/* Final sizing and showing */
setVisible( !b_hideAfterCreation );
- setMinimumWidth( __MAX( controls->sizeHint().width(),
- menuBar()->sizeHint().width() ) + 30 );
+ computeMinimumSize();
/* Switch to minimal view if needed, must be called after the show() */
if( b_minimalView )
p_intf->p_sys->p_mi = NULL;
}
+void MainInterface::computeMinimumSize()
+{
+ int minWidth = 30;
+ if( menuBar()->isVisible() )
+ minWidth += __MAX( controls->sizeHint().width(), menuBar()->sizeHint().width() );
+
+ setMinimumWidth( minWidth );
+}
+
/*****************************
* Main UI handling *
*****************************/
}
b_minimalView = b_minimal;
if( !b_videoFullScreen )
+ {
setMinimalView( b_minimalView );
+ computeMinimumSize();
+ }
emit minimalViewToggled( b_minimalView );
}