Skip to content

Commit

Permalink
Show add client dialog only if main window is active deskflow#4230
Browse files Browse the repository at this point in the history
  • Loading branch information
Xinyu Hou committed Dec 1, 2014
1 parent 48b552a commit 917c750
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/gui/src/ServerConfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -372,10 +372,14 @@ bool ServerConfig::fixNoServer(const QString& name, int& index)

int ServerConfig::showAddClientDialog(const QString& clientName)
{
AddClientDialog addClientDialog(clientName, m_pMainWindow);
addClientDialog.exec();
int result = addClientDialog.addResult();
m_IgnoreAutoConfigClient = addClientDialog.ignoreAutoConfigClient();
int result = kAddClientIgnore;

if (m_pMainWindow->isActiveWindow()) {
AddClientDialog addClientDialog(clientName, m_pMainWindow);
addClientDialog.exec();
result = addClientDialog.addResult();
m_IgnoreAutoConfigClient = addClientDialog.ignoreAutoConfigClient();
}

return result;
}
Expand Down

0 comments on commit 917c750

Please sign in to comment.