summaryrefslogtreecommitdiff
path: root/resources/jquery.ui/jquery.ui.resizable.js
diff options
context:
space:
mode:
Diffstat (limited to 'resources/jquery.ui/jquery.ui.resizable.js')
-rw-r--r--resources/jquery.ui/jquery.ui.resizable.js53
1 files changed, 9 insertions, 44 deletions
diff --git a/resources/jquery.ui/jquery.ui.resizable.js b/resources/jquery.ui/jquery.ui.resizable.js
index 52b1fc4f..f6ce6949 100644
--- a/resources/jquery.ui/jquery.ui.resizable.js
+++ b/resources/jquery.ui/jquery.ui.resizable.js
@@ -1,7 +1,7 @@
-/*
- * jQuery UI Resizable 1.8.17
+/*!
+ * jQuery UI Resizable 1.8.23
*
- * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
+ * Copyright 2012, AUTHORS.txt (http://jqueryui.com/about)
* Dual licensed under the MIT or GPL Version 2 licenses.
* http://jquery.org/license
*
@@ -50,10 +50,6 @@ $.widget("ui.resizable", $.ui.mouse, {
//Wrap the element if it cannot hold child nodes
if(this.element[0].nodeName.match(/canvas|textarea|input|select|button|img/i)) {
- //Opera fix for relative positioning
- if (/relative/.test(this.element.css('position')) && $.browser.opera)
- this.element.css({ position: 'relative', top: 'auto', left: 'auto' });
-
//Create a wrapper element and set the wrapper to the new current internal element
this.element.wrap(
$('<div class="ui-wrapper" style="overflow: hidden;"></div>').css({
@@ -102,9 +98,8 @@ $.widget("ui.resizable", $.ui.mouse, {
var handle = $.trim(n[i]), hname = 'ui-resizable-'+handle;
var axis = $('<div class="ui-resizable-handle ' + hname + '"></div>');
- // increase zIndex of sw, se, ne, nw axis
- //TODO : this modifies original option
- if(/sw|se|ne|nw/.test(handle)) axis.css({ zIndex: ++o.zIndex });
+ // Apply zIndex to all handles - see #7960
+ axis.css({ zIndex: o.zIndex });
//TODO : What's going on here?
if ('se' == handle) {
@@ -247,10 +242,6 @@ $.widget("ui.resizable", $.ui.mouse, {
el.css({ position: 'absolute', top: iniPos.top, left: iniPos.left });
}
- //Opera fixing relative position
- if ($.browser.opera && (/relative/).test(el.css('position')))
- el.css({ position: 'relative', top: 'auto', left: 'auto' });
-
this._renderProxy();
var curleft = num(this.helper.css('left')), curtop = num(this.helper.css('top'));
@@ -549,7 +540,7 @@ $.widget("ui.resizable", $.ui.mouse, {
});
$.extend($.ui.resizable, {
- version: "1.8.17"
+ version: "1.8.23"
});
/*
@@ -566,8 +557,7 @@ $.ui.plugin.add("resizable", "alsoResize", {
var el = $(this);
el.data("resizable-alsoresize", {
width: parseInt(el.width(), 10), height: parseInt(el.height(), 10),
- left: parseInt(el.css('left'), 10), top: parseInt(el.css('top'), 10),
- position: el.css('position') // to reset Opera on stop()
+ left: parseInt(el.css('left'), 10), top: parseInt(el.css('top'), 10)
});
});
};
@@ -599,12 +589,6 @@ $.ui.plugin.add("resizable", "alsoResize", {
style[prop] = sum || null;
});
- // Opera fixing relative position
- if ($.browser.opera && /relative/.test(el.css('position'))) {
- self._revertToRelativePosition = true;
- el.css({ position: 'absolute', top: 'auto', left: 'auto' });
- }
-
el.css(style);
});
};
@@ -617,25 +601,6 @@ $.ui.plugin.add("resizable", "alsoResize", {
},
stop: function (event, ui) {
- var self = $(this).data("resizable"), o = self.options;
-
- var _reset = function (exp) {
- $(exp).each(function() {
- var el = $(this);
- // reset position for Opera - no need to verify it was changed
- el.css({ position: el.data("resizable-alsoresize").position });
- });
- };
-
- if (self._revertToRelativePosition) {
- self._revertToRelativePosition = false;
- if (typeof(o.alsoResize) == 'object' && !o.alsoResize.nodeType) {
- $.each(o.alsoResize, function (exp) { _reset(exp); });
- }else{
- _reset(o.alsoResize);
- }
- }
-
$(this).removeData("resizable-alsoresize");
}
});
@@ -725,13 +690,13 @@ $.ui.plugin.add("resizable", "containment", {
if (cp.left < (self._helper ? co.left : 0)) {
self.size.width = self.size.width + (self._helper ? (self.position.left - co.left) : (self.position.left - cop.left));
- if (pRatio) self.size.height = self.size.width / o.aspectRatio;
+ if (pRatio) self.size.height = self.size.width / self.aspectRatio;
self.position.left = o.helper ? co.left : 0;
}
if (cp.top < (self._helper ? co.top : 0)) {
self.size.height = self.size.height + (self._helper ? (self.position.top - co.top) : self.position.top);
- if (pRatio) self.size.width = self.size.height * o.aspectRatio;
+ if (pRatio) self.size.width = self.size.height * self.aspectRatio;
self.position.top = self._helper ? co.top : 0;
}