javagwtgwtbootstrap3

Unable to update tooltip title in GWT ui binder


I am trying to a add a tooltip to a button. The tooltip comes up fine. But I am able to update the title of the tooltip with my java code only in the constructor, but not in other methods. What's the issue?

 <b:Tooltip title="..." placement="BOTTOM" ui:field="sharedWith">
                <b:Button text="Share" 
                    type="PRIMARY" ui:field="share" icon="USER_PLUS">
                </b:Button>
            </b:Tooltip>

Java code:

sharedWith.setTitle(members.size() + " " + member);

sharedWith is ui:field for Tooltip.


Solution

  • Assuming gwtbootstrap3 here, you need to call reconfigure() whenever you change properties of the Tooltip.