Search code examples
gwtuibinder

GWT: Reference one widget from another in UiBinder?


I have the following UiBinder code:

    <c:CellList ui:field="membersList" />
    <c:SimplePager display="membersList" />

I want to have the pager use the cell list as its display. However, the above code fails because it is trying to parse the string "membersList" instead of using it as a reference to a widget:

    [ERROR] [foo] - Cannot parse value: "membersList" as type HasRows

Is there any way to make this work?


Solution

  • Yes, you have to use curly brackets:

    <c:CellList ui:field="membersList" />
    <c:SimplePager display="{membersList}" />