improve hotkey buffer scrolling speed; bind viewport scrolling to shift-arrows
This commit is contained in:
parent
d5b82f3ebb
commit
d2db81a5f6
|
@ -1946,6 +1946,8 @@
|
|||
"c n" => "catchup_above",
|
||||
"*n" => "article_scroll_down",
|
||||
"*p" => "article_scroll_up",
|
||||
"*(38)|Shift+up" => "article_scroll_up",
|
||||
"*(40)|Shift+down" => "article_scroll_down",
|
||||
"a *w" => "toggle_widescreen",
|
||||
"e" => "email_article",
|
||||
"a q" => "close_article",
|
||||
|
|
|
@ -659,10 +659,14 @@ function hotkey_handler(e) {
|
|||
catchupRelativeToArticle(0);
|
||||
return false;
|
||||
case "article_scroll_down":
|
||||
scrollArticle(50);
|
||||
var ctr = $("content_insert") ? $("content_insert") : $("headlines-frame");
|
||||
|
||||
scrollArticle(ctr.offsetHeight/3);
|
||||
return false;
|
||||
case "article_scroll_up":
|
||||
scrollArticle(-50);
|
||||
var ctr = $("content_insert") ? $("content_insert") : $("headlines-frame");
|
||||
|
||||
scrollArticle(-ctr.offsetHeight/3);
|
||||
return false;
|
||||
case "close_article":
|
||||
closeArticlePanel();
|
||||
|
|
|
@ -560,11 +560,11 @@ function moveToPost(mode, noscroll) {
|
|||
var ctr = $("headlines-frame");
|
||||
|
||||
if (!noscroll && article && article.offsetTop < ctr.scrollTop) {
|
||||
scrollArticle(-ctr.offsetHeight/2);
|
||||
scrollArticle(-ctr.offsetHeight/3);
|
||||
} else if (!noscroll && prev_article &&
|
||||
prev_article.offsetTop < ctr.scrollTop) {
|
||||
cdmExpandArticle(prev_id);
|
||||
scrollArticle(-ctr.offsetHeight/2);
|
||||
scrollArticle(-ctr.offsetHeight/3);
|
||||
} else if (prev_id) {
|
||||
cdmExpandArticle(prev_id);
|
||||
cdmScrollToArticleId(prev_id, noscroll);
|
||||
|
|
Loading…
Reference in New Issue