diff options
author | Ken Moore <ken@pcbsd.org> | 2015-03-02 15:16:21 -0500 |
---|---|---|
committer | Ken Moore <ken@pcbsd.org> | 2015-03-02 15:16:21 -0500 |
commit | 60d19209e98cddaca0497efc860abfa24962e532 (patch) | |
tree | c86ed9356bc6376cbd49cd8b47d8b30f7f00983a /lumina-config | |
parent | Enable a bunch of debugging in the lumina-fm background worker. Something in ... (diff) | |
download | lumina-60d19209e98cddaca0497efc860abfa24962e532.tar.gz lumina-60d19209e98cddaca0497efc860abfa24962e532.tar.bz2 lumina-60d19209e98cddaca0497efc860abfa24962e532.zip |
Fix an issue with how the panel configuration was adjusting the "other" panel settings - the change was bouncing back and triggering the first panel adjustment again - changing locations back to top/bottom instead of where they were set originally.
Diffstat (limited to 'lumina-config')
-rw-r--r-- | lumina-config/mainUI.cpp | 11 | ||||
-rw-r--r-- | lumina-config/mainUI.h | 2 |
2 files changed, 9 insertions, 4 deletions
diff --git a/lumina-config/mainUI.cpp b/lumina-config/mainUI.cpp index c633e866..724d4556 100644 --- a/lumina-config/mainUI.cpp +++ b/lumina-config/mainUI.cpp @@ -16,6 +16,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI()){ ui->setupUi(this); //load the designer file this->setWindowIcon( LXDG::findIcon("preferences-desktop-display","") ); PINFO = new LPlugins(); //load the info class + panadjust = false; DEFAULTBG = LOS::LuminaShare()+"desktop-background.jpg"; //Be careful about the QSettings setup, it must match the lumina-desktop setup QSettings::setPath(QSettings::NativeFormat, QSettings::UserScope, QDir::homePath()+"/.lumina"); @@ -864,7 +865,8 @@ void MainUI::checkpanels(){ void MainUI::adjustpanel1(){ //Adjust panel 1 to complement a panel 2 change - if(loading){ return; } + if(loading || panadjust){ return; } + panadjust = true; qDebug() << "Adjust Panel 1:"; ui->toolBox_panel1->setCurrentIndex( ui->toolBox_panel2->currentIndex() ); bool changed = false; @@ -883,11 +885,13 @@ void MainUI::adjustpanel1(){ changed = true; ui->combo_panel1_loc->setCurrentIndex(newindex); } + panadjust = false; if(!loading){ ui->push_save->setEnabled(true); modpan = true; } } void MainUI::adjustpanel2(){ - if(loading){ return; } + if(loading || panadjust){ return; } + panadjust = true; //Adjust panel 2 to complement a panel 1 change qDebug() << "Adjust Panel 2:"; ui->toolBox_panel2->setCurrentIndex( ui->toolBox_panel1->currentIndex() ); @@ -907,7 +911,8 @@ void MainUI::adjustpanel2(){ changed = true; ui->combo_panel2_loc->setCurrentIndex(newindex); } - if(!loading){ ui->push_save->setEnabled(true); modpan = true; } + panadjust = false; + if(!loading && changed){ ui->push_save->setEnabled(true); modpan = true; } } diff --git a/lumina-config/mainUI.h b/lumina-config/mainUI.h index 93400d93..2593d648 100644 --- a/lumina-config/mainUI.h +++ b/lumina-config/mainUI.h @@ -57,7 +57,7 @@ private: QString panelcolor; QString DEFAULTBG; QList<XDGDesktop> sysApps; - bool loading; + bool loading, panadjust; bool moddesk, modpan, modmenu, modshort, moddef, modses; //page modified flags int panelnumber; |