question

Phil McGee avatar image
Phil McGee asked

Reducing select/touch of APL list text objects

The APL examples at https://developer.amazon.com/alexa/console/ask/displays#/templates include a TextList example. If I extend it with several more entries, the list becomes scrollable. However, touching the list anywhere in order to scroll it is already firing a selection event so how can I tell the difference between a touch intended to scroll vs a touch to deliberately select? Can the select event be mapped to the little round circle with the item# in it instead of the whole text?

alexaapl
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

Alexander Martin avatar image
Alexander Martin answered

Hi @philchillbill,

i guess what you mean is the hover/focused state (the number is colored)? the command (primaryAction) is actually executed when the user touches the entry. look at this example: https://apl.ninja/document/xeladotbe/h6uVgfnX when you swipe through the list with the mouse button pressed, the number is colored, but the SendEvent is executed only when you click on an entry. this behavior is hard-wired into the alexa templates and cannot be changed.

Regards,

Alex

2 comments
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Yes, but to scroll it I need to touch the list and that already sends the event. There's a difference between touching in order to scroll and touching to select. How is the skill handler to know the difference?

0 Likes 0 ·

in my case scrolling does not trigger an event, I have recorded a video that shows that scrolling does not trigger a SendEvent until I click on the element, this is exactly how it behaves on a real device. https://www.alexandermartin.dev/temp/example-2021-05-17_18.23.27.mp4

0 Likes 0 ·