-
1 Apr 2012 3:33 PM #1
Unanswered: Clickable Text Object
Unanswered: Clickable Text Object
I found this link:
http://www.sencha.com/forum/showthre...le-Text-object
But it doesn't seem to work under 2.25. How can I set up a click event on a Text object in 2.25?
Thanks.
-
9 Apr 2012 11:25 PM #2
The following works fine for me
Code:// retrieve the HTML element with an ID equals to 'settings' RootPanel link = RootPanel.get("settings"); link.sinkEvents(Event.ONCLICK); link.addHandler(new ClickHandler() { @Override public void onClick(ClickEvent event) { Window.alert("click!"); } }, ClickEvent.getType());Last edited by Jose Jeria; 21 May 2012 at 7:55 AM. Reason: Updating comment
-
21 May 2012 6:09 AM #3
What's settings
What's settings
So, in this example, what's "settings"? Is that the ID of the text component?
-
21 May 2012 11:41 PM #4
Yeah, the ID of the HTML element whos onclick event I wanted to handle.


Reply With Quote