1. #1
    Sencha User
    Join Date
    Nov 2012
    Posts
    4
    Vote Rating
    0
    kjmcneish is on a distinguished road

      0  

    Default Change cursor to "hand" when over a clickable element

    Change cursor to "hand" when over a clickable element


    How can I turn the cursor into a "hand" when the mouse pointer is positioned over my ad? I have set the Action to URL on some of my text elements, and want to provide a visual cue that the text is "clickable".

  2. #2
    Sencha - Architect Dev Team
    Join Date
    Apr 2012
    Posts
    226
    Vote Rating
    21
    miro.bojic will become famous soon enough miro.bojic will become famous soon enough

      0  

    Default


    Hi kjmcneish, and welcome to the forums,

    To change cursor you can add a little bit of custom JS. First, select your element that you want to have different cursor style, and under Base Object properties > General > ID, give it a name, for example MyButton. Next, under Actions > mouseover, choose Custom JavaScript and enter following line:

    Code:
    controller.getElementById('MyButton').style.cursor = "pointer";
    Please also take a look at documentation about Custom JS in Animator here: http://docs.sencha.com/animator/1-3/...de/advanced_js

    Also, there are different cursor styles available, for reference take a look here: http://www.w3schools.com/cssref/pr_class_cursor.asp

  3. #3
    Sencha User
    Join Date
    Nov 2012
    Posts
    4
    Vote Rating
    0
    kjmcneish is on a distinguished road

      0  

    Default


    Thanks...before I received your reply I was able to get the pointer working by adding the following Custom CSS to each element:

    Code:
    cursor:pointer

Thread Participants: 1