Android Question B4XDialog.ShowCustom not work in a projector with ANDROID SYSTEM using remote control.

scsjc

Well-Known Member
Licensed User
Longtime User
Using the B4XDialog.ShowCustom on a projector (with a ANDROID O.S.) with a remote control, it won't let me press the DialogResponse_Positive or DialogResponse_Cancel button, because the KEYS FOCUS of the projector's remote control cursor is still on the screen panel.

Is there any way to avoid this? and that by moving the remote control cursor to the left or right, you can select ACCEPT or CANCEL of the B4XDialog.ShowCustom. ...something like RequestFocus for the B4XDialog.ShowCustom.

The Msgbox2Async works perfectly with projector with a remote control.
Thanks :)

ezgif.com-video-to-gif (6).gif
 
Last edited:

Erel

B4X founder
Staff member
Licensed User
Longtime User
Try to make the buttons focusable:
B4X:
Private Sub MakeFocusable (v As B4XView)
v.As(JavaObject).RunMethod("setFocusable", Array(True))
 v.As(JavaObject).RunMethod("setFocusableInTouchMode", Array(True))

You should call Dialog.GetButton for each button (after you show the dialog and before you call Wait For).
 
Upvote 0
Top