termux / termux-x11

Termux X11 add-on application.
https://termux.dev
GNU General Public License v3.0
1.96k stars 301 forks source link

Physical right mouse button is not registered #355

Closed xu3s closed 1 year ago

xu3s commented 1 year ago

While using the app when trying to right click it does not get registered, is this can be fixed or is there currently no work around this?

And also middle click just go to home

My devices running android 11 aarch64 if that matter.

twaik commented 1 year ago

I need to know what application prints in debug mode when you try to make a right click.

I already wrote all necessary code to handle right click. But some devices simply do not let intercept it. There is no fix for this.

xu3s commented 1 year ago

Here is the log termux-x11.log

twaik commented 1 year ago

Is it the whole log? I do not see any click attempts or even Termux:X11 app connection...

xu3s commented 1 year ago

Thats the only log that i get by running env TERMUX_X11_DEBUG=1 termux-x11 :0 > tmx11.log & is this wrong?

twaik commented 1 year ago

Did you interact with the program after running this?

xu3s commented 1 year ago

Yes, i run xfce4-session on another tab. Then i tried opening some apps and click and right click there.

twaik commented 1 year ago

It is pretty weird, program must show much more lines...

xu3s commented 1 year ago

I'll try again later, i need to go now

xu3s commented 1 year ago

can this be a reason why the logs is incomplete???

~ $ env TERMUX_X11_DEBUG=1 termux-x11 :0 > tmx11.log
logcat: Unexpected EOF!

This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log
messages as quickly as they were being produced.

If you have enabled significant logging, look into using the -G option to increase log buffer sizes.
logcat: Unexpected EOF!

This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log
messages as quickly as they were being produced.

If you have enabled significant logging, look into using the -G option to increase log buffer sizes.
twaik commented 1 year ago

Unknown...

xu3s commented 1 year ago

so , there is nothing i coud do here???

twaik commented 1 year ago

I can not reproduce this and do not know what to do.

twaik commented 1 year ago

So can you try again with TERMUX_X11_DEBUG to catch this?

xu3s commented 1 year ago

Unfortunately no, i have tried to restart my phone, and even upgraded my os to android 13 that i push back againts still same error: logcat: Unexpected EOF! This means that either the device shut down, logd crashed, or this instance of logcat was unable to read logmessages as quickly as they were being produced.If you have enabled significant logging, look into using the -G option to increase log buffer sizes. I even increases the log buffer size to 100M still the same.

Searching on google still no luck

ThatMG393 commented 1 year ago

@xu3s try clearing data of termux x11

twaik commented 1 year ago

Termux:X11 does not keep any data, nothing to be cleared. But it is possible to obtain logs via ADB.

xu3s commented 1 year ago

Termux:X11 does not keep any data, nothing to be cleared. But it is possible to obtain logs via ADB.

Can you tell me how to do that?

twaik commented 1 year ago

Just google how to use ADB.

twaik commented 1 year ago

Any news on this?

ask9027 commented 1 year ago

Any news on this?

everything is working fine

twaik commented 1 year ago

I was asking @xu3s.

ask9027 commented 1 year ago

I was asking @xu3s.

okay

xu3s commented 1 year ago

sorry, been trying to figure out how to use logcat

trying this command: adb logcat ActivityManager:I com.termux.x11:D *:S but it give no info can someone guide me or just link me to some article about this if possible

twaik commented 1 year ago

adb logcat -c to clear log, start termux-x11 :0 & echo pid is $! and after having aborted message use adb logcat <pid> with pid number you see after starting termux-x11...

xu3s commented 1 year ago

Screenshot_2023_0625_231017.jpg

this is the only thing i got running the command suggested:

~ $ adb logcat -c
~ $ termux-x11 :0 & echo pid is $!
[1] 14004
pid is 14004
~ $ adb logcat 14004
--------- beginning of main
06-25 23:08:42.556 18252  8076 E BufferQueueProducer: [SurfaceView[com.termux.x11/com.termux.x11.MainActivity]#18(BLAST Consumer)18](id:474c00000012,api:1,p:14004,c:18252) query: BufferQueue has been abandoned
06-25 23:08:42.556 18252  8076 E BufferQueueProducer: [SurfaceView[com.termux.x11/com.termux.x11.MainActivity]#18(BLAST Consumer)18](id:474c00000012,api:1,p:14004,c:18252) query: BufferQueue has been abandoned
06-25 23:08:42.573 18252  8076 E BufferQueueProducer: [SurfaceView[com.termux.x11/com.termux.x11.MainActivity]#18(BLAST Consumer)18](id:474c00000012,api:1,p:14004,c:18252) connect: BufferQueue has been abandoned

i run xfce on another session and open termux:X11 app and clicking on it with my mouse, that is the only output.

i'm starting to think that this problem only occur on my device which is vivo t1 5g (anyone with this specific device please help)

twaik commented 1 year ago

Sorry, I was wrong, adb logcat --pid=<pid>

xu3s commented 1 year ago
![Screenshot_2023_0625_232802.jpg](https://github.com/termux/termux-x11/assets/47383486/a4c806df-bef4-43aa-a0d4-3a7239a5156e)

now there is no output

~ $ adb logcat -c
~ $ env TERMUX_X11_DEBUG=1 termux-x11 :0 &                                 
[1] 18884                                                                  
~ $ logcat: Unexpected EOF!                                                
This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log                                          
messages as quickly as they were being produced.                           
If you have enabled significant logging, look into using the -G option to increase log buffer sizes.                                                  
logcat: Unexpected EOF!                                                    
This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log                                          
messages as quickly as they were being produced.                           
If you have enabled significant logging, look into using the -G option to increase log buffer sizes.                                                  
pidof logcat: Unexpected EOF!                                              
This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log                                          
messages as quickly as they were being produced.                           
If you have enabled significant logging, look into using the -G option to increase log buffer sizes.                                            
env TERMUXadb logcat --pid=18884                                                 
logcat: Unexpected EOF!

This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log                                          
messages as quickly as they were being produced.

If you have enabled significant logging, look into using the -G option to increase log buffer sizes.                                                  ^C
~ $
twaik commented 1 year ago

adb logcat --pid=<pid> ...

xu3s commented 1 year ago

maybe my logcat is faulty? it seems like the logcat is crashing when trying to output the log.

twaik commented 1 year ago

You have started env TERMUXadb logcat --pid=18884, not adb logcat --pid=18884...

xu3s commented 1 year ago

adb logcat --pid=<pid> ...

yeah i have run it there but it got buried by the error log of logcat instead, you can see that i run the logcat --pid=pid after i run termux-x11 in the background

twaik commented 1 year ago

logcat --pid does not fit here. That was a reason I adviced you to use ADB and not logcat directly.

xu3s commented 1 year ago

You have started env TERMUXadb logcat --pid=18884, not adb logcat --pid=18884...

that is because i scroll through my recent command, and that does not have a side effect on the command that i run, you can try yourself when you run comand in bg that throw stuff and scroll though history and running it

twaik commented 1 year ago

Start it in another session.

xu3s commented 1 year ago

ok, sorry this is midnight here need to sleep, i have to work tomorrow.

Tomorrow I'll attach a video o you can see what i see, or i can do sharescreen on discord my handle is exelroad

Miguelgrubert commented 1 year ago

Ola poderia falar comigo em português

Em dom., 25 de jun. de 2023 12:49, xu3s @.***> escreveu:

ok, sorry this is midnight here need to sleep, i have to work tomorrow.

Tomorrow I'll attach a video o you can see what i see, or i can do sharescreen on discord my handle is exelroad

— Reply to this email directly, view it on GitHub https://github.com/termux/termux-x11/issues/355#issuecomment-1606155064, or unsubscribe https://github.com/notifications/unsubscribe-auth/BAZZKHAHFE2LP52DUBCZTWTXNBT2VANCNFSM6AAAAAAZMDTXCY . You are receiving this because you are subscribed to this thread.Message ID: @.***>

twaik commented 1 year ago

Official language of this repo is English.

xu3s commented 1 year ago

this is the screen recording of what i get , please enlighten me.

sorry been busy irl lately

twaik commented 1 year ago

It looks like I should connect your phone directly and check what exactly happens here...

xu3s commented 1 year ago

I don't mind. How should i help you to do that?

twaik commented 1 year ago

Contact me in Discord. .twaik

xu3s commented 1 year ago

Ok, mine is exelroad

kulturguda commented 1 year ago

Middle (scroll) and right click do not work for me either. TERMUX_X11_DEBUG=1 termux-x11 :0 registers left click, but neither middle nor right click. Now I'm making right click with double tap or VNC as a solution.

twaik commented 1 year ago

It looks like there is no way to intercept middle and right clicks on such devices. Or I failed to find such a way.