Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Change mouse cursor icon for all buttons/tabs

    Hi,
    I want to change the mouse cursor icon from the hand to the default cursor for all buttons/tabs/... of smartgwt.
    I tried the following CSS rule:
    Code:
    a:hover {
    	cursor: default;
    }
    However, this just works with regular links. Is there an easy way to change the mouse cursor for every "clickable" widget?

    Thanks

    edit.: and the same question to context menus: do I have to overwrite every context menu function with an empty context menu if I don't want the default browser context menu to be displayed? or is there a better solution?
    Last edited by Zordon; 2 Jul 2011, 11:08.

    #2
    use method

    setCursor(Cursor.HAND); - for hand cursor

    setCursor(Cursor.ARROW); - for arrow cursor

    Comment


      #3
      Thanks.
      This works great for IButtons and many other widgets.
      Unfortunately for the TabSet it doesn't work so far:
      Code:
      TabSet tabSet = new TabSet();
      Tab tab = new Tab();
      tabSet.addTab(tab);
      tabSet.setCursor(Cursor.Arrow);
      And tab.setCursor() is not available.
      Is this a SmartGWT bug? Or how can I change the cursor of tabs?

      edit.: same problem with a Window widget. I want to change the cursor for the close and minimize button in the upper right corner:
      Window myWindow = new Window();
      myWindow.setCursor(Cursor.Arrow);
      But the cursor is still displayed as a hand.
      Last edited by Zordon; 5 Jul 2011, 14:19.

      Comment


        #4
        Sorry to bring up this question again, but I still haven't solved it.

        Is there a way to change the cursor icon for TabSets, window widgets and simply ALL widgets/links?

        Thanks

        Comment

        Working...
        X