[interactiveconsole] Fix initial load selection

Summary:
QActionGroup has no signal for when an action within the group changes
checked state. Only when an action within is triggered.

Without calling trigger InteractiveConsole::modeSelectionChanged is not
triggered and m_mode is not updated.

BUG: 408787

Test Plan:
qdbus to launch the console
Execute button went to the right place

Reviewers: #plasma, broulik

Reviewed By: #plasma, broulik

Subscribers: broulik, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D21852
wilder-5.19
David Edmundson 7 years ago
parent 951551bc6d
commit 15de7ceb38
  1. 4
      components/shellprivate/interactiveconsole/interactiveconsole.cpp

@ -207,9 +207,9 @@ InteractiveConsole::~InteractiveConsole()
void InteractiveConsole::setMode(const QString &mode)
{
if (mode.toLower() == QLatin1String("desktop")) {
m_plasmaAction->setChecked(true);
m_plasmaAction->trigger();
} else if (mode.toLower() == QLatin1String("windowmanager")) {
m_kwinAction->setChecked(true);
m_kwinAction->trigger();
}
}

Loading…
Cancel
Save