Commit 6f69173f authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Yet again a try to fix the sizing behaviour when too big...

parent 9ed87e8d
...@@ -73,7 +73,7 @@ VideoWidget::VideoWidget( intf_thread_t *_p_i ) : QFrame( NULL ), p_intf( _p_i ) ...@@ -73,7 +73,7 @@ VideoWidget::VideoWidget( intf_thread_t *_p_i ) : QFrame( NULL ), p_intf( _p_i )
hide(); hide();
/* Set the policy to expand in both directions */ /* Set the policy to expand in both directions */
setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Expanding ); // setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Expanding );
/* Black background is more coherent for a Video Widget */ /* Black background is more coherent for a Video Widget */
QPalette plt = palette(); QPalette plt = palette();
......
...@@ -607,11 +607,9 @@ void MainInterface::debug() ...@@ -607,11 +607,9 @@ void MainInterface::debug()
msg_Dbg( p_intf, "sizeHint: %i - %i", sizeHint().height(), sizeHint().width() ); msg_Dbg( p_intf, "sizeHint: %i - %i", sizeHint().height(), sizeHint().width() );
if( videoWidget && videoWidget->isVisible() ) if( videoWidget && videoWidget->isVisible() )
{ {
// sleep( 10 );
msg_Dbg( p_intf, "size: %i - %i", size().height(), size().width() ); msg_Dbg( p_intf, "size: %i - %i", size().height(), size().width() );
msg_Dbg( p_intf, "sizeHint: %i - %i", sizeHint().height(), sizeHint().width() ); msg_Dbg( p_intf, "sizeHint: %i - %i", sizeHint().height(), sizeHint().width() );
} }
adjustSize();
#endif #endif
} }
...@@ -774,8 +772,8 @@ void MainInterface::togglePlaylist() ...@@ -774,8 +772,8 @@ void MainInterface::togglePlaylist()
{ {
/* toggle the visibility of the playlist */ /* toggle the visibility of the playlist */
TOGGLEV( playlistWidget ); TOGGLEV( playlistWidget );
//resize( sizeHint() );
playlistVisible = !playlistVisible; playlistVisible = !playlistVisible;
//doComponentsUpdate(); //resize( sizeHint() );
} }
} }
...@@ -783,7 +781,7 @@ void MainInterface::togglePlaylist() ...@@ -783,7 +781,7 @@ void MainInterface::togglePlaylist()
void MainInterface::undockPlaylist() void MainInterface::undockPlaylist()
{ {
// dockPL->setFloating( true ); // dockPL->setFloating( true );
adjustSize(); // adjustSize();
} }
void MainInterface::dockPlaylist( pl_dock_e i_pos ) void MainInterface::dockPlaylist( pl_dock_e i_pos )
...@@ -814,11 +812,22 @@ void MainInterface::toggleMinimalView() ...@@ -814,11 +812,22 @@ void MainInterface::toggleMinimalView()
/* Video widget cannot do this synchronously as it runs in another thread */ /* Video widget cannot do this synchronously as it runs in another thread */
/* Well, could it, actually ? Probably dangerous ... */ /* Well, could it, actually ? Probably dangerous ... */
/* This function is called:
- toggling of minimal View
- through askUpdate() by Vout thread request video and resize video (zoom)
- Advanced buttons toggled
*/
void MainInterface::doComponentsUpdate() void MainInterface::doComponentsUpdate()
{ {
msg_Dbg( p_intf, "Updating the geometry" ); msg_Dbg( p_intf, "Updating the geometry" );
// resize( sizeHint() ); /* Here we resize to sizeHint() and not adjustsize because we want
adjustSize(); the videoWidget to be exactly the correctSize */
resize( sizeHint() );
// adjustSize() ;
#ifndef NDEBUG
debug();
#endif
} }
/* toggling advanced controls buttons */ /* toggling advanced controls buttons */
......
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