From f2372797940d2e2eea16592cbb855fd4ec828fca Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Thu, 2 Apr 2009 02:01:43 +0200 Subject: Added show/hide menubar action --- src/mainwindow.cpp | 9 +++++++++ src/mainwindow.h | 1 + src/rekonqui.rc | 16 +++++++++++++--- 3 files changed, 23 insertions(+), 3 deletions(-) diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 566a1b45..bae54d94 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -194,6 +194,7 @@ void MainWindow::setupActions() KStandardAction::fullScreen(this, SLOT(slotViewFullScreen(bool)), this, actionCollection()); KStandardAction::home(this, SLOT(slotHome()), actionCollection()); KStandardAction::preferences(this, SLOT(slotPreferences()), actionCollection()); + KStandardAction::showMenubar(this, SLOT(slotShowMenubar(bool)), actionCollection()); // WEB Actions (NO KStandardActions..) KStandardAction::redisplay(m_view, SLOT(slotWebReload()), actionCollection()); @@ -806,3 +807,11 @@ void MainWindow::geometryChangeRequested(const QRect &geometry) setGeometry(geometry); } + +void MainWindow::slotShowMenubar(bool enable) +{ + if(enable) + menuBar()->show(); + else + menuBar()->hide(); +} \ No newline at end of file diff --git a/src/mainwindow.h b/src/mainwindow.h index c12f8fce..9e64022e 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -112,6 +112,7 @@ private slots: void slotToggleInspector(bool enable); // Settings Menu slots + void slotShowMenubar(bool enable); void slotPreferences(); private: diff --git a/src/rekonqui.rc b/src/rekonqui.rc index dae6c07e..368c9226 100644 --- a/src/rekonqui.rc +++ b/src/rekonqui.rc @@ -1,6 +1,6 @@ - + @@ -57,13 +57,23 @@ - +&Tools - +&Settings + + + + + + + + + + -- cgit v1.2.1