From: Scott González Date: Tue, 12 Jul 2011 13:16:03 +0000 (-0400) Subject: Dialog: Append the dialog to the body early to make sure styles from the classes... X-Git-Tag: 1.9m6~98^2~13 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=0dc4a487628c674868f786db73db7f0c0c2b02b2;p=jquery-ui.git Dialog: Append the dialog to the body early to make sure styles from the classes get applied. --- diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index 0eba39842..e9cf67540 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -108,7 +108,8 @@ $.widget("ui.dialog", { }) .mousedown(function( event ) { self.moveToTop( false, event ); - }), + }) + .appendTo( "body" ), uiDialogContent = self.element .show() @@ -155,8 +156,6 @@ $.widget("ui.dialog", { self._createButtons( options.buttons ); self._isOpen = false; - uiDialog.appendTo( document.body ); - if ( $.fn.bgiframe ) { uiDialog.bgiframe(); }