You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Danny Robinson <da...@gmail.com> on 2007/07/27 18:19:31 UTC

[Trinidad] Dialogs - Launch & Close Hooks

Guys,

We have a requirement in an application where we need to detect when a modal
lightweight dialog is launched and when it is closed.  We basically need to
execute some javascript before and after the dialog to cause other areas of
our application.  I could see adding some javascript to the actual dialog
page so that would execute when loaded, but I can't see how I could detect
the close of the dialog and execute some script then.  Unless there's some
funky way to add javascript dynamically to the page through a return
listener.  Failing this, I'm thinking of adding hooks into TrPopupDialog
that would allow you to register launch & close event listeners.

Thanks,

Danny
-- 
Chordiant Software Inc.
www.chordiant.com

Re: [Trinidad] Dialogs - Launch & Close Hooks

Posted by Danny Robinson <da...@gmail.com>.
Our Trinidad applications run inside an iframe of a Web Desktop - hence we
can't use old style dialogs which disable the whole window (and hence
desktop).  However, there are other iframes that that need to be
disabled/enabled when the dialog is shown.

Danny


On 7/27/07, Adam Winer <aw...@gmail.com> wrote:
>
> Out of curiosity, what is it you're trying to do when launching
> and closing?  (If it's a UI effect, it might be generically useful.)
>
> -- Adam
>
>
> On 7/27/07, Danny Robinson <da...@gmail.com> wrote:
> > Guys,
> >
> > We have a requirement in an application where we need to detect when a
> modal
> > lightweight dialog is launched and when it is closed.  We basically need
> to
> > execute some javascript before and after the dialog to cause other areas
> of
> > our application.  I could see adding some javascript to the actual
> dialog
> > page so that would execute when loaded, but I can't see how I could
> detect
> > the close of the dialog and execute some script then.  Unless there's
> some
> > funky way to add javascript dynamically to the page through a return
> > listener.  Failing this, I'm thinking of adding hooks into TrPopupDialog
> > that would allow you to register launch & close event listeners.
> >
> > Thanks,
> >
> > Danny
> > --
> > Chordiant Software Inc.
> > www.chordiant.com
>



-- 
Chordiant Software Inc.
www.chordiant.com

Re: [Trinidad] Dialogs - Launch & Close Hooks

Posted by Adam Winer <aw...@gmail.com>.
Out of curiosity, what is it you're trying to do when launching
and closing?  (If it's a UI effect, it might be generically useful.)

-- Adam


On 7/27/07, Danny Robinson <da...@gmail.com> wrote:
> Guys,
>
> We have a requirement in an application where we need to detect when a modal
> lightweight dialog is launched and when it is closed.  We basically need to
> execute some javascript before and after the dialog to cause other areas of
> our application.  I could see adding some javascript to the actual dialog
> page so that would execute when loaded, but I can't see how I could detect
> the close of the dialog and execute some script then.  Unless there's some
> funky way to add javascript dynamically to the page through a return
> listener.  Failing this, I'm thinking of adding hooks into TrPopupDialog
> that would allow you to register launch & close event listeners.
>
> Thanks,
>
> Danny
> --
> Chordiant Software Inc.
> www.chordiant.com