diff options
author | Ken Moore <ken@pcbsd.org> | 2015-06-18 08:55:24 -0400 |
---|---|---|
committer | Ken Moore <ken@pcbsd.org> | 2015-06-18 08:55:24 -0400 |
commit | d6ce655acc20d2932f54c5484404f284069f84e1 (patch) | |
tree | 3f5d166eaf0e8a424ed459b5e737770ff8aa9028 /lumina-config/mainUI.cpp | |
parent | Add a quick verification to the favorites system to ensure that the directory... (diff) | |
download | lumina-d6ce655acc20d2932f54c5484404f284069f84e1.tar.gz lumina-d6ce655acc20d2932f54c5484404f284069f84e1.tar.bz2 lumina-d6ce655acc20d2932f54c5484404f284069f84e1.zip |
Add a checkbox for allowing the auto-creation of desktop icons on each individual screen.
Diffstat (limited to 'lumina-config/mainUI.cpp')
-rw-r--r-- | lumina-config/mainUI.cpp | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/lumina-config/mainUI.cpp b/lumina-config/mainUI.cpp index ddc62842..dac7f4f0 100644 --- a/lumina-config/mainUI.cpp +++ b/lumina-config/mainUI.cpp @@ -161,7 +161,8 @@ void MainUI::setupConnections(){ connect(ui->tool_desk_addbgcolor, SIGNAL(clicked()), this, SLOT(deskbgcoloradded()) ); connect(ui->tool_desk_rmbg, SIGNAL(clicked()), this, SLOT(deskbgremoved()) ); connect(ui->spin_desk_min, SIGNAL(valueChanged(int)), this, SLOT(desktimechanged()) ); - + connect(ui->check_desktop_autolaunchers, SIGNAL(clicked()), this, SLOT(desktimechanged()) ); //just need to poke the save routines + //Panels Page connect(ui->tool_panel1_add,SIGNAL(clicked()), this, SLOT(addpanel1()) ); connect(ui->tool_panel2_add,SIGNAL(clicked()), this, SLOT(addpanel2()) ); @@ -510,6 +511,7 @@ void MainUI::loadCurrentSettings(bool screenonly){ else if(bgs[i].startsWith("rgb(")){ui->combo_desk_bg->addItem(QString(tr("Solid Color: %1")).arg(bgs[i]), bgs[i]); } else{ ui->combo_desk_bg->addItem( QIcon(bgs[i]), bgs[i].section("/",-1), bgs[i] ); } } + ui->check_desktop_autolaunchers->setChecked(settings->value(DPrefix+"generateDesktopIcons", false).toBool()); ui->radio_desk_multi->setEnabled(bgs.length()>1); if(bgs.length()>1){ ui->radio_desk_multi->setChecked(true);} else{ ui->radio_desk_single->setChecked(true); } @@ -687,18 +689,19 @@ void MainUI::saveCurrentSettings(bool screenonly){ // Desktop Page if(moddesk){ - QStringList bgs; //get the list of backgrounds to use - if(ui->radio_desk_multi->isChecked()){ - for(int i=0; i<ui->combo_desk_bg->count(); i++){ - bgs << ui->combo_desk_bg->itemData(i).toString(); - } - }else if(ui->combo_desk_bg->count() > 0){ + QStringList bgs; //get the list of backgrounds to use + if(ui->radio_desk_multi->isChecked()){ + for(int i=0; i<ui->combo_desk_bg->count(); i++){ + bgs << ui->combo_desk_bg->itemData(i).toString(); + } + }else if(ui->combo_desk_bg->count() > 0){ bgs << ui->combo_desk_bg->itemData( ui->combo_desk_bg->currentIndex() ).toString(); bgs.removeAll("default"); - } - if(bgs.isEmpty()){ bgs << "default"; } //Make sure to always fall back on the default - settings->setValue(DPrefix+"background/filelist", bgs); - settings->setValue(DPrefix+"background/minutesToChange", ui->spin_desk_min->value()); + } + if(bgs.isEmpty()){ bgs << "default"; } //Make sure to always fall back on the default + settings->setValue(DPrefix+"background/filelist", bgs); + settings->setValue(DPrefix+"background/minutesToChange", ui->spin_desk_min->value()); + settings->setValue(DPrefix+"generateDesktopIcons", ui->check_desktop_autolaunchers->isChecked()); } // Panels Page |