From 3f8f7eb45f318b8d114f18d727a903bf862a14e0 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Sat, 14 Sep 2013 03:30:01 +0400 Subject: [PATCH] fixed a bug introduced in the last several commits... Signed-off-by: Alex A. Naanou --- ui/data.js | 7 ++++++- ui/ui.js | 5 +++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ui/data.js b/ui/data.js index f4bcef87..940d8069 100755 --- a/ui/data.js +++ b/ui/data.js @@ -1535,6 +1535,8 @@ function getAllData(){ // NOTE: this will not update .current state... +// NOTE: when keep_ribbons is set, this may generate empty ribbons... +// // XXX should this set the .current to anything but null or the first elem??? function makeCroppedData(gids, keep_ribbons){ var res = { @@ -1563,14 +1565,17 @@ function makeCroppedData(gids, keep_ribbons){ } +// NOTE: if keep_ribbons is not set this will ALWAYS build a single ribbon +// data-set... function cropDataTo(gids, keep_ribbons){ var prev_state = DATA var cur = DATA.current + var r = getRibbonIndex() CROP_STACK.push(prev_state) DATA = makeCroppedData(gids, keep_ribbons) - cur = getGIDBefore(cur) + cur = getGIDBefore(cur, keep_ribbons ? r : 0) cur = cur == null ? gids[0] : cur DATA.current = cur diff --git a/ui/ui.js b/ui/ui.js index 9fd44c58..4f19e46e 100755 --- a/ui/ui.js +++ b/ui/ui.js @@ -115,6 +115,7 @@ function flashIndicator(direction){ } +// XXX need to get the real base ribbon.... function showRibbonIndicator(){ var cls = '.ribbon-indicator' var indicator = $(cls) @@ -150,8 +151,8 @@ function flashRibbonIndicator(){ return flashing_indicator .show() - .delay(100) - .fadeOut(300) + .delay(200) + .fadeOut(500) }