Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow sites to open new windows #45

Closed
oonet opened this issue Apr 18, 2020 · 30 comments
Closed

Allow sites to open new windows #45

oonet opened this issue Apr 18, 2020 · 30 comments
Labels
bug Something isn't working stale This probably won't be worked on

Comments

@oonet
Copy link

oonet commented Apr 18, 2020

"Allow sites to open new windows" has no effect. New pages always open in current tab.

Testing with startpage.com, "Open search result in a new window" enabled in Advanced Settings.

Originally worked as expected in Lightning Browser. Broke in Lightning Browser before forked to SmartCookieWeb.

@CookieJarApps
Copy link
Owner

This setting was broken due to a fix for a bug in WebView that caused many sites to crash. I'll see if I can fix the setting, but it will likely have to be removed until Google fixes the bug.

@CookieJarApps CookieJarApps added the bug Something isn't working label Apr 19, 2020
@oonet
Copy link
Author

oonet commented Apr 19, 2020

Google might take longer than you :-)

If the setting has to be removed, maybe replace it with a new setting in the "Page tools" menu to toggle between open all links in new tab (with open in current tab option in context menus) and open all links in current tab (default)?

@CookieJarApps
Copy link
Owner

Ok sure, I'll work on adding an option into page tools in next weeks update - the bug's existed for about 2 years now so it doesn't look like a fix is likely anyway (doesn't happen in Chrome though 🤔 )

@oonet
Copy link
Author

oonet commented Apr 20, 2020

And default to opening links in search results in new tab?

With web pages defaulting to opening links in current tab (able to be overridden per instance or page) and search results defaulting to opening links in new tab . . . the original feature allowing web sites to make the decision shouldn't be missed :-)

@stale
Copy link

stale bot commented Jun 28, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale This probably won't be worked on label Jun 28, 2020
@CookieJarApps
Copy link
Owner

Still going to fix ^

@stale stale bot removed the stale This probably won't be worked on label Jun 28, 2020
@CookieJarApps
Copy link
Owner

"Allow sites to open new windows" has no effect. New pages always open in current tab.

Testing with startpage.com, "Open search result in a new window" enabled in Advanced Settings.

Originally worked as expected in Lightning Browser. Broke in Lightning Browser before forked to SmartCookieWeb.

This seems to work correctly now. If you go to Qwant and choose a search result while this is on, it opens in a new tab like it should, but if it's off it opens in the same tab.

@oonet
Copy link
Author

oonet commented Jul 17, 2020

SmartCookieWeb 7.9.3
Allow sites to open new windows - TRUE

DuckDuckGo
Open Links in a New Tab - TRUE

Links open in current tab.

Qwant.com

Links open in current tab.

@CookieJarApps
Copy link
Owner

I see this - is this the correct behaviour?

ezgif-5-0f1b60dfbaef

@oonet
Copy link
Author

oonet commented Jul 18, 2020

Not clear in video how second tab is opened. Looks like it is being opened manually from tab drawer. . . .

Behavior is correct for "Allow sites to open new windows OFF". Links always open in current tab.

For "Allow sites to open new windows ON", clicked links in Qwant should open in a new tab (leaving the old "current" tab unchanged).

@oonet
Copy link
Author

oonet commented Jul 18, 2020

On second look, it seems some steps are missing from the video (gif). In which case, yes, the behavior is correct. With "Allow sites to open new windows" turned ON, clicking the link in Qwant caused it to open in a new tab.

The behavior in version 7.9.3 is to always open links in current tab - regardless of "Allow sites to open new windows".

@CookieJarApps
Copy link
Owner

On second look, it seems some steps are missing from the video (gif). In which case, yes, the behavior is correct. With "Allow sites to open new windows" turned ON, clicking the link in Qwant caused it to open in a new tab.

The behavior in version 7.9.3 is to always open links in current tab - regardless of "Allow sites to open new windows".

Yeah, it seems to work correctly on my device, but I'll get an emulator set up and see if older Android versions handle the setting differently

@stale
Copy link

stale bot commented Sep 16, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale This probably won't be worked on label Sep 16, 2020
@oonet
Copy link
Author

oonet commented Sep 21, 2020

SmartCookieWeb 8.2.2
Android 10

Qwant opens in current tab (should open in new tab).

SmartCookieWeb 8.4.0
Android 7.0

Qwant opens in current tab (should open in new tab).

@stale stale bot removed the stale This probably won't be worked on label Sep 21, 2020
@CookieJarApps
Copy link
Owner

For me, Qwant does open in a new tab, but I've got some new devices to test on now so I'll try and see what's causing the issue.

@oonet
Copy link
Author

oonet commented Sep 22, 2020

Maybe other settings are interfering? Or I have disabled part of the Android system the feature depends upon? Or maybe the implementation of Android 10 (and 7) is the problem?

For me, Qwant opens cleanly in the same tab every time. With "Allow sites to open new windows" set either way. Can you think of anything else for me to try?

@CookieJarApps
Copy link
Owner

Later today I'll try on some more devices.

@RickyM7
Copy link
Contributor

RickyM7 commented Oct 7, 2020

On my Redmi Note 4 (Miui 11 - Android 7.0) this function works perfectly.

@oonet
Copy link
Author

oonet commented Oct 7, 2020

SmartCookieWeb 8.4.0

Tried on several devices, Android 7 to 10. All opened Qwant links in the current tab (regardless of "Allow sites to open new windows" setting).

Tried with DuckDuckGo browser. Qwant links open in new tab.

What else can you think of that I should try?

@CookieJarApps
Copy link
Owner

CookieJarApps commented Oct 7, 2020

What is the Android 10 device? I might be able to get a physical device or emulator going to try it out. Can you also see if the bug occurs on the device here: http://cookiejarapps.com:8000/#!action=stream&udid=MUE4C18915003742&decoder=broadway&ip=cookiejarapps.duckdns.org&port=8886 - thanks :)

Edit: if you see a black rectangle, you might have to click on it first.

@RickyM7
Copy link
Contributor

RickyM7 commented Oct 7, 2020

@oonet Have you tried to clear the application data? I just finished testing v8.4.0 and the sites open the links in a new tab normally.

@oonet
Copy link
Author

oonet commented Oct 12, 2020

For links to open in new tab, "Request 'Do Not Track'" and "Remove identifying HTTP headers" must both be disabled.

With both settings disabled, feature works as advertised :-)

Ideally, opening links in new tab should work regardless of these two settings.

@CookieJarApps
Copy link
Owner

Thanks, that explains why it worked OK on my phone. I'll fix this in this weekend's update.

@CookieJarApps
Copy link
Owner

I'll release a fix today.

@CookieJarApps
Copy link
Owner

I've fixed this in a commit and an APK is coming in an hour or so, just to let you know, there was a warning in the Lightning Browser code that said changing headers + allowing sites to open a new tab causes crashes. I've tested and haven't seen any, but if you have any issues just reply here and I'll publish a fixed APK.

@RickyM7
Copy link
Contributor

RickyM7 commented Dec 15, 2020

@CookieJarApps Having "Allow sites to open new windows" enabled when the "Remove identifying HTTP headers" and / or "Request 'Do Not Track'" option is enabled causes crashes when clicking on sites that open new windows.
I don't know if it's a known bug but I thought I'd better report it.

Device: Redmi Note 4 (MIUI 11 - Android 7.0)
App version: v11.0.0-beta6

@CookieJarApps
Copy link
Owner

@CookieJarApps Having "Allow sites to open new windows" enabled when the "Remove identifying HTTP headers" and / or "Request 'Do Not Track'" option is enabled causes crashes when clicking on sites that open new windows.
I don't know if it's a known bug but I thought I'd better report it.

Device: Redmi Note 4 (MIUI 11 - Android 7.0)
App version: v11.0.0-beta6

Yeah, it's known, but thanks for reporting :) - originally "allow sites to open new windows" was auto-disabled, but someone requested that they could enable both. I'll probably bring back the auto-disable though.

@RickyM7
Copy link
Contributor

RickyM7 commented Dec 15, 2020

I'll probably bring back the auto-disable though.

I think this is the best way, at least until a better solution is found.

@stale
Copy link

stale bot commented Mar 15, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale This probably won't be worked on label Mar 15, 2021
@CookieJarApps CookieJarApps removed the stale This probably won't be worked on label Mar 16, 2021
@stale
Copy link

stale bot commented Jun 14, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale This probably won't be worked on label Jun 14, 2021
@stale stale bot closed this as completed Jun 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working stale This probably won't be worked on
Projects
None yet
Development

No branches or pull requests

3 participants