diff --git a/src/gtk/collpane.cpp b/src/gtk/collpane.cpp index 386a031b9e..20b5e91aba 100644 --- a/src/gtk/collpane.cpp +++ b/src/gtk/collpane.cpp @@ -271,9 +271,9 @@ void wxCollapsiblePane::OnSize(wxSizeEvent &ev) // here we need to resize the pane window otherwise, even if the GtkExpander container // is expanded or shrunk, the pane window won't be updated! - int w = ev.GetSize().y - m_szCollapsed.y; - if (w < 0) w = 0; - m_pPane->SetSize(ev.GetSize().x, w); + int h = ev.GetSize().y - m_szCollapsed.y; + if (h < 0) h = 0; + m_pPane->SetSize(ev.GetSize().x, h); // we need to explicitly call m_pPane->Layout() or else it won't correctly relayout // (even if SetAutoLayout(true) has been called on it!)