From d41fbee0dbfa9eb39f1e32561e9dce9d351bf457 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Sun, 24 Apr 2016 17:35:33 +0300 Subject: [PATCH] cleanup and doc... Signed-off-by: Alex A. Naanou --- ui (gen4)/features/ui-single-image.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/ui (gen4)/features/ui-single-image.js b/ui (gen4)/features/ui-single-image.js index 811a9aa4..12c1b844 100755 --- a/ui (gen4)/features/ui-single-image.js +++ b/ui (gen4)/features/ui-single-image.js @@ -63,14 +63,18 @@ var core = require('features/core') // . | | . - image block same proportion as image // . | | . - we just change scale // . | | . - drag enabled -// . | | . +// . | | . XXX not done... // . +---------------+ . // . . // + - - - - - - - - - + // // // XXX should this be an action??? -// XXX alignment issues in some orientations... +// XXX alignment issues in rotated images... +// ...this makes .ribbons.centerImage() / .ribbons.centerRibbon() +// do things incorreclty in single image mode... +// NOTE: they do their job correctly on rectangular images in +// ribbon view! function updateImageProportions(){ var that = this var threshold = this.config['single-image-proportions-threshold'] || 2 @@ -108,7 +112,7 @@ function updateImageProportions(){ (Dm / s - di) // coefficient: 0 : c == threshold -> 1 : c == 1 * (threshold/c - 1) - // total size... + // new size... var n = di + d @@ -162,6 +166,7 @@ function updateImageProportions(){ } + //--------------------------------------------------------------------- var SingleImageActions = actions.Actions({