X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ff654490b7cb185631a1dc4621094d88643ccf41..05e0b047d879cdbfade7f2ab346c0acdf3e29f96:/src/gtk/collpane.cpp?ds=sidebyside diff --git a/src/gtk/collpane.cpp b/src/gtk/collpane.cpp index 2702156f34..d312306ca3 100644 --- a/src/gtk/collpane.cpp +++ b/src/gtk/collpane.cpp @@ -102,7 +102,7 @@ gtk_collapsiblepane_expanded_callback(GObject * WXUNUSED(object), { // fire an event wxCollapsiblePaneEvent ev(p, p->GetId(), p->IsCollapsed()); - p->GetEventHandler()->ProcessEvent(ev); + p->HandleWindowEvent(ev); // the user asked to explicitely handle the resizing itself... return; @@ -117,17 +117,18 @@ gtk_collapsiblepane_expanded_callback(GObject * WXUNUSED(object), if (top->m_mainWidget) { - // 3) MAGIC HACK: if you ever used GtkExpander in a GTK+ program you know - // that this magic call is required to make it possible to shrink the - // top level window in the expanded->collapsed transition. - // This may be sometimes undesired but *is* necessary and if you look - // carefully, all GTK+ programs using GtkExpander perform this trick - // (e.g. the standard "open file" dialog of GTK+>=2.4 is not resizeable - // when the expander is collapsed!) + // 3) MAGIC HACK: if you ever used GtkExpander in a GTK+ program + // you know that this magic call is required to make it possible + // to shrink the top level window in the expanded->collapsed + // transition. This may be sometimes undesired but *is* + // necessary and if you look carefully, all GTK+ programs using + // GtkExpander perform this trick (e.g. the standard "open file" + // dialog of GTK+>=2.4 is not resizeable when the expander is + // collapsed!) gtk_window_set_resizable (GTK_WINDOW (top->m_widget), p->IsExpanded()); // 4) set size hints - top->SetSizeHints(sz.x, sz.y); + top->SetMinClientSize(sz); // 5) set size top->SetClientSize(sz); @@ -143,7 +144,7 @@ gtk_collapsiblepane_expanded_callback(GObject * WXUNUSED(object), // fire an event wxCollapsiblePaneEvent ev(p, p->GetId(), p->IsCollapsed()); - p->GetEventHandler()->ProcessEvent(ev); + p->HandleWindowEvent(ev); } }