set base uri for load_string
This commit is contained in:
parent
1742a9cdba
commit
6e0f06bab5
1 changed files with 3 additions and 3 deletions
|
@ -179,12 +179,12 @@ class ContentPane (Gtk.Notebook):
|
||||||
view = child.get_child()
|
view = child.get_child()
|
||||||
view.load_uri(text)
|
view.load_uri(text)
|
||||||
|
|
||||||
def load_string (self, text):
|
def load_string (self, text, baseuri):
|
||||||
"""load the given uri in the current web view"""
|
"""load the given uri in the current web view"""
|
||||||
#child = self.get_nth_page(self.get_current_page())
|
#child = self.get_nth_page(self.get_current_page())
|
||||||
child = self.get_nth_page(0);
|
child = self.get_nth_page(0);
|
||||||
view = child.get_child()
|
view = child.get_child()
|
||||||
view.load_string(text, "text/html", "utf-8", "")
|
view.load_string(text, "text/html", "utf-8", baseuri)
|
||||||
|
|
||||||
def back(self):
|
def back(self):
|
||||||
child = self.get_nth_page(self.get_current_page())
|
child = self.get_nth_page(self.get_current_page())
|
||||||
|
@ -1031,7 +1031,7 @@ class FeedReaderWindow(Gtk.Window):
|
||||||
content_string = "<h1>%s</h1><p>%s</p>"%(item['title'], ', '.join(item['categories']))
|
content_string = "<h1>%s</h1><p>%s</p>"%(item['title'], ', '.join(item['categories']))
|
||||||
else:
|
else:
|
||||||
content_string = "<h1>%s</h1>"%item['title']
|
content_string = "<h1>%s</h1>"%item['title']
|
||||||
content_pane.load_string(content_string+item['content'])
|
content_pane.load_string(content_string+item['content'], item['link'])
|
||||||
toolbar.location_set_text(item['link'])
|
toolbar.location_set_text(item['link'])
|
||||||
self.set_title(_("PyFeRea - %s")%item['title'])
|
self.set_title(_("PyFeRea - %s")%item['title'])
|
||||||
feedtree.update_view_all()
|
feedtree.update_view_all()
|
||||||
|
|
Loading…
Reference in a new issue