summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2009-09-13 03:14:55 +0200
committerAndrea Diamantini <adjam7@gmail.com>2009-09-13 03:14:55 +0200
commit09567d9fbf6e034319bbdf7820f4bceac42cee12 (patch)
tree94352260f033ed1c1dd24230a0a30b071e8b3ada /src/mainwindow.cpp
parentnotification system made default and no more "unsettable" (diff)
downloadrekonq-09567d9fbf6e034319bbdf7820f4bceac42cee12.tar.xz
Modified rekonq behaviour:
HomePage has 2 choices: usual home page vs new tab page new tab has 3: new tabp page, home page, blank page
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp19
1 files changed, 18 insertions, 1 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index da51ac2a..099a463e 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -45,6 +45,7 @@
#include "findbar.h"
#include "sidepanel.h"
#include "urlbar.h"
+#include "homepage.h"
// Ui Includes
#include "ui_cleardata.h"
@@ -260,7 +261,7 @@ void MainWindow::setupActions()
a = KStandardAction::fullScreen(this, SLOT(slotViewFullScreen(bool)), this, actionCollection());
a->setShortcut(KShortcut(Qt::Key_F11, Qt::CTRL + Qt::SHIFT + Qt::Key_F));
- KStandardAction::home(m_view, SLOT(slotHome()), actionCollection());
+ KStandardAction::home(this, SLOT(slotHome()), actionCollection());
KStandardAction::preferences(this, SLOT(slotPreferences()), actionCollection());
// WEB Actions (NO KStandardActions..)
@@ -736,6 +737,22 @@ void MainWindow::slotViewPageSource()
}
+void MainWindow::slotHome()
+{
+ WebView *w = currentTab();
+
+ if(ReKonfig::useNewTabPage())
+ {
+ HomePage p;
+ w->setHtml( p.rekonqHomePage(), QUrl());
+ }
+ else
+ {
+ w->load( QUrl(ReKonfig::homePage()) );
+ }
+}
+
+
void MainWindow::slotToggleInspector(bool enable)
{
QWebSettings::globalSettings()->setAttribute(QWebSettings::DeveloperExtrasEnabled, enable);