users@woodstock.java.net

Re: dojo endTopic events

From: Ryan de Laplante <ryan_at_ijws.com>
Date: Fri, 13 Jun 2008 17:51:13 -0400

This worked with my Woodstock 4.1.1 components. It is exciting to see
things finally working! Next I have to figure out why my value change
events fire too many times when I select an item in my dropdown list. I
suspect it is related to what I specified for the parameter of refresh().


I have not tried the "view state serialize & save in session on server"
feature that Ryan wanted me to try in another thread. Hopefully I can
do that Monday.


Ryan


Dan Labrecque wrote:
> If you have not upgraded the Netbeans Visual Web plug-in, you may
> still be using 4.1? If you're using an earlier version of Woodstock,
> you might have more success using:
>
>
> dojo.subscribe(webui.suntheme.widget.dropDown.event.refresh.endTopic,
> processEvents, "update");
>
> Note that Dojo was never considered a public API and does not exist in
> Woodstock 4.2 or later.
>
> Dan
>
> Ryan de Laplante wrote:
>> I'm beginning to wonder if my projects are using different versions
>> of Woodstock. I'm on NetBeans 6.0.1 because of showstopper (for me)
>> bugs in 6.1.
>>
>> My demo app that mostly works fine (except the dojo events) doesn't
>> work when I move the bits into my real application. I get all kinds
>> of weird behavior including the missing state element in AJAX
>> responses, and UI widgets not being refreshed. The project has been
>> around since NB 5.5 and continually upgraded as new versions of NB
>> come out. I wonder if it somehow uses a different version of
>> Woodstock than new projects use. I will investigate this further. My
>> boss has given me permission to spend as much time necessary to make
>> this work because it is important.
>>
>> Thanks,
>> Ryan
>>
>>
>> Dan Labrecque wrote:
>>> I added your code verbatim and it works as expected. The only reason
>>> I can see that "domNode" or its "event" property would be null is if
>>> the wrong id were used. Or, there could be a JavaScript error
>>> somewhere in the page.
>>>
>>> That said, I'm assuming you're using Woodstock 4.2 or later? If
>>> you're using an earlier version, then you may be looking at the
>>> wrong TLD examples.
>>>
>>> Dan
>>>
>>> Ryan de Laplante wrote:
>>>> Thanks. I am certain that I have the right id:
>>>>
>>>> <webuijsf:form binding="#{Page1.form1}" id="*form1*">
>>>> <webuijsf:dropDown binding="#{Page1.dropDown1}" id="*dropDown1*"
>>>> items="#{Page1.list1}" label="Proximity To Elevator" labelOnTop="true"
>>>> onChange="dropDown1Changed(); return
>>>> false;" style="left: 216px; top: 48px; position: absolute"
>>>> valueChangeListenerExpression="#{Page1.dropDown1_processValueChange}"/>
>>>>
>>>> function init() {
>>>> var domNode = document.getElementById('*form1:dropDown1*');
>>>> if (domNode == null || domNode.event == null) {
>>>> return setTimeout("init();", 10);
>>>> }
>>>> alert('subscribing to dropDown1 endTopic');
>>>> domNode.subscribe(domNode.event.refresh.endTopic, processEvents,
>>>> "update");
>>>> }
>>>>
>>>> <webuijsf:body binding="#{Page1.body1}" id="body1"
>>>> onLoad="*init();*" style="-rave-layout: grid">
>>>> The alert in init() never happens. This is a new
>>>> visual web project with very little code in it. You can get it to
>>>> work?
>>>>
>>>>
>>>> Thanks,
>>>> Ryan
>>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_woodstock.dev.java.net
>> For additional commands, e-mail: users-help_at_woodstock.dev.java.net
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_woodstock.dev.java.net
> For additional commands, e-mail: users-help_at_woodstock.dev.java.net
>
>