}
}
+ if (keycode == 73 && shift_key) { // shift + i
+ if (document.getElementById("subtoolbar_search")) {
+ if (Element.visible("subtoolbar_search")) {
+ Element.hide("subtoolbar_search");
+ Element.show("subtoolbar_ftitle");
+ setTimeout("Element.focus('subtoolbar_search_box')", 100);
+ } else {
+ Element.show("subtoolbar_search");
+ Element.hide("subtoolbar_ftitle");
+ }
+ }
+ }
+
if (typeof localHotkeyHandler != 'undefined') {
try {
return localHotkeyHandler(e);
}
for (i = 0; i < content.rows.length; i++) {
- if (!classcheck || content.rows[i].className.match(classcheck)) {
+ if (Element.visible(content.rows[i])) {
+ if (!classcheck || content.rows[i].className.match(classcheck)) {
+
+ if (content.rows[i].id.match(prefix)) {
+ selectTableRow(content.rows[i], do_select);
+
+ var row_id = content.rows[i].id.replace(prefix, "");
+ var check = document.getElementById(check_prefix + row_id);
+
+ if (check) {
+ check.checked = do_select;
+ }
+ } else if (reset_others) {
+ selectTableRow(content.rows[i], false);
+
+ var row_id = content.rows[i].id.replace(prefix, "");
+ var check = document.getElementById(check_prefix + row_id);
+
+ if (check) {
+ check.checked = false;
+ }
- if (content.rows[i].id.match(prefix)) {
- selectTableRow(content.rows[i], do_select);
-
- var row_id = content.rows[i].id.replace(prefix, "");
- var check = document.getElementById(check_prefix + row_id);
-
- if (check) {
- check.checked = do_select;
}
} else if (reset_others) {
selectTableRow(content.rows[i], false);
-
+
var row_id = content.rows[i].id.replace(prefix, "");
var check = document.getElementById(check_prefix + row_id);
-
+
if (check) {
check.checked = false;
}
-
- }
- } else if (reset_others) {
- selectTableRow(content.rows[i], false);
-
- var row_id = content.rows[i].id.replace(prefix, "");
- var check = document.getElementById(check_prefix + row_id);
-
- if (check) {
- check.checked = false;
+
}
-
}
}
}
print "<td class=\"headlineTitle$rtl_cpart\">";
- print "<span class=\"headlineInnerTitle\">";
+ print "<span id=\"subtoolbar_search\"
+ style=\"display : none\">Search: <input
+ id=\"subtoolbar_search_box\"
+ onblur=\"javascript:enableHotkeys();\"
+ onfocus=\"javascript:disableHotkeys();\"
+ onchange=\"subtoolbarSearch()\"
+ onkeyup=\"subtoolbarSearch()\" type=\"search\"></span>";
+
+ print "<span id=\"subtoolbar_ftitle\">";
if ($feed_site_url) {
if (!$bottom) {
print " [$user_page_offset] ";
}
- print "</span>";
-
if (!$bottom && !$disable_feed) {
print "
<a target=\"_new\"
} else if ($feed_small_icon) {
print "<img class=\"noborder\" alt=\"\" src=\"images/$feed_small_icon\">";
}
-
+
+ print "</span>";
+
print "</td>";
print "</tr></table>";
print "<td class='hlContent$hlc_suffix' valign='middle'>";
- print "<a href=\"javascript:view($id,$feed_id);\">" .
+ print "<a id=\"RTITLE-$id\" href=\"javascript:view($id,$feed_id);\">" .
$line["title"];
if (get_pref($link, 'SHOW_CONTENT_PREVIEW')) {
markHeadline(ids[i]);
}
+ subtoolbarSearch();
+
} else {
debug("no new headlines received");
}
}
+function subtoolbarSearch() {
+
+ try {
+
+ var q = document.getElementById("subtoolbar_search_box");
+
+ if (!q) return;
+
+ q = q.value.toUpperCase();
+
+ var ids = false;
+
+ if (document.getElementById("headlinesList")) {
+ ids = getVisibleHeadlineIds();
+ } else {
+ ids = cdmGetVisibleArticles();
+ }
+ for (var i = 0; i < ids.length; i++) {
+ var title = document.getElementById("RTITLE-" + ids[i]);
+
+ if (title) {
+ if (!title.innerHTML.toUpperCase().match(q)) {
+ Element.hide(document.getElementById("RROW-" + ids[i]));
+ } else {
+ Element.show(document.getElementById("RROW-" + ids[i]));
+ }
+ }
+ }
+
+ } catch (e) {
+ exception_error("subtoolbarSearch", e);
+ }
+
+}