Pointer on Vaadin Image

Hi,

i’ve tried to set the mouseover for a vaadin image to pointer:

.v-image-pointer {
cursor: pointer;
}

image.setStyleName(“pointer”);

I put this in a file named “image.scss” and include this file to my theme… but it doesn’t work…
Can anybody help me with my problem? I’m new to vaadin and web applications :confused:

Hi Benjamin,

i think you need to add “:hover” to your selector

.v-image-pointer:hover{ cursor: pointer; } EDIT:
use addStyleName(“…”); instead of setStyleName(“”);

Thanks, but it doesn’t work at all.
I’m not sure where the problem is. Firebug Inspection doesn’t show the css class “pointer” when i inspect my image. There’s only “v-image” and many others from my theme, but not “v-image-pointer” :frowning:

I’ve now tried this:

.v-image { cursor: pointer; } and it works for all images in my application… so the problem is apparently not the css. The problem is how to tell the image which class to use

Fixed!
Shame on me… stylename was set correctly, but overwrite later in the application…

Thanks for Help!