tweak moveToPost behaviour in unexpanded mode
This commit is contained in:
parent
f0540b598a
commit
79074013cb
|
@ -559,6 +559,11 @@ function moveToPost(mode, noscroll) {
|
|||
var prev_article = $("RROW-" + prev_id);
|
||||
var ctr = $("headlines-frame");
|
||||
|
||||
if (!getInitParam("cdm_expanded")) {
|
||||
cdmExpandArticle(prev_id);
|
||||
cdmScrollToArticleId(prev_id, true);
|
||||
} else {
|
||||
|
||||
if (!noscroll && article && article.offsetTop < ctr.scrollTop) {
|
||||
scrollArticle(-ctr.offsetHeight/3);
|
||||
} else if (!noscroll && prev_article &&
|
||||
|
@ -569,6 +574,8 @@ function moveToPost(mode, noscroll) {
|
|||
cdmExpandArticle(prev_id);
|
||||
cdmScrollToArticleId(prev_id, noscroll);
|
||||
}
|
||||
}
|
||||
|
||||
} else if (prev_id) {
|
||||
correctHeadlinesOffset(prev_id);
|
||||
view(prev_id, getActiveFeedId());
|
||||
|
@ -1365,7 +1372,10 @@ function cdmExpandArticle(id) {
|
|||
}
|
||||
|
||||
setActiveArticleId(id);
|
||||
|
||||
if (!getInitParam("cdm_expanded")) {
|
||||
cdmScrollToArticleId(id, true);
|
||||
}
|
||||
|
||||
elem = $("CICD-" + id);
|
||||
|
||||
|
|
Loading…
Reference in New Issue