users@woodstock.java.net

Re: dojo endTopic events

From: Ryan de Laplante <ryan_at_ijws.com>
Date: Tue, 10 Jun 2008 16:32:13 -0400

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
>>