summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2012-07-14 12:03:31 +0200
committerAndrea Diamantini <adjam7@gmail.com>2012-07-14 12:03:31 +0200
commite1dc349d6bc117b5db8b8229804c3600ae57da0a (patch)
tree9a83c9e8d7f984fbfaf335ee8ece31607d9d12d7 /src/mainwindow.cpp
parentSave a site snapshot when adding a favorite via the urlbar (diff)
downloadrekonq-e1dc349d6bc117b5db8b8229804c3600ae57da0a.tar.xz
Review boomarks management
Maybe this is a bit risky before release, but this lets us adding a bookmarks shortcut (CTRL+D) as used in the major browsers. With this commit, rekonq doubles this behavior. BUG: 303445
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index a3b222b3..ad11e1af 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -401,6 +401,11 @@ void MainWindow::setupActions()
tabAction->setDelayed(false);
actionCollection()->addAction(QL1S("tab_list"), tabAction);
+ // ============================== Bookmark =======================================
+ a = KStandardAction::addBookmark(this, SLOT(bookmarkCurrentPage()), actionCollection());
+ KShortcut bkShortcut(Qt::CTRL + Qt::Key_D);
+ a->setShortcut(bkShortcut);
+
//================================Download========================================
a = new KAction(KIcon("download"), i18n("Downloads"), this);
a->setShortcut(KShortcut(Qt::CTRL + Qt::Key_J));
@@ -1669,3 +1674,9 @@ void MainWindow::loadCheckedUrl(const KUrl& url, const Rekonq::OpenType& type, Q
}
}
}
+
+
+void MainWindow::bookmarkCurrentPage()
+{
+ currentTab()->urlBar()->manageBookmarks();
+}