diff --git a/kcmkwin/kwinoptions/mouse.cpp b/kcmkwin/kwinoptions/mouse.cpp index 4b33976e2e..c20cc4d227 100644 --- a/kcmkwin/kwinoptions/mouse.cpp +++ b/kcmkwin/kwinoptions/mouse.cpp @@ -567,6 +567,16 @@ const char* KTitleBarActionsConfig::functionMax( int i ) return tbl_num_lookup( tbl_Max, i ); } +void KTitleBarActionsConfig::showEvent( QShowEvent *ev ) +{ + if ( !standAlone ) { + // Workaround KCModule::showEvent() calling load(), see bug 163817 + QWidget::showEvent( ev ); + return; + } + KCModule::showEvent( ev ); +} + void KTitleBarActionsConfig::load() { KConfigGroup windowsConfig(config, "Windows"); @@ -915,6 +925,15 @@ const char* KWindowActionsConfig::functionAllW(int i) return tbl_num_lookup( tbl_AllW, i ); } +void KWindowActionsConfig::showEvent( QShowEvent *ev ) +{ + if ( !standAlone ) { + QWidget::showEvent( ev ); + return; + } + KCModule::showEvent( ev ); +} + void KWindowActionsConfig::load() { KConfigGroup cg(config, "MouseBindings"); diff --git a/kcmkwin/kwinoptions/mouse.h b/kcmkwin/kwinoptions/mouse.h index eee08217b7..e8ef5d96ea 100644 --- a/kcmkwin/kwinoptions/mouse.h +++ b/kcmkwin/kwinoptions/mouse.h @@ -60,6 +60,9 @@ public: void save(); void defaults(); +protected: + void showEvent( QShowEvent *ev ); + public slots: void changed() { emit KCModule::changed(true); } @@ -106,6 +109,9 @@ public: void save(); void defaults(); +protected: + void showEvent( QShowEvent *ev ); + public slots: void changed() { emit KCModule::changed(true); } diff --git a/kcmkwin/kwinoptions/windows.cpp b/kcmkwin/kwinoptions/windows.cpp index 1c14078f19..4af5e75bc9 100644 --- a/kcmkwin/kwinoptions/windows.cpp +++ b/kcmkwin/kwinoptions/windows.cpp @@ -381,6 +381,15 @@ void KFocusConfig::updateActiveMouseScreen() setActiveMouseScreen( focusCombo->currentIndex() != 0 ); } +void KFocusConfig::showEvent( QShowEvent *ev ) +{ + if ( !standAlone ) { + QWidget::showEvent( ev ); + return; + } + KCModule::showEvent( ev ); +} + void KFocusConfig::load( void ) { QString key; @@ -653,6 +662,15 @@ void KAdvancedConfig::shadeHoverChanged(bool a) { } +void KAdvancedConfig::showEvent( QShowEvent *ev ) +{ + if ( !standAlone ) { + QWidget::showEvent( ev ); + return; + } + KCModule::showEvent( ev ); +} + void KAdvancedConfig::load( void ) { KConfigGroup cg(config, "Windows"); @@ -982,6 +1000,15 @@ void KMovingConfig::slotCntrSnapChanged(int value) { CntrSnap->setSuffix(i18np(" pixel", " pixels", value)); } +void KMovingConfig::showEvent( QShowEvent *ev ) +{ + if ( !standAlone ) { + QWidget::showEvent( ev ); + return; + } + KCModule::showEvent( ev ); +} + void KMovingConfig::load( void ) { QString key; diff --git a/kcmkwin/kwinoptions/windows.h b/kcmkwin/kwinoptions/windows.h index 8b8e54a06e..2890209072 100644 --- a/kcmkwin/kwinoptions/windows.h +++ b/kcmkwin/kwinoptions/windows.h @@ -76,6 +76,9 @@ public: void save(); void defaults(); +protected: + void showEvent( QShowEvent *ev ); + private slots: void setDelayFocusEnabled(); void focusPolicyChanged(); @@ -132,6 +135,9 @@ public: void save(); void defaults(); +protected: + void showEvent( QShowEvent *ev ); + private slots: void changed() { emit KCModule::changed(true); } void slotBrdrSnapChanged( int ); @@ -182,6 +188,9 @@ public: void save(); void defaults(); +protected: + void showEvent( QShowEvent *ev ); + private slots: void shadeHoverChanged(bool);