Skip to content

Commit

Permalink
ui fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pokamest committed May 18, 2021
1 parent 4ba964d commit d4c0e51
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 14 deletions.
18 changes: 15 additions & 3 deletions client/ui/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,15 @@ void MainWindow::goToPage(Page page, bool reset, bool slide)
}
if (page == Page::ShareConnection) {

}
if (page == Page::Wizard) {
ui->radioButton_setup_wizard_medium->setChecked(true);
}
if (page == Page::WizardHigh) {
ui->lineEdit_setup_wizard_high_website_masking->setText(protocols::cloak::defaultRedirSite);
}
if (page == Page::ServerConfiguring) {
ui->progressBar_new_server_configuring->setValue(0);
}
if (page == Page::ServersList) {
updateServersListPage();
Expand Down Expand Up @@ -1041,8 +1050,8 @@ void MainWindow::setupWizardConnections()
connect(ui->pushButton_new_server_advanced, &QPushButton::clicked, this, [this](){ goToPage(Page::NewServerProtocols); });
connect(ui->pushButton_setup_wizard_next, &QPushButton::clicked, this, [this](){
if (ui->radioButton_setup_wizard_high->isChecked()) goToPage(Page::WizardHigh);
if (ui->radioButton_setup_wizard_medium->isChecked()) goToPage(Page::WizardMedium);
if (ui->radioButton_setup_wizard_low->isChecked()) goToPage(Page::WizardLow);
else if (ui->radioButton_setup_wizard_medium->isChecked()) goToPage(Page::WizardMedium);
else if (ui->radioButton_setup_wizard_low->isChecked()) goToPage(Page::WizardLow);
});

connect(ui->pushButton_setup_wizard_high_next, &QPushButton::clicked, this, [this](){
Expand Down Expand Up @@ -1070,6 +1079,10 @@ void MainWindow::setupWizardConnections()
connect(ui->pushButton_setup_wizard_low_finish, &QPushButton::clicked, this, [this](){
installServer(getInstallConfigsFromWizardPage());
});

connect(ui->lineEdit_setup_wizard_high_website_masking, &QLineEdit::returnPressed, this, [this](){
ui->pushButton_setup_wizard_high_next->click();
});
}

void MainWindow::setupAppSettingsConnections()
Expand Down Expand Up @@ -1097,7 +1110,6 @@ void MainWindow::setupAppSettingsConnections()
Debug::openLogsFolder();
QDesktopServices::openUrl(QUrl::fromLocalFile(Utils::systemLogPath()));
});

}

void MainWindow::setupGeneralSettingsConnections()
Expand Down
22 changes: 11 additions & 11 deletions client/ui/mainwindow.ui
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ QPushButton:hover {
<string notr="true"/>
</property>
<property name="currentIndex">
<number>13</number>
<number>2</number>
</property>
<widget class="QWidget" name="page_start">
<widget class="QLabel" name="label_25">
Expand Down Expand Up @@ -5397,8 +5397,8 @@ QToolBox::tab:hover {
<rect>
<x>0</x>
<y>0</y>
<width>360</width>
<height>360</height>
<width>100</width>
<height>30</height>
</rect>
</property>
<property name="styleSheet">
Expand Down Expand Up @@ -5525,8 +5525,8 @@ background: #282932;
<rect>
<x>0</x>
<y>0</y>
<width>360</width>
<height>360</height>
<width>100</width>
<height>30</height>
</rect>
</property>
<attribute name="label">
Expand Down Expand Up @@ -5685,8 +5685,8 @@ background: #282932;
<rect>
<x>0</x>
<y>0</y>
<width>360</width>
<height>360</height>
<width>100</width>
<height>30</height>
</rect>
</property>
<attribute name="label">
Expand Down Expand Up @@ -5851,8 +5851,8 @@ background: #282932;
<rect>
<x>0</x>
<y>0</y>
<width>360</width>
<height>360</height>
<width>100</width>
<height>30</height>
</rect>
</property>
<property name="styleSheet">
Expand Down Expand Up @@ -6075,8 +6075,8 @@ color: #15CDCB;
<rect>
<x>0</x>
<y>0</y>
<width>360</width>
<height>360</height>
<width>100</width>
<height>30</height>
</rect>
</property>
<attribute name="label">
Expand Down

0 comments on commit d4c0e51

Please sign in to comment.