Commit e6ed0117 authored by gbazin's avatar gbazin
Browse files

* modules/gui/wxwindows/interface.cpp: better interface size under gtk.

parent b478e5fc
...@@ -372,13 +372,17 @@ void Interface::CreateOurMenuBar() ...@@ -372,13 +372,17 @@ void Interface::CreateOurMenuBar()
/* Find out size of menu bar */ /* Find out size of menu bar */
int i_size = 0; int i_size = 0;
for( int i = 0; i < menubar->GetMenuCount(); i++ ) for( unsigned int i = 0; i < menubar->GetMenuCount(); i++ )
{ {
int i_width, i_height; int i_width, i_height;
menubar->GetTextExtent( menubar->GetLabelTop(i), &i_width, &i_height ); menubar->GetTextExtent( menubar->GetLabelTop(i), &i_width, &i_height );
i_size += i_width + 4 /* approximate margin */; i_size += i_width +
#if defined(__WXGTK__)
20 /* approximate margin */;
#else
4 /* approximate margin */;
#endif
} }
frame_sizer->SetMinSize( i_size, -1 ); frame_sizer->SetMinSize( i_size, -1 );
/* Intercept all menu events in our custom event handler */ /* Intercept all menu events in our custom event handler */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment