right, the nonmodal window is basically a calculator (kind of) that helps
the user do some math. It needs to have access to "lower" (layer-wise)
fields.
If a modal window is displayed then it should cover the nonmodal window
(lets call it the calculator).

I can do this with some error like this:

new ModalWindow(calculator){         private static final long
serialVersionUID = 0L;

         @Override
         public void show(AjaxRequestTarget cTarget) {
            super.show(cTarget);
            cTarget.appendJavascript("if
(typeof(Wicket.Window.get())!=\"undefined\") {
Wicket.Window.get().destroyMask(); }");
         }

      };

This destroyMask works fine, but when I close the window, it throws an error
due to destroyMask is called again and inside executes the following code:

        /**
 * Destroys the mask.
 */
destroyMask: function() {
this.mask.hide();
this.mask = null;
}

I am thinking in overriding this body with:

        /**
 * Destroys the mask.
 */
destroyMask: function() {
                if(this.mask) {
        this.mask.hide();
        this.mask = null;
                }
}

Or something of the sort.

f(t)

On Tue, Oct 7, 2008 at 9:01 AM, Nino Saturnino Martinez Vazquez Wael <
[EMAIL PROTECTED]> wrote:

> both modal and nonmodal?
>
>
> Francisco Diaz Trepat - gmail wrote:
>
>> Seams that it is not possible to do this.
>> I need both modal and modeless.
>>
>> f(t)
>>
>> On Tue, Oct 7, 2008 at 7:57 AM, Francisco Diaz Trepat - gmail <
>> [EMAIL PROTECTED]> wrote:
>>
>>
>>
>>> Hi nino, sounds good, I'll have to set the setCssClassName() if I don't
>>> want to clash with other modal windows, that need to be modal, right?
>>> f(t)
>>>
>>>
>>> On Tue, Oct 7, 2008 at 2:36 AM, Nino Saturnino Martinez Vazquez Wael <
>>> [EMAIL PROTECTED]> wrote:
>>>
>>>
>>>
>>>> Why not use wicket modal window, and just override css?
>>>>
>>>>
>>>> Francisco Diaz Trepat - gmail wrote:
>>>>
>>>>
>>>>
>>>>> Hi I need to build a pop-up modal window on my application.
>>>>> I wanted to see if I could get some recomendations or comments.
>>>>>
>>>>> Obviously I need not to re-enter username and password and work on the
>>>>> same
>>>>> session.
>>>>>
>>>>> It could be a div element like the Wicket Dialog, or a real new window.
>>>>>
>>>>> Thoughts?
>>>>>
>>>>> thanks,
>>>>> f(t)
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>> --
>>>> -Wicket for love
>>>>
>>>> Nino Martinez Wael
>>>> Java Specialist @ Jayway DK
>>>> http://www.jayway.dk
>>>> +45 2936 7684
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>>>> For additional commands, e-mail: [EMAIL PROTECTED]
>>>>
>>>>
>>>>
>>>>
>>>
>>
>>
>
> --
> -Wicket for love
>
> Nino Martinez Wael
> Java Specialist @ Jayway DK
> http://www.jayway.dk
> +45 2936 7684
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to