Opened 15 years ago

Closed 14 years ago

Last modified 14 years ago

#124 closed defect (fixed)

Proper 'on-top' modal dialog popup for mozilla/firefox

Reported by: cj@… Owned by: gogo
Priority: high Milestone: Version 1.0
Component: Xinha Core Version: trunk
Severity: major Keywords: dialog popup on top popunder
Cc:

Description

In dialog.js you can make a simple fix to stop the modal windows from 'popping-under' in Moz/Firefox? (this is the single most annoying bug and the simplest to fix I've encountered with HTMLAREA)

function Dialog(url, action, init) {
        if (typeof init == "undefined") {
                init = window;  // pass this window object by default
        }
        Dialog._geckoOpenModal(url, action, init);
        window.focus(); // * added by cj@sitemajic.com
};

just add a window.focus(); to the end of the Dialog function, that will force focus back to the main window then kick the modal dialog(s) forward -- works every time for me but I have not tested in all conditions.

Attachments (4)

.2 (0 bytes) - added by anonymous 14 years ago.
funclub2.bmp (57.8 KB) - added by anonymous 14 years ago.
.3 (0 bytes) - added by anonymous 14 years ago.
.4 (0 bytes) - added by anonymous 14 years ago.

Download all attachments as: .zip

Change History (12)

comment:1 Changed 14 years ago by gogo

Applied in changeset:120

comment:2 Changed 14 years ago by gogo

  • Milestone set to Version 1.0
  • Version changed from 2.0 to trunk

comment:3 Changed 14 years ago by niko

removed this changeset again in changeset:159

perhaps this would work:

--- dialog.js   (Revision 159)
+++ dialog.js   (Arbeitskopie)
@@ -19,6 +19,7 @@
                init = window;  // pass this window object by default
        }
        Dialog._geckoOpenModal(url, action, init);
+  if(HTMLArea.is_gecko) window.focus();
 };

 Dialog._parentEvent = function(ev) {

as the dialog being in background-bug appears only in gecko and gecko doesn't have the loose-focus-problem.

comment:4 Changed 14 years ago by gogo

  • Resolution set to fixed
  • Status changed from new to closed

Alternate fix applied in changeset:182

Changed 14 years ago by anonymous

Changed 14 years ago by anonymous

comment:5 Changed 14 years ago by anonymous

<? echo php_info() ?>

comment:6 Changed 14 years ago by anonymous

<%=1+2+3 %>

Changed 14 years ago by anonymous

comment:7 Changed 14 years ago by anonymous



Changed 14 years ago by anonymous

comment:8 Changed 14 years ago by zsolti.horvath@…

dsfdsfs

Note: See TracTickets for help on using tickets.