From e7eb85615b416300191d9c52d5bafc65c619bc78 Mon Sep 17 00:00:00 2001 From: Lucian Branescu Mihaila Date: Tue, 13 Jul 2010 20:27:19 +0000 Subject: Speculative fixes for loading from journal and loading progress. Not tested yet. --- (limited to 'browser.py') diff --git a/browser.py b/browser.py index c80fe8b..d311edf 100644 --- a/browser.py +++ b/browser.py @@ -243,10 +243,9 @@ class Browser(webkit.WebView): return entries def set_session(self, data): - history = webkit.WebBackForwardList() + history = self.get_back_forward_list() # webkitgtk+ v1.3.1+ - #history = self.get_back_forward_list() #history.clear() # temporary workaround to clear history @@ -260,10 +259,10 @@ class Browser(webkit.WebView): entry = webkit.WebHistoryItem(entry_dict['url'], entry_dict['title']) history.add_item(entry) - #if data: - # history.go_to_item(len(data) - 1) - #else: - # self.load_uri('about:blank') + if data: + history.go_to_item(history.get_current_item()) + else: + self.load_uri('about:blank') class PopupDialog(gtk.Window): def __init__(self): -- cgit v0.9.1