Disable Mouse Wheel in selected nodes

Post Reply
User avatar
Hopki
Gnome
Posts: 10741
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Wed Aug 05, 2020 1:54 pm

Following a Facebook User Group request please find attached a component that will disable the mouse wheel zoom but for selected nodes.

Download and double click to add the component to Pano2VR.
The component works by detecting the tag "disable".

Once the component is added to your skin just tag each node using the User Data panel that should not have mouse wheel interaction with "disable", without the quotes.

Screenshot 2020-08-05 at 12.50.13.png
Screenshot 2020-08-05 at 12.50.13.png (7.52 KiB) Viewed 1916 times

Under the hood for those that want to know:
The component uses two Node Changed, Go To URL actions in a container, the URLs are JavaScript calls.

Code: Select all

javascript:player.setLockedWheel(true)
This disables the mouse wheel.

Code: Select all

javascript:player.setLockedWheel(false)
This enables the mouse wheel.

Both actions use an action filter that checks the tag of the node.
For the deactivate mouse wheel action the action filter is: Tags, contain, disable

For the activate mouse wheel action the action filter is: Tags, not contain, disable

Regards,
Attachments
disable_mouse_wheel.ggskc
(7.56 KiB) Downloaded 31 times
Hopki
Garden Gnome Software Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
Post Reply