Mmm... Ok, I read "context menu" and got stuck with that idea :-) as soon
as I get back to my pc I'll try to refactor it out :-)
On Nov 28, 2013 8:44 PM, "Tomás Malbrán" <notifications@github.com> wrote:

> In src/command/DefaultMenus.js:
>
> > +         */
> > +        $("#working-set-option-btn").on("click", function (e) {
> > +            var buttonOffset,
> > +                buttonHeight;
> > +
> > +            e.stopPropagation();
> > +
> > +            if (working_set_settings_cmenu.isOpen()) {
> > +                working_set_settings_cmenu.close();
> > +            } else {
> > +                buttonOffset = $(this).offset();
> > +                buttonHeight = $(this).outerHeight();
> > +                working_set_settings_cmenu.open({
> > +                    pageX: buttonOffset.left,
> > +                    pageY: buttonOffset.top + buttonHeight
> > +                });
>
> The utility function would be moved to the Menus file and made as a
> function that it exports. Then from the Default Menus and from the Recent
> Projects main file, that function can be called through the Menu module to
> create the required on click event.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/adobe/brackets/pull/6107/files#r7991328>
> .
>