]> git.wh0rd.org Git - tt-rss.git/commitdiff
fix row selection on editFeed()
authorAndrew Dolgov <fox@madoka.spb.ru>
Sun, 25 Dec 2005 13:43:31 +0000 (14:43 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Sun, 25 Dec 2005 13:43:31 +0000 (14:43 +0100)
functions.js
prefs.js

index 60fd9da640ef14b4b3e800abcedcf2896d8378de..e408fb8d7c10b52fed8dadec3729c81f591a585c 100644 (file)
@@ -536,6 +536,26 @@ function selectTableRow(r, do_select) {
        }
 }
 
+function selectTableRowById(elem_id, check_id, do_select) {
+
+       try {
+
+               var row = document.getElementById(elem_id);
+
+               if (row) {
+                       selectTableRow(row, do_select);
+               }               
+
+               var check = document.getElementById(check_id);
+
+               if (check) {
+                       check.checked = do_select;
+               }
+       } catch (e) {
+               exception_error("selectTableRowById", e);
+       }
+}
+
 function selectTableRowsByIdPrefix(content_id, prefix, check_prefix, do_select, 
        classcheck) {
 
index 695b1abbf356c4c53ba7f36b3f85d8bf9c2b89a5..89ad81d38c13ed823820a54f78ccd51a48c6c538 100644 (file)
--- a/prefs.js
+++ b/prefs.js
@@ -401,7 +401,10 @@ function editFeed(feed) {
        xmlhttp.send(null); */
 
        selectTableRowsByIdPrefix('prefFeedList', 'FEEDR-', 'FRCHK-', false);
-       selectTableRowsByIdPrefix('prefFeedList', 'FEEDR-'+feed, 'FRCHK-'+feed, true);
+//     selectTableRowsByIdPrefix('prefFeedList', 'FEEDR-'+feed, 'FRCHK-'+feed, 
+//             true, false);
+
+       selectTableRowById('FEEDR-'+feed, 'FRCHK-'+feed, true);
 
        xmlhttp.open("GET", "backend.php?op=pref-feeds&subop=editfeed&id=" +
                param_escape(active_feed), true);