diff options
author | Cristian Mircea Messel <mess110@gmail.com> | 2018-05-16 23:05:09 +0300 |
---|---|---|
committer | Cristian Mircea Messel <mess110@gmail.com> | 2018-07-25 01:03:26 +0300 |
commit | 6d5fcad576962e5950641f7e7b113a6ac6f397e5 (patch) | |
tree | e650b09380890669bbd3623bfbd5c5960ebf84eb /src/qt/optionsdialog.cpp | |
parent | 7ebd8c6385253bfa30175169a22f93474d8ddfaf (diff) |
[gui] Make proxy icon from statusbar clickable
Clicking on the proxy icon will open settings showing the network tab
Create enum Tab in OptionsModel
Use new connect syntax
Use lambda for private slots
Diffstat (limited to 'src/qt/optionsdialog.cpp')
-rw-r--r-- | src/qt/optionsdialog.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/qt/optionsdialog.cpp b/src/qt/optionsdialog.cpp index a57343f036..79f4f7777a 100644 --- a/src/qt/optionsdialog.cpp +++ b/src/qt/optionsdialog.cpp @@ -170,6 +170,16 @@ void OptionsDialog::setModel(OptionsModel *_model) connect(ui->thirdPartyTxUrls, SIGNAL(textChanged(const QString &)), this, SLOT(showRestartWarning())); } +void OptionsDialog::setCurrentTab(OptionsDialog::Tab tab) +{ + QWidget *tab_widget = nullptr; + if (tab == OptionsDialog::Tab::TAB_NETWORK) tab_widget = ui->tabNetwork; + if (tab == OptionsDialog::Tab::TAB_MAIN) tab_widget = ui->tabMain; + if (tab_widget && ui->tabWidget->currentWidget() != tab_widget) { + ui->tabWidget->setCurrentWidget(tab_widget); + } +} + void OptionsDialog::setMapper() { /* Main */ |