From 7415fcf2129c4ac0cfd814b0beb917e2372447f1 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Thu, 11 Jul 2013 12:28:24 +0400 Subject: [PATCH] enable floating title for expandable combined mode, minor expandable mode fixes --- css/cdm.css | 4 ++++ js/viewfeed.js | 8 +++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/css/cdm.css b/css/cdm.css index c16cf28f..98fd4edf 100644 --- a/css/cdm.css +++ b/css/cdm.css @@ -110,6 +110,10 @@ div.cdm.expandable div.cdmHeader span.titleWrap { max-width : 500px; } +div.cdm.expandable.active div.cdmHeader span.titleWrap { + white-space : normal; +} + div.cdm.expandable div.cdmHeader a.title { font-weight : bold; color : #555; diff --git a/js/viewfeed.js b/js/viewfeed.js index e23db86b..1785fe3f 100644 --- a/js/viewfeed.js +++ b/js/viewfeed.js @@ -1315,7 +1315,7 @@ function headlines_scroll_handler(e) { if (hsp) hsp.innerHTML = ""; } - if (getInitParam("cdm_expanded") && isCdmMode()) { + if (isCdmMode()) { updateFloatingTitle(); } @@ -1489,6 +1489,12 @@ function cdmCollapseArticle(event, id, unmark) { if (event) Event.stop(event); PluginHost.run(PluginHost.HOOK_ARTICLE_COLLAPSED, id); + + if (row.offsetTop < $("headlines-frame").scrollTop) + scrollToRowId(row.id); + + Element.hide("floatingTitle"); + $("floatingTitle").setAttribute("rowid", false); } } catch (e) { -- 2.39.5