Opened 2 years ago

Last modified 23 months ago

#18981 assigned defect

Child popup closes parent popup when mouse left click duration reaches certain threshold value

Reported by: dylan Owned by: dylan
Priority: high Milestone: 1.14
Component: Dijit Version: 1.12.1
Keywords: Cc:
Blocked By: Blocking:

Description (last modified by dylan)

Received this issue via email as trac was flagging it as spam:

Inside a tooltip dialog that is opened using a popup, I have a button that opens a color picker also using popup. If I click a color cell rapidly the color picker closes, and the parent dialog remains opened. If I hold the mouse button for a longer period of time on a color cell, when I release the mouse, the color picker popup closes and then the parent tooltip dialog closes along with it.

This issue does not occur if I debug the code and put a breakpoint in the color picker popup onExecute() method. Pausing the execution seems to prevent propagation of the close event to the parent popup.

Below is my code to open the color picker - where fontTextColorNode is a button in a parent popup dialog.

            on(this.fontTextColorNode, "click", function (event) {

 

                var myPalette = new ColorPalette(

                {

                    palette: "7x10",

                    onChange: function (val) {

 

                        console.log("selected color", myPalette.value);

 

                        that._set("color", myPalette.value);

 

                        formElementController.setPropertyValue(that.parentWidgetId, "color", myPalette.value);

                    }

                });

 

                myPalette.on("blur", function () {

                    popup.close(myPalette);

                });

 

                popup.open({

                    parent: that,

                    popup: myPalette,

                    around: that.fontTextColorNode,

                    orient: ["below"],

                    onExecute: function () {

                        //alert();

                        popup.close(myPalette);

                        console.log("closed myPalette");

                    },

                    onCancel: function () {

                        popup.close(myPalette);

                    }

                });

                focusUtil.focus(myPalette);

            });

Change History (3)

comment:1 Changed 2 years ago by dylan

Description: modified (diff)

comment:2 Changed 2 years ago by dylan

Milestone: tbd1.12.3
Owner: set to dylan
Priority: undecidedhigh
Status: newassigned

comment:3 Changed 23 months ago by dylan

Milestone: 1.12.31.14
Note: See TracTickets for help on using tickets.