X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d752a3c394b830405753476e508898988d502bfd..b77b87881bae2e6306366d79e7fe160334b3d4a2:/src/gtk/checklst.cpp?ds=sidebyside diff --git a/src/gtk/checklst.cpp b/src/gtk/checklst.cpp index 74064e190c..0f754b7d52 100644 --- a/src/gtk/checklst.cpp +++ b/src/gtk/checklst.cpp @@ -7,17 +7,31 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma implementation "checklst.h" #endif -#include "wx/checklst.h" +// For compilers that support precompilation, includes "wx.h". +#include "wx/wxprec.h" + +#include "wx/defs.h" #if wxUSE_CHECKLISTBOX +#include "wx/checklst.h" +#include "wx/gtk/private.h" + #include #include +//----------------------------------------------------------------------------- +// wxCheckListBoxBase +//----------------------------------------------------------------------------- + +wxCheckListBoxBase::wxCheckListBoxBase() +{ +} + //----------------------------------------------------------------------------- // wxCheckListBox //----------------------------------------------------------------------------- @@ -52,7 +66,7 @@ bool wxCheckListBox::IsChecked( int index ) const GtkBin *bin = GTK_BIN( child->data ); GtkLabel *label = GTK_LABEL( bin->child ); - wxString str = wxString(label->label,*wxConvCurrent); + wxString str( wxGTK_CONV_BACK( label->label ) ); return str.GetChar(1) == wxCHECKLBOX_CHECKED; } @@ -71,14 +85,14 @@ void wxCheckListBox::Check( int index, bool check ) GtkBin *bin = GTK_BIN( child->data ); GtkLabel *label = GTK_LABEL( bin->child ); - wxString str = wxString(label->label,*wxConvCurrent); + wxString str( wxGTK_CONV_BACK( label->label ) ); if (check == (str.GetChar(1) == wxCHECKLBOX_CHECKED)) return; str.SetChar( 1, check ? wxCHECKLBOX_CHECKED : wxCHECKLBOX_UNCHECKED ); - gtk_label_set( label, str.mbc_str() ); + gtk_label_set( label, wxGTK_CONV( str ) ); return; }