Skip to main content

Search and Top Navigation

#10487 closed bug (duplicate)

Opened August 05, 2014 08:01PM UTC

Closed August 05, 2014 08:10PM UTC

Last modified August 05, 2014 08:49PM UTC

Top Modal Dialog can't overlay other stacked dialog

Reported by: carlshe Owned by:
Priority: minor Milestone: none
Component: ui.dialog Version: 1.11.0
Keywords: Cc:
Blocked by: Blocking:
Description

When open a new modal dialog, being expected to overlay other existing dialogs, the z-index of its newly created back-overlay seems not correctly set.

I add few lines, referring parts of _moveToTop, to _createOverlay as below:

var zIndicies = this.uiDialog.siblings(".ui-front:visible").map(function () {

return +$(this).css("z-index");

}).get(),

zIndexMax = Math.max.apply(null, zIndicies);

if (zIndexMax >= +this.overlay.css("z-index")) {

this.overlay.css("z-index", zIndexMax + 1);

}

And temporarily, the problem seems resolved.

I'm not skilled in development of JQueryUI, so hope somebody could help fixing this.

Thanks!

Attachments (0)
Change History (2)

Changed August 05, 2014 08:10PM UTC by scottgonzalez comment:1

resolution: → duplicate
status: newclosed

Duplicate of #10138.

Changed August 05, 2014 08:49PM UTC by carlshe comment:2

Just for friendly remind, Because I can't have a look at the newest code of 1.11.1

I add the code closely following the creation of overlay, not in _moveToTop.

Why? Because the zIndex of dialog is possible to be changed within _moveToTop. Sometimes nonmodal dialogs could be popup from current Modal dialog. In this case, even the modal dialog get focused again and has its zIndex changed, its back-overlay's zIndex shouldn't be changed accordingly. That means, the zIndex of overlay only needs to be set once while created.

Thanks!