Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

Context menu only appears in first browser window #28

Closed
SuperGouge opened this issue May 3, 2015 · 6 comments
Closed

Context menu only appears in first browser window #28

SuperGouge opened this issue May 3, 2015 · 6 comments

Comments

@SuperGouge
Copy link

When opening multiple windows, the add-on only works in the first one. In the other ones, the context menu does not appear. I suspect this has to do with the use of the getMostRecentBrowserWindow() function.

@JonnyThree
Copy link

Hello i have a similar problem, so i decided to report it in this thread. The addon doesn't appear in context menu with old "Menu editor" addon installed, there was no problems with old versions of gTranslate. And if i disable it, the context menu is in english: Translate ..... instead of Tradurre ......, local language in my browser is italian.

@bpierre
Copy link
Owner

bpierre commented May 5, 2015

@SuperGouge Indeed, thanks! I will work on it.

@JonnyThree I think your problem may be related to restartless addons that do not use XUL overlays. Do you have the context menu icon with uBlock for example? Are you using Menu Editor II? Have you removed the “Inspect” item by any chance?

@JonnyThree
Copy link

thanks for the answer. yes, i have ublock installed (how you know that?), and the icon of ublock is present. the "menu editor" addon is the same used by user nemesis8185, that have same problem in this thread, last comment: #23

@mote0230
Copy link
Collaborator

mote0230 commented May 6, 2015

I had a look into the menu editor extention, when you first install gtranslate, and translate something, and then go to menu editor it shows up there as "translate [text you selected]", and in the menu editor's save file. If you restart the browser it disappears. Compared to ublock, which shows up as blockElement in the save file. Looking in the source code: https://github.com/chrisaljoudi/uBlock/blob/master/src/js/contextmenu.js#L58

So my guess is that adding an 'id' to the contextmenu entry that isn't variable would solve it.

@bpierre
Copy link
Owner

bpierre commented May 6, 2015

Thanks, I will try that. I need to commit my changes for #26, I will check if it works with the Menu Editor extension.

@andrefidalgosilva
Copy link

Just to add to this, the issue also happens when opening a private browsing window (Firefox 27). I believe fixing the issue with new windows will also fix this, but it won't hurt to have private windows in mind when testing the fix :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants