rNeomy / auto-tab-discard

Use native tab discarding method to automatically reduce memory usage of inactive tabs
https://webextension.org/listing/tab-discard.html
Mozilla Public License 2.0
929 stars 79 forks source link

☑ Display "Open Link in New Discarded Tab" item in the "link" context menu – not displayed #227

Open grahamperrin opened 3 years ago

grahamperrin commented 3 years ago

https://github.com/rNeomy/auto-tab-discard/issues/226#issuecomment-824725758

… we already have a context menu item for links to open a tab in the discarded state. …

The menu item is not apparent with Firefox 88:

https://user-images.githubusercontent.com/192271/115836417-5dcb4780-a40f-11eb-9122-5f1b27fbd73c.mp4

Workaround

Open link in new discarded tab (extension)

grahamperrin commented 3 years ago

Also, the wording of the preference might be more concise. Instead of:

☑ Display "Open Link in New Discarded Tab" item in the "link" context menu

– this should suffice:

☑ Display "Open Link in New Discarded Tab" in the context menu

– or even:

☑ Offer to "Open Link in New Discarded Tab"


Personally, I think that the menu item could be more simply Open in New Discarded Tab because (unless I'm missing something) there's no context other than link.

rNeomy commented 3 years ago

The menu item is not apparent with Firefox 88:

Can you confirm on a new Profile?

– this should suffice:

I am a fan of simplifying things. However, the user needs to know where the context menu is expected. So we somehow need to point to the link context in the description.

rNeomy commented 3 years ago

Personally, I think that the menu item could be more simply Open in New Discarded Tab because (unless I'm missing something) there's no context other than link.

Done!

grahamperrin commented 3 years ago

Can you confirm on a new Profile?

Interesting! I seem to have at least two profiles bugged, but can not reproduce the issue with a new profile.

I wondered whether there's a conflict with Open link in new discarded tab by def00111. As far as I can tell, no conflict:

image

– and the Open Link in New Discarded Tab menu option of Auto Tab Discard remains visible after Open link in new discarded tab (the extension) is disabled.

For https://github.com/rNeomy/auto-tab-discard/commit/b2333c94a5266b337a6f32a788b0139d9da515de did you make the issue reproducible?

rNeomy commented 3 years ago

remains visible after Open link in new discarded tab (the extension) is disabled.

Your FF profile is probably damaged! Migrate to a new one

did you make the issue reproducible?

I haven't tried.

grahamperrin commented 3 years ago

… Migrate to a new one

No problem for the test profile, which I used for the screen recording in the opening post, however my everyday default profile has years' worth of preferences for umpteen extensions and so on.

I should find for myself an explanation for the problem …

grahamperrin commented 3 years ago

my everyday default profile

grahamperrin commented 3 years ago

From opening post https://github.com/rNeomy/auto-tab-discard/issues/227#issue-865841164:

The menu item is not apparent with Firefox 88:

A few minutes ago I found the test profile, which was bugged at the time of the screen recording, not bugged with outdated 0.4.6. Then bugged, then not bugged, then bugged, then not bugged whilst I tested in various ways. A sense of randomness, until …


… I think I made the bug (or symptoms of the bug) reproducible with outdated 0.4.6 with a new profile. Steps, as far as I can tell:

  1. add 0.4.6 https://addons.mozilla.org/firefox/downloads/file/3764231/auto_tab_discard-0.4.6-an+fx.xpi and do not allow in private windows
  2. the link context menu appears ☑
  3. allow in private windows
  4. ⚠ the link context menu disappears.

I have a screen recording of this, however it's a horribly long recording with the (short) interesting bit at the tail end, so I'll not share it unless you want to see it.

Please, does something in https://github.com/rNeomy/auto-tab-discard/commit/b2333c94a5266b337a6f32a788b0139d9da515de fix the four-step case above?


(I'm very interested, because there's a comparable sense of randomness with occasional non-appearance of the page context menu item for Mozilla's Multi-Account Containers extension.)

grahamperrin commented 3 years ago

This profile (named clean) was refreshed a few hours ago:

https://user-images.githubusercontent.com/192271/116594115-c8055000-a919-11eb-853e-59c84a5ea17e.mp4

rNeomy commented 3 years ago

I can reproduce this. Seems like FF does not call any of the initialization event listeners once you enable the extension on the private mode. If you do a restart the menu will appear though.

Chealer commented 3 months ago

@grahamperrin : Could you retitle this to something like:

'Display "Open in New Discarded Tab" item in the "link" context menu' option has no effect