X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/71ead4bf23e61cec55e4f428fac561fc12b987b9..8a31648287be0ef976f133de2786b137f1e98340:/src/gtk/control.cpp diff --git a/src/gtk/control.cpp b/src/gtk/control.cpp index f69a1dddf3..5a06a3910f 100644 --- a/src/gtk/control.cpp +++ b/src/gtk/control.cpp @@ -89,7 +89,7 @@ void wxControl::PostCreation(const wxSize& size) // GetBestSize is called. gtk_widget_ensure_style(m_widget); - ApplyWidgetStyle(); + GTKApplyWidgetStyle(); SetInitialSize(size); } @@ -123,19 +123,19 @@ void wxControl::GTKFixSensitivity(bool onlyIfUnderMouse) void wxControl::GTKSetLabelForLabel(GtkLabel *w, const wxString& label) { - // save the original label - wxControlBase::SetLabel(label); - const wxString labelGTK = GTKConvertMnemonics(label); gtk_label_set_text_with_mnemonic(w, wxGTK_CONV(labelGTK)); } +#if wxUSE_MARKUP + void wxControl::GTKSetLabelWithMarkupForLabel(GtkLabel *w, const wxString& label) { const wxString labelGTK = GTKConvertMnemonicsWithMarkup(label); gtk_label_set_markup_with_mnemonic(w, wxGTK_CONV(labelGTK)); } +#endif // wxUSE_MARKUP // ---------------------------------------------------------------------------- // GtkFrame helpers @@ -160,6 +160,8 @@ GtkWidget* wxControl::GTKCreateFrame(const wxString& label) void wxControl::GTKSetLabelForFrame(GtkFrame *w, const wxString& label) { + wxControlBase::SetLabel(label); + GtkLabel* labelwidget = GTK_LABEL(gtk_frame_get_label_widget(w)); GTKSetLabelForLabel(labelwidget, label); } @@ -314,22 +316,4 @@ wxControl::GetDefaultAttributesFromGTKWidget(wxGtkWidgetNewFromAdj_t widget_new, return attr; } -// ---------------------------------------------------------------------------- -// idle handling -// ---------------------------------------------------------------------------- - -void wxControl::OnInternalIdle() -{ - if ( GTKShowFromOnIdle() ) - return; - - if ( GTK_WIDGET_REALIZED(m_widget) ) - { - GTKUpdateCursor(); - } - - if ( wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen() ) - UpdateWindowUI(wxUPDATE_UI_FROMIDLE); -} - #endif // wxUSE_CONTROLS