Thread Tools Display Modes
07/12/15, 06:53 AM   #1
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,579
React to mousewheel while key is pressed

I am looking for a way to cycle through a list with the mouse wheel while holding a key.
All I managed to do right now is zoom the camera...
I wonder if this is even possible without using some hack like placing a Textfield over the whole screen?

Lua Code:
  1. local function StartAction()
  2.   SetGameCameraUIMode(true)
  3.   GuiRoot:SetHandler("OnMouseWheel", function(control, delta, ctrl, alt, shift, command)
  4.     d("wheel")
  5.   end)
  6. end
  7. local function EndAction()
  8.   SetGameCameraUIMode(false)
  9.   GuiRoot:SetHandler("OnMouseWheel", nil)
  10. end
  Reply With Quote
07/12/15, 11:07 AM   #2
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
-- Strike that, see the next post that method is better.

Last edited by circonian : 07/12/15 at 12:41 PM.
  Reply With Quote
07/12/15, 12:41 PM   #3
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
This works:

bindings.xml
Warning: Spoiler


code.lua
Warning: Spoiler

Last edited by circonian : 07/12/15 at 01:04 PM.
  Reply With Quote
07/12/15, 12:58 PM   #4
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,579
Thank you very much!
I remembered that Chip mentioned action layers in a different thread a few days ago and started investigating them.
I pretty much arrived at the same solution.
Yours looks a bit simpler though
  Reply With Quote
07/12/15, 01:05 PM   #5
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
no problem, glad I could help.
  Reply With Quote

ESOUI » Developer Discussions » General Authoring Discussion » React to mousewheel while key is pressed


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off