Enable/Disable option

Is there any way to add the "Enable" option that the 3.x version of X-Notifier has to the 4.x version (for disabling/enabling the checking for new email)?

I often leave Firefox running, but disable email checks while I am connected to my work VPN.  I don't want to be checking my personal email accounts while connected to my work's network.

Also, I have the browser running while I sleep, and I disable X-Notifier so that I am not awakened by the email notifications, but I can still get any other alerts from other applications.

Please consider adding this fuction back to X-Notifier if possible.

Thanks!

 

jeroen's picture

To solve your sleep problem: you can disable the 'Play a sound' option of X-notifier.

Also, you can eather disable individual accounts in the Options window of X-notifier or the complete extension in the Extensions window of Firefox.

But you might already be aware of that...

Yes, I am aware that I can disable the extension (which is the best way to do what I want at this time, I guess), but that seems a bit of overkill.  Is there a reason that this option cannot be added to the extension (technical or otherwise)?

If it is not going to be added, what is the quickest way to enable/disable an extension?  I will be doing it every day, so right clicking and "manage extension" and then scrolling down to select "disable" is a bit more than I would like.  Enabling it again, I guess, would mean leaving that tab open so I can select it and then select the enable option.

Seems sillygo through this if an enable/disable option can be built in to the tool itself.

jeroen's picture

To enable/disable an extension is a functionality belonging to the browser. So my assumption is Mozilla decided it not safe to give this functionality to an extension and therefore doesn't make this functionality available in the present add-on developer API (Application Programming Interface).

Ctrl+Shift+A is the shortcut for the Add-ons Manager, which you - as you said - can leave open.

Another option is to leave the X-notifier Options window open to enable/disable the sound option.
For this option X-notifier could offer a shortcut. But such a shortcut should be configurable by the user and therefore needs to get addressed in the Options window and I doubt that the developer presently has time to get this done.

Well, I'm not looking for an option to disabe the addon, just an option that does the equivelent of unchecking all the email accounts I have checked in the settings, and then rechecking those same accounts when I enable it again.  I have 7 accounts I check, so unchecking each of those to "disable" the addon and then rechecking each one to "enable" it again would not be practical.

Just unchecking the sound option does not stop the email checks that happen every x minutes, so that option only helps for the sleep situation, but even so, it seems a waste of resources to be checking for email every x minutes when I have no intention of reading that email until I wake up.

EDIT:  In thinking about this, I just want what the 3.x addon had.  You can stop the automatic checking for new mail for all accounts with a single setting and re-enable it again with a single setting.  Also the ability to do an on-demand check for new mail for all accounts (even when the auto check is disabled).  I am not sure why these options were removed, so that is why I was asking if there was a technical or perhaps political reason why they were removed (or not added to the new version).

When the developer had to rewrite for the changes in FF by Mozilla, some features were left behind as the changes in the Application Programming Interface did not allow for the necessary programming. The developer stated he wanted to include everything but couldn't... perhaps the enable/disable option was one of those unduplicatable features.
Otherwise, there are some macro programming tools that allow you to save user actions like mouse clicks, executing hotkeys, shortcut key sequences, etc... that may be of use to provide a 'toggle' feature in one click for all the actions you need to do to accomplish what you want.

I understand that certain functions could not be replicated due to the restrictions with Firefox 57+, but I doubt that this is one of them.  The functionality to check or not check any particular email account is already there, you would just need to add a new flag that if set, would stop the automatic checking for all accounts.   It has nothing to do with the functionality provided by the Firefox API.

I keep many tabs open in my browser, and I like to come back to each tab in the state I left it in, so while exiting the browser all together is an option, it's not an ideal one.  I want the tab to have the same data it did when I left, not load a fresh version of the page it was on (which may have changed).

As for using an automated tool, I did think about doing this (I've used AutoHotkey for several projects, although I don't know if it is ideal for this one), but I am not sure how difficult it would be to implement something to enable/disable an addon.

The Chrome version also does not have this enable/disable toggle.  Maybe it isn't so easy.
I have emailed the developer.

jeroen's picture

I told you: "To enable/disable an extension is a functionality belonging to the browser."
Adding a switch to the extension is not disabling the extension. It stays enabled, but skips basically all it's execution. You probably will say that is the same, but it is not. The result is the same, yes. 

In version 3 the browser preferences (about:config) got used to enable/disable the preference extensions.xnotifier.enabled and an extension was also allowed to set (change) these preferences. You can find it in the code (line 1304) of Main.js of X-notifier 3.5.23:    this.setState(this.MSG_ENABLED,this.prefBranch.getBoolPref("enabled"));

I'm not sure who you are replying to, but I understand the difference.  I don't want to have to disable the extension, just temporarily disable the auto-checks for all the configured email accounts.

As for where the status of this switch would be stored, I have no idea.  It was in the about:config for version 3.x, but it doesn't have to be there for 4.x.  You can obviously set and retain option for the addon, so just store it along wth all those settings (wherever that may be with Firefox 57+).

I've been disabling/enabling the extension every day (twice a day) and it is kind of ridiculous, but I guess that is the best option for now.  I hope this feature can be added to the extension soon (if at all).

CFBancroft's picture

Why don't you set "check interval" 600 minutes = 10 hours! (I am not sure if it allowed 600?)

So that way X-Notifier will not bother you for 10 hours!

If you want to check right NOW? Just click on "Check Now"

Simple like that?

Thanks for the suggestion, but each email account has a separate check interval.  So I would have to change each one, so not practical.  It would be easier just to uncheck each email account if I were to go that route.

I do want the email accounts to be auto-checked, but only when I am awake and not conected to the VPN.

CFBancroft's picture

TOP Browsers...
Chrome
Firefox
Safari
Opera

I guess you use Firefox with X-notifier? (If, Yes)

Then you can use Chrome, Safari or Opera without X-notifier to use
and "via" VPN to work?

If you love Firefox to use with VPN, then use Chrome with X-notifier! ??

Why limit to yourself with one Browsers?
without being hassle to add features on X-notifier?

CFBancroft's picture

I wrote it six years and one week AGO!

http://xnotifier.tobwithu.com/dp/node/253

I think already covered it... with NEW Firefox and Chrome no longer!!! Because of API issue!

WHO BLAME? Bad People try to Break/Hack it... that cause Firefox Dev. removed API...

I stay with Xnotifier-reload with Firefox ESR 52.9.0 UNTIL no longer work... I WILL CRY, CRY!

That all I can say!