Sie sind nicht angemeldet.

magnus

Anfänger

  • »magnus« ist der Autor dieses Themas

Beiträge: 17

Wohnort: Germany

Beruf: Student

  • Nachricht senden

1

Sonntag, 11. Oktober 2009, 23:49

onovercrop

Hello,

I am using one a png image for all my buttons in a panorama, and am cropping parts from it for the buttons and the images for the onover event.

Quellcode

1
2
3
4
<plugin name="help"
	url="buttons/buttons.png"
	crop="96|0|16|16"
	onovercrop="96|16|16|16" />


The problem is, that when I am holding the left mouse button pressed while being on a button and moving the mouse away from the button it keeps the crop from the onover event and does not go back to the original button image. In my example the button says red (onover colour) instead of going back to black (normal colour).
Is there any workaround for this problem?

Thanks in advance,
Magnus

2

Montag, 12. Oktober 2009, 01:42

Hi magnus,

I have tried with the buttons example that comes with krpano download file...
And I noticed that, when you have only crop and onovercrop defined and ondowncrop not defined, then the button acts as you explain above....
Simply define the ondowncrop with the same value as crop or onovercrop or a new value for button pressed...

Salut.

magnus

Anfänger

  • »magnus« ist der Autor dieses Themas

Beiträge: 17

Wohnort: Germany

Beruf: Student

  • Nachricht senden

3

Montag, 12. Oktober 2009, 15:29

Thanks a lot for the help again, michel.
Your solution works fine for me, even when using a new picture for ondowncrop it switches back to the original picture when I am releasing the mouse button.

I was hoping to get around using another attribute but as long as it works I am fine with this solution.

Ähnliche Themen