diff FeedSettings.py @ 77:d292ab61ed6f

Add another setting to feed: when opening a feed entry in browser, you can force opening it in an external browser now. This is because some sites just crash the QWebView.
author Dirk Olmes <dirk@xanthippe.ping.de>
date Sat, 14 Aug 2010 02:53:49 +0200
parents 6bc6899f3330
children d11c3f71ac40
line wrap: on
line diff
--- a/FeedSettings.py	Wed Aug 11 03:59:33 2010 +0200
+++ b/FeedSettings.py	Sat Aug 14 02:53:49 2010 +0200
@@ -14,6 +14,11 @@
     def initUi(self):
         self.ui.feedTitle.setText(self.feed.title)
         self.ui.autoLoadArticle.setChecked(self.feed.auto_load_entry_link)
+        self.ui.alwaysOpenInBrowser.setChecked(self.feed.always_open_in_browser)
+
+    def editingTitleFinished(self):
+        title = str(self.ui.feedTitle.text())
+        self.feed.title = title
 
     def autoLoadArticleChanged(self, change):
         if change:
@@ -21,6 +26,12 @@
         else:
             self.feed.auto_load_entry_link = False
 
+    def alwaysOpenInExternalBrowser(self, change):
+        if change:
+            self.feed.always_open_in_browser = True
+        else:
+            self.feed.always_open_in_browser = False
+
     def accept(self):
         self.session.commit()
         QtGui.QDialog.accept(self)
@@ -28,7 +39,3 @@
     def reject(self):
         self.session.rollback()
         QtGui.QDialog.reject(self)
-
-    def editingTitleFinished(self):
-        title = str(self.ui.feedTitle.text())
-        self.feed.title = title