Commit e8804c18 authored by Albert Astals Cid's avatar Albert Astals Cid

Update m_showMenuBarAction on the proper time

BUG: 178020

svn path=/trunk/KDE/kdegraphics/okular/; revision=898742
parent 2eecd577
......@@ -87,7 +87,6 @@ void Shell::init()
createGUI(m_part);
m_showToolBarAction = static_cast<KToggleAction*>(toolBarMenuAction());
m_doc = qobject_cast<KDocumentViewer*>(m_part);
m_showMenuBarAction->setChecked( menuBar()->isVisible() );
}
connect( this, SIGNAL( restoreDocument(const KConfigGroup&) ),m_part, SLOT( restoreDocument(const KConfigGroup&)));
......@@ -271,6 +270,13 @@ void Shell::setFullScreen( bool useFullScreen )
setWindowState( windowState() & ~Qt::WindowFullScreen ); // reset
}
void Shell::showEvent(QShowEvent *e)
{
m_showMenuBarAction->setChecked( menuBar()->isVisible() );
KParts::MainWindow::showEvent(e);
}
void Shell::slotUpdateFullScreen()
{
if(m_fullScreenAction->isChecked())
......
......@@ -67,6 +67,8 @@ protected:
void writeSettings();
void setFullScreen( bool );
void showEvent(QShowEvent *event);
private slots:
void fileOpen();
......
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