Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#15182 closed bug (fixed)

Error when underlaying dialog is closed after the new one is open

Reported by: john357smith Owned by: Scott González
Priority: minor Milestone: 1.12.2
Component: ui.dialog Version: 1.12.1
Keywords: Cc:
Blocked by: Blocking:


Follow this case:

  1. open first dialog (from link or button)
  2. open second dialog (from button from previous dialog) and close first dialog via 'close' command
  3. close second dialog (via closing button)
  4. try open first dialog again and stack trace will occur saying "Uncaught TypeError: Cannot read property '_focusTabbable' of undefined"

Workaround: close first dialog first then open a new one.

Tested on: latest Chrome and Firefox

Code example:

$(function() { 

   $("#link_test1").on('click', function() {

      autoOpen: false,
      modal: true

      autoOpen: false,
      modal: true,
      buttons: [
          text: "open",
 	  click: function() {


<a href="#" id="link_test1">open</a>

<div id="test_dlg1" title="test1">

<div id="test_dlg2" title="test2">

Change History (4)

comment:1 Changed 6 years ago by Scott González

Status: newopen

comment:2 Changed 6 years ago by Scott González

Owner: set to Scott González
Resolution: fixed
Status: openclosed

In 5708046:

Dialog: Fix shared event handler for modal dialogs

The old logic worked when all widgets of the same type used the same
event namespace. However, now that each instance has its own namespace,
we cannot use _on() for shared event handlers.

Fixes #15182
Closes gh-1817

comment:3 Changed 6 years ago by Scott González

Milestone: none1.12.2

comment:4 Changed 6 years ago by Scott González

#15198 is a duplicate of this ticket.

Note: See TracTickets for help on using tickets.