summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2009-09-13 03:18:45 +0200
committerAndrea Diamantini <adjam7@gmail.com>2009-09-13 03:18:45 +0200
commit1cb0ff22c8d9f29bb3a0aee2b1b673efb1d556d6 (patch)
treec08b50a6c7512fc42a4dd913be44badd9ff03202 /src/mainwindow.cpp
parentSome "stupid" toolbars fixes (diff)
parentModified rekonq behaviour: (diff)
downloadrekonq-1cb0ff22c8d9f29bb3a0aee2b1b673efb1d556d6.tar.xz
Merge branch 'HomePage'
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp35
1 files changed, 16 insertions, 19 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index e7494c0e..1dc56f7a 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"
@@ -183,6 +184,10 @@ void MainWindow::setupToolbars()
void MainWindow::postLaunch()
{
+ // notification system
+ connect(m_view, SIGNAL(showStatusBarMessage(const QString&, Rekonq::Notify)), this, SLOT(notifyMessage(const QString&, Rekonq::Notify)));
+ connect(m_view, SIGNAL(linkHovered(const QString&)), this, SLOT(notifyMessage(const QString&)));
+
// --------- connect signals and slots
connect(m_view, SIGNAL(setCurrentTitle(const QString &)), this, SLOT(slotUpdateWindowTitle(const QString &)));
connect(m_view, SIGNAL(printRequested(QWebFrame *)), this, SLOT(printRequested(QWebFrame *)));
@@ -423,26 +428,8 @@ void MainWindow::setupSidePanel()
void MainWindow::slotUpdateConfiguration()
{
// ============== General ==================
- m_homePage = ReKonfig::homePage();
mainView()->showTabBar();
- // "status bar" messages (new notifyMessage system)
- if(ReKonfig::showUrlsPopup())
- {
- connect(m_view, SIGNAL(showStatusBarMessage(const QString&, Rekonq::Notify)),
- this, SLOT(notifyMessage(const QString&, Rekonq::Notify)));
- connect(m_view, SIGNAL(linkHovered(const QString&)),
- this, SLOT(notifyMessage(const QString&)));
- }
- else
- {
- disconnect(m_view, SIGNAL(showStatusBarMessage(const QString&, Rekonq::Notify)),
- this, SLOT(notifyMessage(const QString&, Rekonq::Notify)));
- disconnect(m_view, SIGNAL(linkHovered(const QString&)),
- this, SLOT(notifyMessage(const QString&)));
- }
-
-
// =========== Fonts ==============
QWebSettings *defaultSettings = QWebSettings::globalSettings();
@@ -752,7 +739,17 @@ void MainWindow::slotViewPageSource()
void MainWindow::slotHome()
{
- Application::instance()->loadUrl(KUrl(m_homePage));
+ WebView *w = currentTab();
+
+ if(ReKonfig::useNewTabPage())
+ {
+ HomePage p;
+ w->setHtml( p.rekonqHomePage(), QUrl());
+ }
+ else
+ {
+ w->load( QUrl(ReKonfig::homePage()) );
+ }
}