[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [rekonq] src: Reopen the tabs lasting with "rekonq pages" (about urls, pdfs, etc..)
From:       Andrea Diamantini <adjam7 () gmail ! com>
Date:       2012-06-19 16:11:30
Message-ID: 20120619161130.472A3A60A9 () git ! kde ! org
[Download RAW message or body]

Git commit 7cd1fd1b92283096b240effe81069e3912bedec6 by Andrea Diamantini.
Committed on 19/06/2012 at 18:11.
Pushed by adjam into branch 'master'.

Reopen the tabs lasting with "rekonq pages" (about urls, pdfs, etc..)

WARNING: Needs testing...

BUG: 302017

M  +5    -3    src/mainview.cpp

http://commits.kde.org/rekonq/7cd1fd1b92283096b240effe81069e3912bedec6

diff --git a/src/mainview.cpp b/src/mainview.cpp
index e3e8298..3ec838f 100644
--- a/src/mainview.cpp
+++ b/src/mainview.cpp
@@ -452,13 +452,14 @@ void MainView::closeTab(int index, bool del)
 
     if (!tabToClose->url().isEmpty()
             && tabToClose->url().scheme() != QL1S("about")
-            && !tabToClose->page()->isOnRekonqPage()
             && !QWebSettings::globalSettings()->testAttribute(QWebSettings::PrivateBrowsingEnabled)
        )
     {
         const int recentlyClosedTabsLimit = 8;
         TabHistory history(tabToClose->view()->history());
-
+        history.title = tabToClose->view()->title();
+        history.url = tabToClose->url().url();
+        
         m_recentlyClosedTabs.removeAll(history);
         if (m_recentlyClosedTabs.count() == recentlyClosedTabsLimit)
             m_recentlyClosedTabs.removeLast();
@@ -686,7 +687,8 @@ void MainView::restoreClosedTab(int i, bool inNewTab)
                     ;
 
     history.applyHistory(view->history());
-
+    view->load(KUrl(history.url));
+    
     // just to get sure...
     m_recentlyClosedTabs.removeAll(history);
 }
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic