summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2010-07-19 20:27:55 +0200
committerAndrea Diamantini <adjam7@gmail.com>2010-07-20 14:13:12 +0200
commit62308d3f5b79322379bd3594c45d15b6e7be9099 (patch)
tree0107edc53220e789396f8cd31460023724a3bcf2
parent- Performance improvements (partial updates of the tree) (diff)
downloadrekonq-62308d3f5b79322379bd3594c45d15b6e7be9099.tar.xz
Remove home && bookmarks buttons
Let (eventual) bookmarks menu && tools menu having a shortcut: ALT+B for bookmarks && ALT+T for Tools
-rw-r--r--src/mainwindow.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 0deeb15b..81eff496 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -196,15 +196,20 @@ void MainWindow::setupToolbars()
m_mainBar->addAction(actionByName(KStandardAction::name(KStandardAction::Forward)));
m_mainBar->addSeparator();
m_mainBar->addAction(actionByName( QL1S("stop_reload") ));
- m_mainBar->addAction(actionByName(KStandardAction::name(KStandardAction::Home)));
+// m_mainBar->addAction(actionByName(KStandardAction::name(KStandardAction::Home)));
// location bar
KAction *urlBarAction = new KAction(this);
urlBarAction->setDefaultWidget(m_view->widgetBar());
m_mainBar->addAction(urlBarAction);
- m_mainBar->addAction(actionByName( QL1S("bookmarksActionMenu") ));
+// m_mainBar->addAction(actionByName( QL1S("bookmarksActionMenu") ));
+ connect(actionByName(QL1S("bookmarksActionMenu")), SIGNAL(triggered()),
+ qobject_cast<QToolButton*>(m_mainBar->widgetForAction(actionByName(QL1S("bookmarksActionMenu")))), SLOT(showMenu()));
+
m_mainBar->addAction(actionByName( QL1S("rekonq_tools") ));
+ connect(actionByName(QL1S("rekonq_tools")), SIGNAL(triggered()),
+ qobject_cast<QToolButton*>(m_mainBar->widgetForAction(actionByName(QL1S("rekonq_tools")))), SLOT(showMenu()));
m_mainBar->show(); // this just to fix reopening rekonq after fullscreen close
@@ -448,6 +453,8 @@ void MainWindow::setupActions()
KActionMenu *bmMenu = Application::bookmarkProvider()->bookmarkActionMenu(this);
bmMenu->setIcon(KIcon("bookmarks"));
bmMenu->setDelayed(false);
+ bmMenu->setShortcutConfigurable(true);
+ bmMenu->setShortcut( KShortcut(Qt::ALT + Qt::Key_B) );
actionCollection()->addAction(QL1S("bookmarksActionMenu"), bmMenu);
@@ -465,7 +472,9 @@ void MainWindow::setupTools()
kDebug() << "setup tools...";
KActionMenu *toolsMenu = new KActionMenu(KIcon("configure"), i18n("&Tools"), this);
toolsMenu->setDelayed(false);
-
+ toolsMenu->setShortcutConfigurable(true);
+ toolsMenu->setShortcut( KShortcut(Qt::ALT + Qt::Key_T) );
+
toolsMenu->addAction(actionByName(KStandardAction::name(KStandardAction::Open)));
toolsMenu->addAction(actionByName(KStandardAction::name(KStandardAction::SaveAs)));
toolsMenu->addAction(actionByName(KStandardAction::name(KStandardAction::Print)));