mirror of
https://github.com/jquery/jquery-ui.git
synced 2026-01-29 16:07:58 -05:00
Dialog: Fixed #3221: User outerWidth/Height for positioning.
This commit is contained in:
@@ -335,11 +335,11 @@ $.widget("ui.dialog", {
|
||||
pLeft += 0;
|
||||
break;
|
||||
case 'right':
|
||||
pLeft += wnd.width() - this.uiDialog.width();
|
||||
pLeft += wnd.width() - this.uiDialog.outerWidth();
|
||||
break;
|
||||
default:
|
||||
case 'center':
|
||||
pLeft += (wnd.width() - this.uiDialog.width()) / 2;
|
||||
pLeft += (wnd.width() - this.uiDialog.outerWidth()) / 2;
|
||||
}
|
||||
}
|
||||
if (pos[1].constructor == Number) {
|
||||
@@ -351,12 +351,12 @@ $.widget("ui.dialog", {
|
||||
break;
|
||||
case 'bottom':
|
||||
// Opera check fixes #3564, can go away with jQuery 1.3
|
||||
pTop += ($.browser.opera ? window.innerHeight : wnd.height()) - this.uiDialog.height();
|
||||
pTop += ($.browser.opera ? window.innerHeight : wnd.height()) - this.uiDialog.outerHeight();
|
||||
break;
|
||||
default:
|
||||
case 'middle':
|
||||
// Opera check fixes #3564, can go away with jQuery 1.3
|
||||
pTop += (($.browser.opera ? window.innerHeight : wnd.height()) - this.uiDialog.height()) / 2;
|
||||
pTop += (($.browser.opera ? window.innerHeight : wnd.height()) - this.uiDialog.outerHeight()) / 2;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user