Jelmerro / Vieb

Vim Inspired Electron Browser - Vim bindings for the web by design
https://vieb.dev
GNU General Public License v3.0
1.32k stars 63 forks source link

left mouse click does not follow link on the first click in fresh tabs #489

Closed se7en-x230 closed 1 year ago

se7en-x230 commented 1 year ago

Since the update left click refreshes the page and does not follow the link. Keybinding f works find left click does not

Jelmerro commented 1 year ago

I have only had this issue very occasionally, but then it does work if I click the link a second time. Is this also in line with your experience? I have not been able to find a fix for it as of yet.

se7en-x230 commented 1 year ago

Yes it is a very random thing. Sometimes it works sometimes not.

I generated a new config with my setup b cause I thought something is messing up but that did not solve the problem.

se7en-x230 commented 1 year ago

I moved the .config/vieb folder to generate a completely new one and tested now for 10 min. No problems. So I guess it is something in the config file that causes the behavior.

se7en-x230 commented 1 year ago

https://0x0.st/HTjD.txt

that's my viebrc

Jelmerro commented 1 year ago

I don't think it's the config specifically, but it might be related to other data in the folder. My viebrc is extremely minimal and I also have it, but only in my main instance with a lot of history and data, not in others. Could very well be the result of having some pieces of corrupted chromium data in there somewhere instead of being directly caused by a setting. I don't see any of these settings being related to the problem personally, as the only setting we share is the custom downloadpath... here's my config for comparison: image Are you seeing any errors in the internal devtools (opens with F8) when this happens? I do have some logs in there that could be related, I'll let you know when I know more.

se7en-x230 commented 1 year ago

I renamed the enter Vieb folder Opened Vieb to recreate the entries .config/Vieb folder. Then tested a while without problems. Next i copied my colors/ folder and vievrc into the new created Vieb folder and the problem restated again.

se7en-x230 commented 1 year ago

I will do further tests tomorrow morning

Jelmerro commented 1 year ago

Okay, so I could reproduce this in a completely new Vieb datafolder: it's only doing this if you click on a link in a new tab that hasn't navigated through other means yet. If you use follow mode or explore mode to change the url of the tab and THEN click with the mouse it all keeps working, but if you make a new tab and the FIRST thing you do in it is click on a link then it doesn't work. If you then click on that same link again it does work and that tab will never have that issue again from what I have seen.

Jelmerro commented 1 year ago

I believe to have found the reason for this issue, it's due to a call to the webview on each navigation to change the useragent, which was moved to a new spot in the V10 release, and apparently cancels navigations if called at this moment. After moving the call to the load-commit event instead of the will-navigate event it works again, see this commit for the fix. If you know how to run from source, do let me know if this resolves the problem for you as well.

Jelmerro commented 1 year ago

Fixed in 10.1.0 :tada: