-
-
Notifications
You must be signed in to change notification settings - Fork 183
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
Incognito windows restored as normal windows in Chrome #342
Comments
Oh, okay, I had to enable the |
Because of Chrome's specification, it is impossible to open a session in private window. https://developer.chrome.com/extensions/manifest/incognito
|
Hmm interesting, but session buddy is able to open them in incognito windows somehow. |
I can confirm saving incognito windows. Although by reviewing the auto save history, there were times it haven't save them. :EDIT: as @ym1234 stated, it should be possible to reopen saved tabs as incognito. |
Can the "invalid" tag please be removed? As @ym1234 mentioned, Session Buddy is able to both save and restore to incognito windows, and to me that's one of the fundamental features that I use in Session Buddy which I would love to see in Tab Session manager. Also, @DedupOperator: Do you mean that it should be generally possible to reopen saved tabs as incognito or specifically in Tab Session Manager? |
@ym1234 do you mind changing the issue title - say "Incognito windows restored as normal windows in Chrome"? Skimming through the code:
Looking around a single commit adds both hunks referenced - but it only adds Chrome support by reshuffling things around. There is no incognito support afaict. So I've tried removing the Firefox guard - now all the tabs are opened in the same normal window... I think. Dropping the @sienori can you share some tips and ideas? |
Done, doesn't look like there is any intention to fix this issue though. |
I guess things got burred and/or the fix does not seems obvious... Speaking of which, I've got to the bottom of it 🎉 Tl;Dr: As the replace.html of "Tab Lazy Loading" is loader, the incognito tab moves to the normal window. Yes, the Firefox guard must be nuked. Since lazy-loading is a must for me, I'll take a look at enabling discard for Chrome. Stay tuned I should have something over the weekend. |
@ym1234 didn't get the time for a proper fix, but in the meanwhile here is what I've been using: commit 97b0ff7304a7b279963d2158ca03e68f942535b4
Author: Emil Velikov <emil.l.velikov@gmail.com>
Date: Mon Nov 2 11:19:59 2020 +0000
HACKY: chrome: restore incognito windows as such
Current code, only restores the incognito mode for Firefox. Although
by removing the guard, we end up with incognito tabs in the main
window. That's due to the lazy loading - aka our assets are not allowed
within the incognito tab.
Note: this might be a bug, since incognito split mode (as in the json
manifest) implies that this should work ... while the spanning mode
explicitly forbids it.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
diff --git a/src/background/open.js b/src/background/open.js
index a539a86..8a0b9b3 100644
--- a/src/background/open.js
+++ b/src/background/open.js
@@ -19,10 +19,8 @@ export async function openSession(session, property = "openInNewWindow") {
const openInNewWindow = async () => {
log.log(logDir, "openSession() openInNewWindow()");
let createData = {};
- if (browserInfo().name === "Firefox") {
- const firstTab = session.windows[win][Object.keys(session.windows[win])[0]];
- createData.incognito = firstTab.incognito;
- }
+ const firstTab = session.windows[win][Object.keys(session.windows[win])[0]];
+ createData.incognito = firstTab.incognito;
const isSetPosition =
getSettings("isRestoreWindowPosition") && session.windowsInfo != undefined;
@@ -168,7 +166,7 @@ function openTab(session, win, currentWindow, tab, isOpenToLastIndex = false) {
}
//Lazy loading
- if (getSettings("ifLazyLoading")) {
+ if (browserInfo().name == "Firefox" && getSettings("ifLazyLoading")) {
if (getSettings("isUseDiscarded") && isEnabledDiscarded) {
if (!createOption.active && !createOption.pinned) {
createOption.discarded = true;
diff --git a/src/settings/defaultSettings.js b/src/settings/defaultSettings.js
index c010ce2..0032435 100644
--- a/src/settings/defaultSettings.js
+++ b/src/settings/defaultSettings.js
@@ -16,7 +16,9 @@ export default [
title: "ifLazyLoadingLabel",
captions: ["ifLazyLoadingCaptionLabel"],
type: "checkbox",
- default: true,
+ // TODO: Chrome: add discard support and rework/expose to users
+ default: browserInfo().name == "Firefox"
+ shouldShow: browserInfo().name == "Firefox"
childElements: [
{
id: "isUseDiscarded", |
I fixed this problem in version 6.9.0. cc1aafc |
Short description
Private (Incognito) aren't remembered (Even with the option enabled)
Steps to reproduce
Save private window
Expected result
Saves the incognito window
Actual result
Doesn't save the incognito window(s)
Platform information
The text was updated successfully, but these errors were encountered: