|
|
|
@ -200,6 +200,7 @@ void TunnelPane::deleteButtonReleased() {
@@ -200,6 +200,7 @@ void TunnelPane::deleteButtonReleased() {
|
|
|
|
|
switch (ret) { |
|
|
|
|
case QMessageBox::Ok: |
|
|
|
|
// OK was clicked
|
|
|
|
|
hideWrongInputLabel(); |
|
|
|
|
tunnelsPageUpdateListener->needsDeleting(tunnelConfig->getName()); |
|
|
|
|
break; |
|
|
|
|
case QMessageBox::Cancel: |
|
|
|
@ -232,10 +233,9 @@ void TunnelPane::deleteTunnelForm() {
@@ -232,10 +233,9 @@ void TunnelPane::deleteTunnelForm() {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void TunnelPane::highlightWrongInput(QString warningText, QWidget* controlWithWrongInput) { |
|
|
|
|
bool redVisible = wrongInputPane->isVisible(); |
|
|
|
|
wrongInputPane->setVisible(true); |
|
|
|
|
wrongInputLabel->setText(warningText); |
|
|
|
|
if(!redVisible)mainWindow->adjustSizesAccordingToWrongLabel(); |
|
|
|
|
mainWindow->adjustSizesAccordingToWrongLabel(); |
|
|
|
|
if(controlWithWrongInput){ |
|
|
|
|
mainWindow->ui->tunnelsScrollArea->ensureWidgetVisible(controlWithWrongInput); |
|
|
|
|
controlWithWrongInput->setFocus(); |
|
|
|
@ -244,8 +244,6 @@ void TunnelPane::highlightWrongInput(QString warningText, QWidget* controlWithWr
@@ -244,8 +244,6 @@ void TunnelPane::highlightWrongInput(QString warningText, QWidget* controlWithWr
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void TunnelPane::hideWrongInputLabel() const { |
|
|
|
|
bool redVisible = wrongInputPane->isVisible(); |
|
|
|
|
wrongInputPane->setVisible(false); |
|
|
|
|
if(redVisible)mainWindow->adjustSizesAccordingToWrongLabel(); |
|
|
|
|
|
|
|
|
|
mainWindow->adjustSizesAccordingToWrongLabel(); |
|
|
|
|
} |
|
|
|
|