Posts: 143
Joined: Feb 2017
Reputation:
0
There is a horizontal list, so left-right arrows scroll it. All's OK.
Now, can I tap into scrolling with my own events somehow? Defining <onleft> <onright> seems to do nothing.
Posts: 7,805
Joined: Feb 2013
Reputation:
1,484
You can use a fake button to control the list and supply additional actions e.g.
<onleft>Control.Move(ID,-1)</onleft>
<onleft>ADDITIONAL_ACTION</onleft>
The alternative is to use a hidden button in the <focusedlayout> with an <onfocus> condition. But that will just trigger something when the list moves - i.e. you won't be able to define separate actions for left and right individually.
Posts: 143
Joined: Feb 2017
Reputation:
0
Thanks, I'll redesign and use 2nd approach (didn't know that focusable items are allowed on lists).
Posts: 7,805
Joined: Feb 2013
Reputation:
1,484
They aren't really (you will get an error in the log) and you can't use it for official repo submission, but they do work as a hack for an onfocus command