Page 1 of 1

Firefox resume_session_once bookmarklet?

Posted: Sun Oct 29, 2006 12:10 pm
by Ambush Commander
I had disabled session restore previously in order to determine whether or not it was slowing down my browser (it wasn't). So now I've reenabled it, and I noticed another interesting configuration option:

Code: Select all

browser.sessionstore.resume_session_once
Which would resume the session on the next load of Firefox, but not afterwards; it's a one shot deal. That's quite cool, since Opera's tendency to always save your sessions bugs me a little, but session saving in a non-crash context can be occasionally useful, for instance, if you need to shut down for the night but want to resume, say, a research project tomorrow.

Of course, however, I don't want to be monkeying around with my about:config every time I want this to happen: there should be a button of some sorts that you click and voila, session save is on for just this particular session.

Could I achieve this with, say, a bookmarklet? This would be definitely achievable with a Firefox extension, but I doubt anyone's come out with an extension yet (most of them are not based on the integrated sessionstore functionality), and I'm not so savvy on having to write one out myself.

Posted: Sun Oct 29, 2006 6:21 pm
by Weirdan
it's certainly possible, though it would require enabling untrusted code to access UniversalXPConnect.

Urls you might want to visit:
http://straxus.javadevelopersjournal.co ... eqXPCPerms
http://www.rietta.com/firefox/Tutorial/prefs.html#js

Posted: Tue Oct 31, 2006 6:31 pm
by Ambush Commander
Goodness that looks complicated.