diff --git a/retroshare-gui/src/gui/QuickStartWizard.cpp b/retroshare-gui/src/gui/QuickStartWizard.cpp index 31170636a..bafeb547e 100644 --- a/retroshare-gui/src/gui/QuickStartWizard.cpp +++ b/retroshare-gui/src/gui/QuickStartWizard.cpp @@ -64,7 +64,6 @@ QuickStartWizard::QuickStartWizard(QWidget *parent) : /* Hide platform specific features */ #ifndef Q_WS_WIN ui.checkBoxRunRetroshareAtSystemStartup->setVisible(false); - #endif } @@ -183,7 +182,7 @@ void QuickStartWizard::on_pushButtonSystemFinish_clicked() { Settings->setValue(QString::fromUtf8("StartMinimized"), startMinimized()); Settings->setValue(QString::fromUtf8("doQuit"), quitbox()); - Settings->setRunRetroshareOnBoot(ui.checkBoxRunRetroshareAtSystemStartup->isChecked()); + Settings->setRunRetroshareOnBoot(ui.checkBoxRunRetroshareAtSystemStartup->isChecked(), ui.chkRunRetroshareAtSystemStartupMinimized->isChecked()); saveChanges(); @@ -200,7 +199,6 @@ void QuickStartWizard::on_pushButtonSharesAdd_clicked() /* select a dir */ - QString qdir = QFileDialog::getExistingDirectory(this, tr("Select A Folder To Share"), "", QFileDialog::ShowDirsOnly | QFileDialog::DontResolveSymlinks); @@ -363,7 +361,9 @@ bool QuickStartWizard::messageBoxOk(QString msg) void QuickStartWizard::loadGeneral() { - ui.checkBoxRunRetroshareAtSystemStartup->setChecked(Settings->runRetroshareOnBoot()); + bool minimized; + ui.checkBoxRunRetroshareAtSystemStartup->setChecked(Settings->runRetroshareOnBoot(minimized)); + ui.chkRunRetroshareAtSystemStartupMinimized->setChecked(minimized); ui.checkBoxStartMinimized->setChecked(Settings->value(QString::fromUtf8("StartMinimized"), false).toBool()); ui.checkBoxQuit->setChecked(Settings->value(QString::fromUtf8("doQuit"), false).toBool()); diff --git a/retroshare-gui/src/gui/QuickStartWizard.ui b/retroshare-gui/src/gui/QuickStartWizard.ui index a46fd1a02..5e1770dcf 100644 --- a/retroshare-gui/src/gui/QuickStartWizard.ui +++ b/retroshare-gui/src/gui/QuickStartWizard.ui @@ -158,7 +158,7 @@ p, li { white-space: pre-wrap; } - 1 + 0 @@ -863,14 +863,14 @@ p, li { white-space: pre-wrap; } - + Do not show a message when Closing RetroShare - + Start Minimized @@ -884,6 +884,33 @@ p, li { white-space: pre-wrap; } + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 10 + 20 + + + + + + + + Start minimized on system start + + + + + diff --git a/retroshare-gui/src/gui/settings/GeneralPage.cpp b/retroshare-gui/src/gui/settings/GeneralPage.cpp index 5dc77a169..a95e9d468 100755 --- a/retroshare-gui/src/gui/settings/GeneralPage.cpp +++ b/retroshare-gui/src/gui/settings/GeneralPage.cpp @@ -39,11 +39,9 @@ GeneralPage::GeneralPage(QWidget * parent, Qt::WFlags flags) /* Hide platform specific features */ #ifndef Q_WS_WIN ui.chkRunRetroshareAtSystemStartup->setVisible(false); - #endif ui.autoLogin->setChecked(RsInit::getAutoLogin()); - } /** Destructor */ @@ -61,8 +59,7 @@ GeneralPage::save(QString &errmsg) Settings->setValue(QString::fromUtf8("ClosetoTray"), closetoTray()); - Settings->setRunRetroshareOnBoot( - ui.chkRunRetroshareAtSystemStartup->isChecked()); + Settings->setRunRetroshareOnBoot(ui.chkRunRetroshareAtSystemStartup->isChecked(), ui.chkRunRetroshareAtSystemStartupMinimized->isChecked()); Settings->setMaxTimeBeforeIdle(ui.spinBox->value()); @@ -73,7 +70,9 @@ GeneralPage::save(QString &errmsg) void GeneralPage::load() { - ui.chkRunRetroshareAtSystemStartup->setChecked(Settings->runRetroshareOnBoot()); + bool minimized; + ui.chkRunRetroshareAtSystemStartup->setChecked(Settings->runRetroshareOnBoot(minimized)); + ui.chkRunRetroshareAtSystemStartupMinimized->setChecked(minimized); ui.checkStartMinimized->setChecked(Settings->value(QString::fromUtf8("StartMinimized"), false).toBool()); @@ -82,8 +81,6 @@ GeneralPage::load() ui.checkClosetoTray->setChecked(Settings->value(QString::fromUtf8("ClosetoTray"), false).toBool()); ui.spinBox->setValue(Settings->getMaxTimeBeforeIdle()); - - } bool GeneralPage::quit() const { @@ -101,7 +98,6 @@ bool GeneralPage::closetoTray() const { return ui.checkClosetoTray->isChecked(); } - /** Called when the "show on startup" checkbox is toggled. */ void GeneralPage::toggleShowOnStartup(bool checked) diff --git a/retroshare-gui/src/gui/settings/GeneralPage.ui b/retroshare-gui/src/gui/settings/GeneralPage.ui index c7fa49080..b4e518ce6 100755 --- a/retroshare-gui/src/gui/settings/GeneralPage.ui +++ b/retroshare-gui/src/gui/settings/GeneralPage.ui @@ -1,614 +1,641 @@ - - - GeneralPage - - - - 0 - 0 - 413 - 314 - - - - - 0 - 64 - - - - - - - - - 0 - 0 - 0 - - - - - - - 208 - 208 - 208 - - - - - - - 255 - 255 - 255 - - - - - - - 247 - 247 - 247 - - - - - - - 104 - 104 - 104 - - - - - - - 139 - 139 - 139 - - - - - - - 0 - 0 - 0 - - - - - - - 255 - 255 - 255 - - - - - - - 0 - 0 - 0 - - - - - - - 255 - 255 - 255 - - - - - - - 240 - 240 - 240 - - - - - - - 0 - 0 - 0 - - - - - - - 0 - 0 - 128 - - - - - - - 255 - 255 - 255 - - - - - - - 0 - 0 - 255 - - - - - - - 255 - 0 - 255 - - - - - - - 231 - 231 - 231 - - - - - - - - - 0 - 0 - 0 - - - - - - - 208 - 208 - 208 - - - - - - - 255 - 255 - 255 - - - - - - - 247 - 247 - 247 - - - - - - - 104 - 104 - 104 - - - - - - - 139 - 139 - 139 - - - - - - - 0 - 0 - 0 - - - - - - - 255 - 255 - 255 - - - - - - - 0 - 0 - 0 - - - - - - - 255 - 255 - 255 - - - - - - - 240 - 240 - 240 - - - - - - - 0 - 0 - 0 - - - - - - - 192 - 192 - 192 - - - - - - - 0 - 0 - 0 - - - - - - - 0 - 0 - 255 - - - - - - - 255 - 0 - 255 - - - - - - - 231 - 231 - 231 - - - - - - - - - 104 - 104 - 104 - - - - - - - 208 - 208 - 208 - - - - - - - 255 - 255 - 255 - - - - - - - 247 - 247 - 247 - - - - - - - 104 - 104 - 104 - - - - - - - 139 - 139 - 139 - - - - - - - 104 - 104 - 104 - - - - - - - 255 - 255 - 255 - - - - - - - 104 - 104 - 104 - - - - - - - 240 - 240 - 240 - - - - - - - 240 - 240 - 240 - - - - - - - 0 - 0 - 0 - - - - - - - 0 - 0 - 128 - - - - - - - 255 - 255 - 255 - - - - - - - 0 - 0 - 255 - - - - - - - 255 - 0 - 255 - - - - - - - 231 - 231 - 231 - - - - - - - - - Arial - 10 - 50 - false - false - false - false - - - - Qt::NoContextMenu - - - - - - - 0 - 80 - - - - Startup - - - - - - Start RetroShare when my system starts - - - - - - - Start minimized - - - true - - - - - - - - - - Misc - - - - - - Do not show the Quit RetroShare MessageBox - - - - - - - Do not Minimize to Tray Icon - - - true - - - - - - - Auto Login - - - - - - - - - - Qt::Vertical - - - - 178 - 95 - - - - - - - - Idle - - - - - - Idle Time - - - - - - - seconds - - - - - - 1000 - - - - - - - - - - - + + + GeneralPage + + + + 0 + 0 + 413 + 314 + + + + + 0 + 64 + + + + + + + + + 0 + 0 + 0 + + + + + + + 208 + 208 + 208 + + + + + + + 255 + 255 + 255 + + + + + + + 247 + 247 + 247 + + + + + + + 104 + 104 + 104 + + + + + + + 139 + 139 + 139 + + + + + + + 0 + 0 + 0 + + + + + + + 255 + 255 + 255 + + + + + + + 0 + 0 + 0 + + + + + + + 255 + 255 + 255 + + + + + + + 240 + 240 + 240 + + + + + + + 0 + 0 + 0 + + + + + + + 0 + 0 + 128 + + + + + + + 255 + 255 + 255 + + + + + + + 0 + 0 + 255 + + + + + + + 255 + 0 + 255 + + + + + + + 231 + 231 + 231 + + + + + + + + + 0 + 0 + 0 + + + + + + + 208 + 208 + 208 + + + + + + + 255 + 255 + 255 + + + + + + + 247 + 247 + 247 + + + + + + + 104 + 104 + 104 + + + + + + + 139 + 139 + 139 + + + + + + + 0 + 0 + 0 + + + + + + + 255 + 255 + 255 + + + + + + + 0 + 0 + 0 + + + + + + + 255 + 255 + 255 + + + + + + + 240 + 240 + 240 + + + + + + + 0 + 0 + 0 + + + + + + + 192 + 192 + 192 + + + + + + + 0 + 0 + 0 + + + + + + + 0 + 0 + 255 + + + + + + + 255 + 0 + 255 + + + + + + + 231 + 231 + 231 + + + + + + + + + 104 + 104 + 104 + + + + + + + 208 + 208 + 208 + + + + + + + 255 + 255 + 255 + + + + + + + 247 + 247 + 247 + + + + + + + 104 + 104 + 104 + + + + + + + 139 + 139 + 139 + + + + + + + 104 + 104 + 104 + + + + + + + 255 + 255 + 255 + + + + + + + 104 + 104 + 104 + + + + + + + 240 + 240 + 240 + + + + + + + 240 + 240 + 240 + + + + + + + 0 + 0 + 0 + + + + + + + 0 + 0 + 128 + + + + + + + 255 + 255 + 255 + + + + + + + 0 + 0 + 255 + + + + + + + 255 + 0 + 255 + + + + + + + 231 + 231 + 231 + + + + + + + + + Arial + 10 + 50 + false + false + false + false + + + + Qt::NoContextMenu + + + + + + + 0 + 80 + + + + Startup + + + + + + Start RetroShare when my system starts + + + + + + + Start minimized + + + true + + + + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 10 + 20 + + + + + + + + Start minimized on system start + + + + + + + + + + + + Misc + + + + + + Do not show the Quit RetroShare MessageBox + + + + + + + Do not Minimize to Tray Icon + + + true + + + + + + + Auto Login + + + + + + + + + + Qt::Vertical + + + + 178 + 95 + + + + + + + + Idle + + + + + + Idle Time + + + + + + + seconds + + + + + + 1000 + + + + + + + + + + + diff --git a/retroshare-gui/src/gui/settings/rsharesettings.cpp b/retroshare-gui/src/gui/settings/rsharesettings.cpp index 77ee571fd..291cc424b 100644 --- a/retroshare-gui/src/gui/settings/rsharesettings.cpp +++ b/retroshare-gui/src/gui/settings/rsharesettings.cpp @@ -424,14 +424,19 @@ void RshareSettings::setPrivateChatHistoryCount(int value) /** Returns true if RetroShare is set to run on system boot. */ bool -RshareSettings::runRetroshareOnBoot() +RshareSettings::runRetroshareOnBoot(bool &minimized) { + minimized = false; + #if defined(Q_WS_WIN) - if (!win32_registry_get_key_value(STARTUP_REG_KEY, RETROSHARE_REG_KEY).isEmpty()) { + QString value = win32_registry_get_key_value(STARTUP_REG_KEY, RETROSHARE_REG_KEY); + + if (!value.isEmpty()) { + /* Simple check for "-m" */ + minimized = value.contains(" -m"); return true; - } else { - return false; } + return false; #else /* Platforms other than windows aren't supported yet */ return false; @@ -440,14 +445,17 @@ RshareSettings::runRetroshareOnBoot() /** If run is set to true, then RetroShare will run on system boot. */ void -RshareSettings::setRunRetroshareOnBoot(bool run) +RshareSettings::setRunRetroshareOnBoot(bool run, bool minimized) { #if defined(Q_WS_WIN) if (run) { - win32_registry_set_key_value(STARTUP_REG_KEY, RETROSHARE_REG_KEY, - QString("\"" + - QDir::convertSeparators(QCoreApplication::applicationFilePath())) + - "\""); + QString value = "\"" + QDir::convertSeparators(QCoreApplication::applicationFilePath()) + "\""; + + if (minimized) { + value += " -m"; + } + + win32_registry_set_key_value(STARTUP_REG_KEY, RETROSHARE_REG_KEY, value); } else { win32_registry_remove_key(STARTUP_REG_KEY, RETROSHARE_REG_KEY); } diff --git a/retroshare-gui/src/gui/settings/rsharesettings.h b/retroshare-gui/src/gui/settings/rsharesettings.h index 981af3a65..7268bc71f 100644 --- a/retroshare-gui/src/gui/settings/rsharesettings.h +++ b/retroshare-gui/src/gui/settings/rsharesettings.h @@ -100,10 +100,10 @@ public: void setShowMainWindowAtStart(bool show); /** Returns true if RetroShare should start on system boot. */ - bool runRetroshareOnBoot(); + bool runRetroshareOnBoot(bool &minimized); /** Set whether to run RetroShare on system boot. */ - void setRunRetroshareOnBoot(bool run); + void setRunRetroshareOnBoot(bool run, bool minimized); /* Get the destination log file. */ QString getLogFile(); diff --git a/retroshare-gui/src/gui/settings/settings.ui b/retroshare-gui/src/gui/settings/settings.ui index f085e149d..660e71d45 100755 --- a/retroshare-gui/src/gui/settings/settings.ui +++ b/retroshare-gui/src/gui/settings/settings.ui @@ -1,335 +1,338 @@ - - - Settings - - - - 0 - 0 - 458 - 366 - - - - Options - - - - :/images/kcmsystem24.png:/images/kcmsystem24.png - - - - - - - 130 - 0 - - - - - 130 - 16777215 - - - - false - - - - 24 - 24 - - - - Qt::ElideMiddle - - - QListView::Static - - - QListView::TopToBottom - - - false - - - QListView::Fixed - - - QListView::SinglePass - - - - 100 - 24 - - - - QListView::ListMode - - - 0 - - - true - - - -1 - - - - General - - - - :/images/kcmsystem24.png:/images/kcmsystem24.png - - - - - Server - - - - :/images/server_24x24.png:/images/server_24x24.png - - - - - Transfer - - - - :/images/ktorrent32.png:/images/ktorrent32.png - - - - - Directories - - - - :/images/folder_doments.png:/images/folder_doments.png - - - - - Notify - - - - :/images/status_unknown.png:/images/status_unknown.png - - - - - Security - - - - :/images/encrypted32.png:/images/encrypted32.png - - - - - Message - - - - :/images/evolution.png:/images/evolution.png - - - - - Forum - - - - :/images/konversation.png:/images/konversation.png - - - - - Chat - - - - :/images/chat_24.png:/images/chat_24.png - - - - - Appearance - - - - :/images/looknfeel.png:/images/looknfeel.png - - - - - Sound - - - - :/images/sound.png:/images/sound.png - - - - - - - - - - - 24 - 24 - - - - - - - true - - - - - - - - 0 - 0 - - - - - Sans Serif - 11 - 75 - false - true - false - false - - - - - - - - - - - Qt::Horizontal - - - - - - - - - 0 - - - - - - - - Qt::Horizontal - - - - - - - 6 - - - 0 - - - - - Qt::Horizontal - - - - 312 - 31 - - - - - - - - - 0 - 22 - - - - Cancel - - - - - - - - 0 - 22 - - - - OK - - - - - - - - - - - - - applyButton - clicked() - Settings - accept() - - - 278 - 253 - - - 96 - 254 - - - - - canceButton - clicked() - Settings - reject() - - - 369 - 253 - - - 179 - 282 - - - - - + + + Settings + + + + 0 + 0 + 458 + 366 + + + + Options + + + + :/images/kcmsystem24.png:/images/kcmsystem24.png + + + + + + + 130 + 0 + + + + + 130 + 16777215 + + + + false + + + + 24 + 24 + + + + Qt::ElideMiddle + + + QListView::Static + + + QListView::TopToBottom + + + false + + + QListView::Fixed + + + QListView::SinglePass + + + + 100 + 24 + + + + QListView::ListMode + + + 0 + + + true + + + -1 + + + + General + + + + :/images/kcmsystem24.png:/images/kcmsystem24.png + + + + + Server + + + + :/images/server_24x24.png:/images/server_24x24.png + + + + + Transfer + + + + :/images/ktorrent32.png:/images/ktorrent32.png + + + + + Directories + + + + :/images/folder_doments.png:/images/folder_doments.png + + + + + Notify + + + + :/images/status_unknown.png:/images/status_unknown.png + + + + + Security + + + + :/images/encrypted32.png:/images/encrypted32.png + + + + + Message + + + + :/images/evolution.png:/images/evolution.png + + + + + Forum + + + + :/images/konversation.png:/images/konversation.png + + + + + Chat + + + + :/images/chat_24.png:/images/chat_24.png + + + + + Appearance + + + + :/images/looknfeel.png:/images/looknfeel.png + + + + + Sound + + + + :/images/sound.png:/images/sound.png + + + + + + + + + + + 24 + 24 + + + + + + + true + + + + + + + + 0 + 0 + + + + + Sans Serif + 11 + 75 + false + true + false + false + + + + + + + + + + + Qt::Horizontal + + + + + + + + + 0 + + + + + + + + Qt::Horizontal + + + + + + + 6 + + + 0 + + + + + Qt::Horizontal + + + + 312 + 31 + + + + + + + + + 0 + 22 + + + + Cancel + + + + + + + + 0 + 22 + + + + OK + + + true + + + + + + + + + + + + + applyButton + clicked() + Settings + accept() + + + 278 + 253 + + + 96 + 254 + + + + + canceButton + clicked() + Settings + reject() + + + 369 + 253 + + + 179 + 282 + + + + + diff --git a/retroshare-gui/src/lang/retroshare_de.qm b/retroshare-gui/src/lang/retroshare_de.qm index 1e8fcc7aa..62879cd21 100644 Binary files a/retroshare-gui/src/lang/retroshare_de.qm and b/retroshare-gui/src/lang/retroshare_de.qm differ diff --git a/retroshare-gui/src/lang/retroshare_de.ts b/retroshare-gui/src/lang/retroshare_de.ts index 42f67cd99..aa738ba12 100644 --- a/retroshare-gui/src/lang/retroshare_de.ts +++ b/retroshare-gui/src/lang/retroshare_de.ts @@ -4231,17 +4231,22 @@ Fill in your GPG password when asked, to sign your new key. GeneralPage - + Auto Login Automatische Anmeldung - + Startup Programmstart - + + Start minimized on system start + Minimieren beim Starten mit dem System + + + Misc Verschiedenes @@ -4258,20 +4263,20 @@ Fill in your GPG password when asked, to sign your new key. seconds - + Sekunden - + Start minimized Minimiert starten Start RetroShare when my system starts - Starte mit Windows + Starte RetroShare mit dem System - + Idle Untätig @@ -8841,12 +8846,12 @@ p, li { white-space: pre-wrap; } - + Exit Beenden - + For best performance, RetroShare needs to know a little about your connection to the internet. Für die beste Leistung muss RetroShare ein wenig über Ihre Internetverbindung erfahren. @@ -8894,12 +8899,12 @@ p, li { white-space: pre-wrap; } - + < Back < Zurück - + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } @@ -8974,12 +8979,17 @@ p, li { white-space: pre-wrap; } Starte RetroShare mit dem System. - - Finish - Ende + + Start minimized on system start + Minimieren beim Starten mit dem System - + + Finish + Fertigstellen + + + Select A Folder To Share Wählen Sie ein Ordner zum Freigeben @@ -8999,7 +9009,7 @@ p, li { white-space: pre-wrap; } Warnung! - + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; }