XWidgetSoft Forum
https://www.bbs.xwidget.com/

Scroll Objects OnMouseWheel Up/Down
https://www.bbs.xwidget.com/viewtopic.php?f=8&t=5509
Page 1 of 1

Author:  kabott1 [ February 25th, 2015, 9:19 am ]
Post subject:  Scroll Objects OnMouseWheel Up/Down

Hi all, im trying to make some objects (shortcuts) move up/down on mouse wheel Up/down

i did this but isnt working as it should, any help is appreciated!


function layer1OnMouseWheelUp(Sender)
{
var LY = layer6.Y;
layer6.MoveTo( 6,LY+1,0.2,0,0,0,false)

// x, y , ms, , y , delay, HidenFinish
}

function layer1OnMouseWheelDown(Sender)
{
var LY = layer6.Y;
layer6.MoveTo( 6,LY-1,0.2,0,0,0,false)

// x, y , ms, , y , delay, HidenFinish
}



Attachment:
AIVI_Shortcuts_Window(1).xwp [153.36 KiB]
Downloaded 386 times

Author:  Jimking [ February 25th, 2015, 10:47 am ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

Something like this:

http://jimking.deviantart.com/art/Dark- ... -409966169

Author:  kabott1 [ February 25th, 2015, 1:08 pm ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

Hi jimking, mno, that resizes the obj, i want to scroll up/down like if were scrolling a website. so i need the objects to move up/down (not zoom)

Author:  meme [ February 25th, 2015, 10:53 pm ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

Hi kabott1
Not sure exactly what you want to move up/down ?
var LY = layer6.Y is not returning a value try using var LY = layer6.top
it returns a value and changes with scrolling.

Author:  Jimking [ February 25th, 2015, 11:09 pm ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

kabott1 wrote:
Hi jimking, mno, that resizes the obj, i want to scroll up/down like if were scrolling a website. so i need the objects to move up/down (not zoom)

You need to use this script as base and change the values for the up/down movement.
I have not time to test it now..

Author:  kabott1 [ February 26th, 2015, 3:43 am ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

done! i was calling the value wrong, meme gave me a clue, ill be posting the widget soon! thanks guys!

Author:  kabott1 [ February 26th, 2015, 12:46 pm ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

Here it is, resizable & with mouse scroll :D

Attachment:
2015-02-26_174543.jpg
2015-02-26_174543.jpg [ 14.01 KiB | Viewed 8484 times ]

Attachment:
AIVI_Shortcuts_Window.xwp [153.51 KiB]
Downloaded 417 times

Author:  Jimking [ February 26th, 2015, 5:35 pm ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

Cool! ;)

Author:  meme [ February 26th, 2015, 6:42 pm ]
Post subject:  Re: Scroll Objects OnMouseWheel Up/Down

Nice job

Page 1 of 1 All times are UTC - 8 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/