Commit 1a5ed68b authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: cache some config variables

parent b243bc8f
...@@ -121,6 +121,8 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf ) ...@@ -121,6 +121,8 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
/* Do we want anoying popups or not */ /* Do we want anoying popups or not */
b_notificationEnabled = var_InheritBool( p_intf, "qt-notification" ); b_notificationEnabled = var_InheritBool( p_intf, "qt-notification" );
b_pauseOnMinimize = var_InheritBool( p_intf, "qt-pause-minimized" );
/* Set the other interface settings */ /* Set the other interface settings */
settings = getSettings(); settings = getSettings();
settings->beginGroup( "MainWindow" ); settings->beginGroup( "MainWindow" );
...@@ -1128,9 +1130,8 @@ void MainInterface::changeEvent(QEvent *event) ...@@ -1128,9 +1130,8 @@ void MainInterface::changeEvent(QEvent *event)
b_hasPausedWhenMinimized = false; b_hasPausedWhenMinimized = false;
if( THEMIM->getIM()->playingStatus() == PLAYING_S && if( THEMIM->getIM()->playingStatus() == PLAYING_S &&
THEMIM->getIM()->hasVideo() && THEMIM->getIM()->hasVideo() && !THEMIM->getIM()->hasVisualisation() &&
!THEMIM->getIM()->hasVisualisation() && b_pauseOnMinimize )
var_InheritBool( p_intf, "qt-pause-minimized" ) )
{ {
b_hasPausedWhenMinimized = true; b_hasPausedWhenMinimized = true;
THEMIM->pause(); THEMIM->pause();
......
...@@ -161,6 +161,7 @@ private: ...@@ -161,6 +161,7 @@ private:
bool b_hideAfterCreation; bool b_hideAfterCreation;
bool b_minimalView; ///< Minimal video bool b_minimalView; ///< Minimal video
bool b_interfaceFullScreen; bool b_interfaceFullScreen;
bool b_pauseOnMinimize;
/* States */ /* States */
bool playlistVisible; ///< Is the playlist visible ? bool playlistVisible; ///< Is the playlist visible ?
......
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