1. #1
    Sencha Premium Member
    Join Date
    Feb 2012
    Posts
    6
    Vote Rating
    0
    thomhehl is on a distinguished road

      0  

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

  2. #2
    Sencha Premium Member
    Join Date
    Dec 2008
    Location
    Munich, Germany
    Posts
    183
    Vote Rating
    0
    Jose Jeria is an unknown quantity at this point

      0  

    Default


    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

  3. #3
    Sencha Premium Member
    Join Date
    Feb 2012
    Posts
    6
    Vote Rating
    0
    thomhehl is on a distinguished road

      0  

    Question What's settings

    What's settings


    So, in this example, what's "settings"? Is that the ID of the text component?

  4. #4
    Sencha Premium Member
    Join Date
    Dec 2008
    Location
    Munich, Germany
    Posts
    183
    Vote Rating
    0
    Jose Jeria is an unknown quantity at this point

      0  

    Default


    Yeah, the ID of the HTML element whos onclick event I wanted to handle.

Thread Participants: 1

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar