--- a/dialog/dialog.js	2011-03-17 22:29:56.000000000 +0100
+++ b/dialog/dialog.js	2012-11-02 18:12:58.000000000 +0100
@@ -239,7 +239,13 @@
       };
       o = $.extend({}, Drupal.settings.Dialog.defaults, overrides, command.options);
       $.each(o, function (i, v) { $el.dialog('option', i, v); });
-
+      
+      // hide/show the background mask depending on $el.dialog('option', 'modal')
+      if(! $el.dialog('option', 'modal')) {
+          $('.ui-widget-overlay').hide();
+      } else {
+          $('.ui-widget-overlay').show();
+      }
       if ($el.height() > o.maxHeight) {
         $el.dialog('option', 'height', o.maxHeight);
         $el.dialog('option', 'position', o.position);
