thx for reply, johan

yes..you r right, when i click a link, I want redirect to a load a page and
then at the same time, a modal dialog is show immediately... 

my current testing here is... the modal window component is call at the
parent class and then the report form is call at child class. Common sense,
all the component at the parent class will call first before the child
class' component , right...

yes... right now my page can load the modal window, but it is shown after
the report page is finish load. The main reason i use the modalwindow is
feasible the user to make decision whether want terminate the report page
loading or not ( if the user don't want to wait until the page is finish
load) 

as what you suggested on Jan 31, 2008.. yes.. i did. Add ajaxlink to call
the modal window and then onload it. The code that i auto fire the ajaxlink
is 

getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel( ajaxLink ),
null );

which i get the sample resource from this forum
http://www.nabble.com/modal-window-question---opening-a-modal-window-on-page-load-to12586008.html#a12598786

yes..it worked. but it is loaded after the page is finish load.  :(


thanks in advance 
- kenix




Johan Compagner wrote:
> 
> what do you exactly want?
> you want a modal dialog to show immedianlty when another page is loaded?
> I think you have to dig into the javascript portion of modal window then
> (or
> matej can tell you a bit more)
> 
> first of all the page below it has to load first completely because that
> does contain the div.
> 
> I do think you should think about your gui a bit more and if there isn't a
> better way of doing stuff
> because showing a modal dialog immediantly on a new page doesn't make much
> sense to me in 99.9% of the cases i can think of
> 
> johan
> 
> On Feb 4, 2008 12:24 PM, kenixwong <[EMAIL PROTECTED]> wrote:
> 
>>
>> hi,
>>
>> can anybody share the solution with me ?
>>
>> is that the javaScript is take time to load for the modal window even
>> this
>> component is called before the form component is call?
>>
>>
>> anyone can help ? until now i still can't get any solution and resource
>> yet...
>>
>>
>> thanks in advance,...
>> - kenix
>>
>>
>>
>> kenixwong wrote:
>> >
>> > 2 process cant together in a same time - modal window and form in the
>> same
>> > page constructor?  Is because the process haven't done, so the request
>> > wont send to wicket there?
>> >
>> > The main  reason i want to implement this features, caused modal window
>> > can prevent the user navigate to other page or feasible the user to
>> cancel
>> > the form process if the loading time is longer. Another point is,
>> because
>> > my report page is loading with JFreeChart to generate the chart report.
>> If
>> > the user press right click to Open Link in new tab, the chart at the
>> > previous tab will have the broken link issue means the chart is cant
>> > display. So, modal window can play an important role here...
>> >
>> >
>> > I was using the wicket 1.2.4. Is it the version cant support it and i
>> need
>> > to upgrade ? i read from
>> > http://cwiki.apache.org/WICKET/wicket-130-rc1.html .. Migration from
>> 1.2
>> > to 1.3, there is not much different for the modal window in both
>> version..
>> > can anyone give some solution to me?
>> >
>> >
>> > Thanks in advance
>> > - kenix
>> >
>> >
>> >
>> >
>> >
>> > kenixwong wrote:
>> >>
>> >> thanks for reply, johan
>> >>
>> >> i want to show the modal window once the report page is load. Mean
>> >> background is continue loading the report and the modal window is just
>> as
>> >> a control (its features is invisible the background and only close
>> once
>> >> action performed is click in the modal window ) to prevent user
>> navigate
>> >> to other page. For the modal window it only define one cancel button,
>> >> mean if user click the cancel button, the background ( report page )
>> is
>> >> stop.
>> >>
>> >> Yes... the modal window is only shown by an ajax link. I get the
>> source
>> >> from this forum ..where it can fire the ajaxlink whitout click the
>> link.
>> >> Here is the code
>> >>
>> >>   <   getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
>> >> ajaxLink ), null );   >
>> >>
>> >> Even i tried to create a modal window with ajaxlink ( add auto fire
>> event
>> >> as above code ) and put at the parent class and the report page is the
>> >> child class. But the result is same, the report page is finish loaded
>> >> then only pop up the modal window.
>> >>
>> >> my report page constructor :
>> >>
>> >> public LineChart() {
>> >>     /// modal window use panel..declare the modal window setting here
>> >> then add
>> >>      add(modalWindow);
>> >>
>> >>      // to auto pop up the modal window.
>> >>      ajaxLink = new AjaxLink("cancelReportModalLink"){
>> >>                 @Override
>> >>                 public void onClick(AjaxRequestTarget target) {
>> >>                         cancelReportModal.show(target);
>> >>                         }
>> >>                 };
>> >>      add(ajaxLink);
>> >>
>> >>       //  Fire the ajaxLink onclick function
>> >>      getBodyContainer().addOnLoadModifier(new ClickOnceOnLoadModel(
>> >> ajaxLink ), null );
>> >>
>> >>      add(feedback);
>> >>      add(new LineChartForm("LineChartForm"));
>> >> }
>> >>
>> >>
>> >> private class LineChartForm extends Form {
>> >>             // execute query
>> >>             // result as in JFreeChart
>> >> }
>> >>
>> >>
>> >> i add the component for modal window then only come to form.
>> supposedly
>> >> it will show the modal window then load the form, am i right . Why ? 2
>> >> process in a same time cant together?  Is because the process haven't
>> >> done, so the request wont send to wicket there,
>> >>
>> >> 2 way i tried. Call the modal window at Parent class and also child
>> >> class. But it still given me the same result.
>> >>
>> >> between, can you explain more or give example for the onload event
>> that
>> >> you mentioned ? onLoad event for the modal window ? I was using the
>> >> wicket 1.2.4. Is it the version cant support it and i need to upgrade
>> ?
>> >>
>> >>
>> >>
>> >> Thanks in advance
>> >>
>> >> - kenix
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> Johan Compagner wrote:
>> >>>
>> >>> how do you show the modal dialog??
>> >>> Normally the modal dialog is only shown by an ajax link.
>> >>> I guess you show it on onload event. Then yes the page will first
>> load
>> >>> itself
>> >>> then call onload and then the modal window will show itself
>> >>>
>> >>> johan
>> >>>
>> >>>
>> >>>
>> >>> On Jan 31, 2008 6:16 AM, kenixwong <[EMAIL PROTECTED]> wrote:
>> >>>
>> >>>>
>> >>>> hi,
>> >>>>
>> >>>> for the above case, for example... my page constructor: i add the
>> >>>> component
>> >>>> ( modal window, feedBackPanel, form ) . Once i load the page, why
>> the
>> >>>> modal
>> >>>> window will only display when the page is finish loaded. Is that the
>> >>>> wicket
>> >>>> had default set the main thread for the form component?
>> >>>>
>> >>>> Thanks in advance
>> >>>> --
>> >>>> View this message in context:
>> >>>>
>> http://www.nabble.com/is-there-wicket-had-per-defined-the-Thread-for-the-form-component-tp15198385p15198385.html
>> >>>> Sent from the Wicket - User mailing list archive at
>> >>>> Nabble.com <http://nabble.com/><http://nabble.com/>
>> >>>> .
>> >>>>
>> >>>>
>> >>>>
>> ---------------------------------------------------------------------
>> >>>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >>>> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>>>
>> >>>>
>> >>>
>> >>>
>> >>
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/is-there-wicket-had-per-defined-the-Thread-for-the-form-component-tp15198385p15266151.html
>>  Sent from the Wicket - User mailing list archive at
>> Nabble.com<http://nabble.com/>
>> .
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/is-there-wicket-had-per-defined-the-Thread-for-the-form-component-tp15198385p15267910.html
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to