]> git.wh0rd.org Git - tt-rss.git/commitdiff
misc feed edit dialog fixes
authorAndrew Dolgov <fox@fakecake.org>
Sat, 20 Nov 2010 12:36:42 +0000 (15:36 +0300)
committerAndrew Dolgov <fox@fakecake.org>
Sat, 20 Nov 2010 12:36:42 +0000 (15:36 +0300)
functions.js
tt-rss.js

index 5e3156126082094a38d95b8e2de35084ec26cf5a..e303c40491352ac2ab7e3fe8d44a20031c42906e 100644 (file)
@@ -1564,8 +1564,10 @@ function getSelectedTableRowIds(id) {
 }
 
 function editFeed(feed, event) {
-
        try {
+               if (feed <= 0)
+                       return alert(__("You can't edit this kind of feed."));
+
                var query = "backend.php?op=pref-feeds&subop=editfeed&id=" +
                        param_escape(feed);
 
index 1559530b8a4854621421921b3b51da18b0524cfd..4ab357363b62a465f54f944cbfb56baf2e3eab2a 100644 (file)
--- a/tt-rss.js
+++ b/tt-rss.js
@@ -376,7 +376,11 @@ function quickMenuGo(opid) {
                }
 
                if (opid == "qmcEditFeed") {
-                       editFeed(getActiveFeedId());
+                       if (activeFeedIsCat())
+                               alert(__("You can't edit this kind of feed."));
+                       else
+                               editFeed(getActiveFeedId());
+                       return;
                }
        
                if (opid == "qmcRemoveFeed") {
@@ -843,7 +847,13 @@ function hotkey_handler(e) {
                        }
 
                        if (keycode == 69) { // e
-                               editFeed(getActiveFeedId());
+
+                               if (activeFeedIsCat())
+                                       alert(__("You can't edit this kind of feed."));
+                               else
+                                       editFeed(getActiveFeedId());
+                               return;
+
                                return false;
                        }