Hallo folks,
I have a widget defined as follow:
<g:HTMLPanel>
<g:HTML ui:field="rootElement" styleName="{resources.mainStructure.widgetBox}"/>
</g:HTMLPanel>
and in the related java class there's something like this:
@UiField HTML rootElement;
for(int row = 0; row < 10; row ++) {
rootElement.getElement().appendChild(new MyWidget().getElement());
}
where MyWidget is something like this other:
<g:HTMLPanel>
<table border="0" cellpadding="0" cellspacing="0" class="{resources.mainStructure.areaWidget}">
<tbody class="{resources.mainStructure.workArea}">
<tr>
<td ui:field="td_1"/>
<td ui:field="td_2"/>
<td ui:field="td_3"/>
<td ui:field="td_4"/>
<td ui:field="td_5"/>
<td ui:field="td_6"/>
<td ui:field="td_7"/>
<td ui:field="td_8"/>
</tr>
</tbody>
<tfoot class="{resources.mainStructure.lineaBus}">
<tr>
<th ui:field="th_1"/>
<th ui:field="th_2"/>
<th ui:field="th_3"/>
<th ui:field="th_4"/>
<th ui:field="th_5"/>
<th ui:field="th_6"/>
<th ui:field="th_7"/>
<th ui:field="th_8"/>
</tr>
</tfoot>
</table>
At some point I attach to a certain td another widget, this one:
<g:HTMLPanel>
<g:Anchor styleName="{resources.mainStructure.orangeButton}" ui:field="selectMe">+</g:Anchor>
</g:HTMLPanel>
Now, the problem is that when I click the anchor of the above widget, no click is fired. If I attach the anchor widget to another widget,not to the td one, it works fine. So far I understand the problem is in the first widget, because if I attach MyWidget to nothing than the "selectMe" onclick event is fired. Any comment? Thanks, Chris