diff --git a/classes/feeds.php b/classes/feeds.php
index c9e5ca496..b32521130 100755
--- a/classes/feeds.php
+++ b/classes/feeds.php
@@ -406,7 +406,7 @@ class Feeds extends Handler_Protected {
$reply['content'] .= "
";
$reply['content'] .= "
";
$reply['content'] .= "$marked_pic";
@@ -505,7 +505,7 @@ class Feeds extends Handler_Protected {
$tmp_content .= "
";
$tmp_content .= "";
$tmp_content .= "$marked_pic";
diff --git a/classes/pref/feeds.php b/classes/pref/feeds.php
index f47d24501..efc76701e 100755
--- a/classes/pref/feeds.php
+++ b/classes/pref/feeds.php
@@ -1435,7 +1435,7 @@ class Pref_Feeds extends Handler_Protected {
# id needed for selectTableRows()
print "
| ";
print "";
@@ -1500,7 +1500,7 @@ class Pref_Feeds extends Handler_Protected {
# id needed for selectTableRows()
print " | | ";
print "";
diff --git a/classes/pref/filters.php b/classes/pref/filters.php
index e48615395..f9b4bfb2a 100755
--- a/classes/pref/filters.php
+++ b/classes/pref/filters.php
@@ -429,7 +429,7 @@ class Pref_Filters extends Handler_Protected {
$data = htmlspecialchars(json_encode($line));
- print "".
+ print "".
"".$this->getRuleName($line)."".
"";
}
@@ -473,7 +473,7 @@ class Pref_Filters extends Handler_Protected {
$data = htmlspecialchars(json_encode($line));
- print "".
+ print "".
"".$this->getActionName($line)."".
"";
}
diff --git a/classes/pref/prefs.php b/classes/pref/prefs.php
index 82456f342..017f2e06c 100644
--- a/classes/pref/prefs.php
+++ b/classes/pref/prefs.php
@@ -799,7 +799,7 @@ class Pref_Prefs extends Handler_Protected {
$plugin_icon = $checked ? "plugin.png" : "plugin_disabled.png";
- print " | | ";
@@ -1023,7 +1023,7 @@ class Pref_Prefs extends Handler_Protected {
print " | ";
@@ -1050,7 +1050,7 @@ class Pref_Prefs extends Handler_Protected {
$edit_title = htmlspecialchars($line["title"]);
print " | ";
diff --git a/classes/pref/users.php b/classes/pref/users.php
index 1e6eae227..eda3e1a0e 100644
--- a/classes/pref/users.php
+++ b/classes/pref/users.php
@@ -419,7 +419,7 @@ class Pref_Users extends Handler_Protected {
$line["created"] = make_local_datetime($line["created"], false);
$line["last_login"] = make_local_datetime($line["last_login"], false);
- print " | ";
diff --git a/include/feedbrowser.php b/include/feedbrowser.php
index a0b1b6e8f..4f37241ea 100644
--- a/include/feedbrowser.php
+++ b/include/feedbrowser.php
@@ -53,7 +53,7 @@
$site_url = htmlspecialchars($line["site_url"]);
$subscribers = $line["subscribers"];
- $check_box = "";
@@ -73,7 +73,7 @@
$feed_url = htmlspecialchars($line["feed_url"]);
$site_url = htmlspecialchars($line["site_url"]);
- $check_box = "";
if ($line['articles_archived'] > 0) {
diff --git a/include/functions.php b/include/functions.php
index f6d09fe67..2ec42c7ee 100755
--- a/include/functions.php
+++ b/include/functions.php
@@ -1244,7 +1244,7 @@
"g t" => "goto_tagcloud",
"g *p" => "goto_prefs",
// "other" => array(
- "(9)|Tab" => "select_article_cursor", // tab
+ "r" => "select_article_cursor",
"c l" => "create_label",
"c f" => "create_filter",
"c s" => "collapse_sidebar",
diff --git a/js/functions.js b/js/functions.js
index ce6d7aca9..033933794 100755
--- a/js/functions.js
+++ b/js/functions.js
@@ -53,8 +53,8 @@ Array.prototype.remove = function(s) {
}
};
-const ListUtils = {
- onChecked: function(elem) {
+const Lists = {
+ onRowChecked: function(elem) {
// account for dojo checkboxes
elem = elem.domNode || elem;
@@ -62,11 +62,23 @@ const ListUtils = {
}
};
+const Tables = {
+ onRowChecked: function(elem) {
+ // account for dojo checkboxes
+ elem = elem.domNode || elem;
+
+ elem.up("tr").toggleClassName("Selected");
+ }
+}
+
const Utils = {
_rpc_seq: 0,
hotkey_prefix: 0,
hotkey_prefix_pressed: false,
hotkey_prefix_timeout: 0,
+ urlParam: function(param) {
+ return String(window.location.href).parseQuery()[param];
+ },
next_seq: function() {
this._rpc_seq += 1;
return this._rpc_seq;
@@ -988,43 +1000,6 @@ function getCookie(name) {
return unescape(dc.substring(begin + prefix.length, end));
}
-function toggleSelectRowById(sender, id) {
- const row = $(id);
- return toggleSelectRow(sender, row);
-}
-
-/* this is for dijit Checkbox */
-function toggleSelectRow2(sender, row, is_cdm) {
-
- if (!row)
- if (!is_cdm)
- row = sender.domNode.parentNode.parentNode;
- else
- row = sender.domNode.parentNode.parentNode.parentNode; // oh ffs
-
- if (sender.checked && !row.hasClassName('Selected'))
- row.addClassName('Selected');
- else
- row.removeClassName('Selected');
-
- if (typeof Headlines != "undefined")
- Headlines.updateSelectedPrompt();
-}
-
-
-function toggleSelectRow(sender, row) {
-
- if (!row) row = sender.parentNode.parentNode;
-
- if (sender.checked && !row.hasClassName('Selected'))
- row.addClassName('Selected');
- else
- row.removeClassName('Selected');
-
- if (typeof Headlines != "undefined")
- Headlines.updateSelectedPrompt();
-}
-
// noinspection JSUnusedGlobalSymbols
function displayIfChecked(checkbox, elemId) {
if (checkbox.checked) {
@@ -1034,10 +1009,6 @@ function displayIfChecked(checkbox, elemId) {
}
}
-function getURLParam(param){
- return String(window.location.href).parseQuery()[param];
-}
-
// noinspection JSUnusedGlobalSymbols
function closeInfoBox() {
const dialog = dijit.byId("infoBox");
@@ -1140,7 +1111,7 @@ const Filters = {
new dijit.form.CheckBox({
onChange: function () {
- ListUtils.onChecked(this);
+ Lists.onRowChecked(this);
},
}, cb);
@@ -1189,7 +1160,7 @@ const Filters = {
new dijit.form.CheckBox({
onChange: function () {
- ListUtils.onChecked(this);
+ Lists.onRowChecked(this);
},
}, cb);
diff --git a/js/prefs.js b/js/prefs.js
index 40068b95c..f12c31441 100755
--- a/js/prefs.js
+++ b/js/prefs.js
@@ -69,17 +69,17 @@ const App = {
Utils.setLoadingProgress(50);
notify("");
- let tab = getURLParam('tab');
+ let tab = Utils.urlParam('tab');
if (tab) {
tab = dijit.byId(tab + "Tab");
if (tab) dijit.byId("pref-tabs").selectChild(tab);
}
- const method = getURLParam('method');
+ const method = Utils.urlParam('method');
if (method == 'editFeed') {
- const param = getURLParam('methodparam');
+ const param = Utils.urlParam('methodparam');
window.setTimeout(function () {
CommonDialogs.editFeed(param)
diff --git a/js/tt-rss.js b/js/tt-rss.js
index b337e0ae5..71bb2337a 100644
--- a/js/tt-rss.js
+++ b/js/tt-rss.js
@@ -414,7 +414,7 @@ const App = {
if (!row.hasClassName("active"))
cb.attr("checked", !cb.attr("checked"));
- toggleSelectRowById(cb, "RROW-" + id);
+ Headlines.onRowChecked(cb);
return false;
}
}
diff --git a/js/viewfeed.js b/js/viewfeed.js
index 93bc56c9d..e7703ed55 100755
--- a/js/viewfeed.js
+++ b/js/viewfeed.js
@@ -1109,6 +1109,14 @@ const Headlines = {
return rv;
},
+ onRowChecked: function(elem) {
+ // account for dojo checkboxes
+ elem = elem.domNode || elem;
+
+ elem.up("div[id*=RROW]").toggleClassName("Selected");
+
+ this.updateSelectedPrompt();
+ },
select: function(mode) {
// mode = all,none,unread,invert,marked,published
let query = "#headlines-frame > div[id*=RROW]";