From b4516b0bacb68179eb6f7cbff9c6474ec03cc9ab Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Wed, 30 Sep 2009 10:21:58 +0200 Subject: BIG BIG commit removed: - last closed tabs feature - new tab page settings (unuseful, we need something better) implemented - new home page layout (needs love) - new about: protocol to load home page sections - preview images cache todo: - cleaning cache mechanism - bug fixing - add/remove to preferred actions --- src/CMakeLists.txt | 1 - src/history.cpp | 5 ++++ src/homepage.cpp | 69 +++++++++++++++++++++--------------------- src/homepage.h | 3 +- src/mainview.cpp | 10 ------- src/mainview.h | 4 --- src/previewimage.cpp | 22 ++++++++++---- src/previewimage.h | 8 +++-- src/rekonq.kcfg | 9 ++---- src/settings.cpp | 64 --------------------------------------- src/settings.h | 2 -- src/settings_newtabpage.ui | 74 ---------------------------------------------- src/webpluginfactory.cpp | 9 ++---- src/websnap.cpp | 11 +++---- src/websnap.h | 3 +- 15 files changed, 73 insertions(+), 221 deletions(-) delete mode 100644 src/settings_newtabpage.ui diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index c443de2e..11fc5c6b 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -33,7 +33,6 @@ KDE4_ADD_UI_FILES( rekonq_SRCS password.ui proxy.ui settings_general.ui - settings_newtabpage.ui settings_fonts.ui settings_proxy.ui settings_webkit.ui diff --git a/src/history.cpp b/src/history.cpp index da39c4be..7e5cb741 100644 --- a/src/history.cpp +++ b/src/history.cpp @@ -114,6 +114,11 @@ bool HistoryManager::historyContains(const QString &url) const void HistoryManager::addHistoryEntry(const QString &url) { QUrl cleanUrl(url); + + // don't store about: urls (home page related) + if(cleanUrl.scheme() == QString("about")) + return; + cleanUrl.setPassword(QString()); cleanUrl.setHost(cleanUrl.host().toLower()); HistoryItem item(cleanUrl.toString(), QDateTime::currentDateTime()); diff --git a/src/homepage.cpp b/src/homepage.cpp index c57661c4..5b8c9de2 100644 --- a/src/homepage.cpp +++ b/src/homepage.cpp @@ -82,7 +82,7 @@ QString HomePage::rekonqHomePage(const KUrl &url) if(url == KUrl("about:bookmarks")) speed = fillBookmarks(); if(url == KUrl("about:home") || url == KUrl("about:preferred")) - speed = speedDial(); + speed = fillPreferred(); QString html = QString(QLatin1String(file.readAll())) .arg(imagesPath) @@ -93,7 +93,7 @@ QString HomePage::rekonqHomePage(const KUrl &url) } -QString HomePage::speedDial() +QString HomePage::fillPreferred() { QStringList names = ReKonfig::previewNames(); QStringList urls = ReKonfig::previewUrls(); @@ -104,7 +104,6 @@ QString HomePage::speedDial() speed += "
"; speed += ""; speed += ""; - speed += ""; speed += ""; speed += "

"; speed += "" + names.at(i) + "
"; @@ -115,7 +114,6 @@ QString HomePage::speedDial() speed += "
"; speed += ""; speed += ""; - speed += ""; speed += ""; speed += "

"; speed += "" + names.at(i) + "
"; @@ -126,51 +124,54 @@ QString HomePage::speedDial() } -QString HomePage::recentlyClosedTabs() -{ - QString closed = "

" + i18n("Recently closed tabs") + "

"; - closed += ""; - return closed; -} - - QString HomePage::lastVisitedSites() { - QString history = "

" + i18n("Last 20 visited sites") + "

"; - history += "