mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-20 20:01:28 +00:00
allow s, S, u hotkeys to work on selection instead of active article
This commit is contained in:
16
tt-rss.js
16
tt-rss.js
@@ -841,6 +841,7 @@ function hotkey_handler(e) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (keycode == 16) return; // ignore lone shift
|
if (keycode == 16) return; // ignore lone shift
|
||||||
|
if (keycode == 17) return; // ignore lone ctrl
|
||||||
|
|
||||||
if ((keycode == 70 || keycode == 67 || keycode == 71)
|
if ((keycode == 70 || keycode == 67 || keycode == 71)
|
||||||
&& !hotkey_prefix) {
|
&& !hotkey_prefix) {
|
||||||
@@ -966,27 +967,18 @@ function hotkey_handler(e) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (keycode == 83 && shift_key) { // S
|
if (keycode == 83 && shift_key) { // S
|
||||||
var id = getActiveArticleId();
|
selectionTogglePublished(undefined, false, true);
|
||||||
if (id) {
|
|
||||||
togglePub(id);
|
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (keycode == 83) { // s
|
if (keycode == 83) { // s
|
||||||
var id = getActiveArticleId();
|
selectionToggleMarked(undefined, false, true);
|
||||||
if (id) {
|
|
||||||
toggleMark(id);
|
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (keycode == 85) { // u
|
if (keycode == 85) { // u
|
||||||
var id = getActiveArticleId();
|
selectionToggleUnread(undefined, false, true)
|
||||||
if (id) {
|
|
||||||
toggleUnread(id);
|
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user