summaryrefslogtreecommitdiff
path: root/addons/website/static/lib/summernote/src/js/module/Handle.js
diff options
context:
space:
mode:
Diffstat (limited to 'addons/website/static/lib/summernote/src/js/module/Handle.js')
-rw-r--r--addons/website/static/lib/summernote/src/js/module/Handle.js44
1 files changed, 0 insertions, 44 deletions
diff --git a/addons/website/static/lib/summernote/src/js/module/Handle.js b/addons/website/static/lib/summernote/src/js/module/Handle.js
deleted file mode 100644
index 375428faa32..00000000000
--- a/addons/website/static/lib/summernote/src/js/module/Handle.js
+++ /dev/null
@@ -1,44 +0,0 @@
-define('summernote/module/Handle', function () {
- /**
- * Handle
- */
- var Handle = function () {
- /**
- * update handle
- * @param {jQuery} $handle
- * @param {Object} styleInfo
- * @param {Boolean} isAirMode
- */
- this.update = function ($handle, styleInfo, isAirMode) {
- var $selection = $handle.find('.note-control-selection');
- if (styleInfo.image) {
- var $image = $(styleInfo.image);
- var pos = isAirMode ? $image.offset() : $image.position();
-
- // include margin
- var imageSize = {
- w: $image.outerWidth(true),
- h: $image.outerHeight(true)
- };
-
- $selection.css({
- display: 'block',
- left: pos.left,
- top: pos.top,
- width: imageSize.w,
- height: imageSize.h
- }).data('target', styleInfo.image); // save current image element.
- var sizingText = imageSize.w + 'x' + imageSize.h;
- $selection.find('.note-control-selection-info').text(sizingText);
- } else {
- $selection.hide();
- }
- };
-
- this.hide = function ($handle) {
- $handle.children().hide();
- };
- };
-
- return Handle;
-});