Page 1 of 1

Android Tvbox and infrared remote

Posted: Sat Jan 21, 2023 9:54 pm
by trevix
Hello.
I have a standalone on an Android 11 TvBox (TOX3lite).
If my script opens an Answer dialog (with the usual "OK" or "Cancel"), I am able, using the infrared remote control wheel (up,down, left, right, OK), to move between the 2 buttons and select them, closing in this way the answer dialog!
Any other LC native or not buttons, or fields, or widget fields or else, don't react to the command sent from the infrared remote.

How come?
What makes the ask and answer dialogs so different?
How can I select a text input field using the remote?
Thanks

Trevix

Re: Android Tvbox and infrared remote

Posted: Sun Jan 22, 2023 8:18 pm
by jacque
I don't know the answer but I'm curious how you got the app into the TV box. I have a chromecast with Google TV and there are only a few apps available.

Re: Android Tvbox and infrared remote

Posted: Sun Jan 22, 2023 8:22 pm
by trevix
I installed my standalone on several TvBoxes, using ADB with a USB cable or, if this does not work, using the app "x-ploreFileManager" and getting the APK from google drive.
I don't think that chromecast allow this, but you try.
Regards

Re: Android Tvbox and infrared remote

Posted: Sun Jan 22, 2023 10:36 pm
by jacque
Thanks. You're right, Chromecast can't use ADB. There are third-party sideloading apps but they only connect to the Play Store.

Re: Android Tvbox and infrared remote

Posted: Wed Mar 01, 2023 11:19 am
by trevix
No answers yet, but I just had a revelation:
The answer/ask dialogs are listed in the "inclusion" of the standalone settings.
So, my guess, they have code (lcb? C+?) beside what can be seen inside the "Answer Dialog" stack, enabling the LiveCode UI view.
This code probably is what enables the interaction of the infrared with the dialog buttons.
I know so little about how the infrared controls interact with the OS.
Any light?

Re: Android Tvbox and infrared remote

Posted: Wed Mar 01, 2023 11:58 am
by SparkOut
I have no real clue, but as a trial maybe you could test opening a substack as a modal or palette or play about with window modes, just to see what you get.

Re: Android Tvbox and infrared remote

Posted: Wed Mar 01, 2023 12:16 pm
by trevix
Done: doesn't work

Re: Android Tvbox and infrared remote

Posted: Thu Mar 02, 2023 12:47 pm
by simon.schvartzman
According to the dictionary both Modal and Palette are available for mac, windows, linux and the issue being explored is about Android so I guess none of them will make any difference, I've already quickly tried both options and indeed they don't.

Just wondering if there is something else that could be tried...

Regards

Re: Android Tvbox and infrared remote

Posted: Thu Mar 02, 2023 3:18 pm
by SparkOut
I'm still just guessing, but I "guess" the answer dialog is a call to system native API leaving the OS to render the display.
Is the problem the same with native controls created on the fly with mobileControlCreate... ?

Re: Android Tvbox and infrared remote

Posted: Sat Mar 04, 2023 4:51 pm
by trevix
Yes: no MobileControl created responds to the infrared
I am talking of buttons, off course. Like it happens on the answer dialog, where you can navigate between the cancel and ok buttons using left and right on the remote.
You can type into mobile control created fields (the keyboard appears) but you cannot navigate from field to field.
I am wondering what can reach LC from the OS that receive some signal from the infrared remote. It's a mystery.