Commit 481f39fb authored by Maximilian Schiller's avatar Maximilian Schiller
Browse files

Fix missing main menu after disabling systray icon

After the systray icon is disabled the titlebar still references the old
menu. With this patch the titebar gets updated with the new menu.
parent a0b08cb1
......@@ -864,6 +864,7 @@ void MainWindow::applySettings()
// add a new one
m_menu = new QMenu(this);
setupMenu();
m_titleBar->updateMenu();
} else if (Settings::showSystrayIcon() && !m_notifierItem) {
m_notifierItem = new KStatusNotifierItem(this);
m_notifierItem->setStandardActionsEnabled(false);
......
......@@ -185,6 +185,11 @@ void TitleBar::updateMask()
setMask(mask);
}
void TitleBar::updateMenu()
{
m_menuButton->setMenu(m_mainWindow->menu());
}
void TitleBar::setFocusButtonState(bool checked)
{
m_focusButton->setChecked(checked);
......
......@@ -44,6 +44,7 @@ class TitleBar : public QWidget
void applySkin();
void updateMask();
void updateMenu();
QString title();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment