grssam / User-Style-Manager

Source Code for the addon User Style Manager
https://addons.mozilla.org/en-US/firefox/addon/user-style-manager/
28 stars 4 forks source link

Hitting "Options" button from add-ons manager opens a MODAL window #29

Closed Drugoy closed 12 years ago

Drugoy commented 12 years ago

You can access the same window by middle-clicking your extension's toolbar button and in that case the window is not modal. But if you click "Options" button of your extension from Add-ons manager - the window gets opened modal, so you can't minimize it or access browser's pages with clicks.

Are there any strong reasons for such a difference?

grssam commented 12 years ago

As mentioned in the previous issue, I can't fix this one. Its Firefox behavior. That is the only reason that I provide so many other ways to access the Options window.

Drugoy commented 12 years ago

Oh, sorry, didn't notice that message.

I'm okay that you've closed this issue, but maybe it's better do like AdBlock+ does? just put all your real settings to that page in AOM + add a button "Open 'Styles Manager' window" which would open that window and I hope in that case - you'll be able to make it non modal. huh?

grssam commented 12 years ago

The way adblock plus do things is different as it overlays its own xul files on to the AOM page . If I provide inline settings, then I cannot localize them as I am using a restartless add-on.

Moreover, if your checkbox "Close options window while editing" is checked, then you will be able to switch tabs or minimize the editor, and when you return back to options window by closing the editor, then the newly opened window is non modal.

Drugoy commented 12 years ago

Ok, nvm then.

Drugoy commented 12 years ago

I'm not sure if this helps, but I asked my friend whether you are right or not, and he said that he didn't try, but localizing may be possible: https://developer.mozilla.org/en/Extensions/Bootstrapped_extensions#Adding_user_interface_with_a_chrome.manifest

Could you take a look at that?

Drugoy commented 12 years ago

He created a working proof of concept: http://infocatcher.ucoz.net/temp/customizations_for_adblock_plus-1.0-sm-tb-fx_ru.xpi if you change "general.useragent.locale" pref's value to "ru" - and hit f5 to update settings window - then "Filter preferences customization" line will get translated into Russian.

p.s.: thanks to Infocatcher :)

grssam commented 12 years ago

I will think about it and see what I can do. But reverting back to inline settings is a no go. I can have a work around.

Drugoy commented 12 years ago

But reverting back to inline settings is a no go.

why? all the checkboxes and settings like "pick a hotkey for that" look good when they are inline.

grssam commented 12 years ago

because then I would have to separate things out. Users will have to shift from one window to another to change different settings. the toolbar button will have to point to 2 different pages. I just want everything to be together. As far as this bug is concerned, there might be another way of achieving it.

Drugoy commented 12 years ago

Okay, I got your point and I don't have any problems with that.