From 22ffd3743ce7b67b8cd1403d428c3b57b806fdb8 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Tue, 22 Nov 2016 23:41:38 +0300 Subject: [PATCH] cleanup... Signed-off-by: Alex A. Naanou --- ui (gen4)/imagegrid/ribbons.js | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/ui (gen4)/imagegrid/ribbons.js b/ui (gen4)/imagegrid/ribbons.js index beaed1b6..829c0798 100755 --- a/ui (gen4)/imagegrid/ribbons.js +++ b/ui (gen4)/imagegrid/ribbons.js @@ -764,6 +764,7 @@ var RibbonsPrototype = { // .getRibbonSet(true) // -> ribbon-set // + // XXX revise... getRibbonSet: function(create){ // ribbon set... var ribbon_set = this.viewer.find('.ribbon-set') @@ -1860,14 +1861,9 @@ var RibbonsPrototype = { // NOTE: another way to remove a ribbon or an image just to use // .getRibbon(..).remove() and .getImage(...).remove() respectivly. clear: function(gids){ - if(gids == 'full'){ - this.getRibbonSet().remove() - // clear all... - } else if(gids == null || gids == '*'){ - this.preventTransitions() - this.dom.setOffset(this.getRibbonSet(), 0, 0).children().detach() - this.restoreTransitions() + if(gids == 'full' || gids == '*' || gids == null){ + this.getRibbonSet().remove() // clear one or more gids... } else {