Author Topic: KDE Logout Widget Firefox Tabs  (Read 527 times)

Offline xr200

  • Full Member
  • ***
  • Posts: 95
KDE Logout Widget Firefox Tabs
« on: December 12, 2011, 08:33:49 AM »
I'm running KDE and use firefox for my browser.  I have configured firefox to
autostart (under Configure your Desktop -> System Administration -> Autostart)
when KDE starts up.   When firefox starts up, I would like for firefox to
open with a blank page.  I have firefox configured to start with a blank
page (Edit -> Preferences -> When Firefox starts: Show a blank page).   
I have KDE configured to start with an empty session
(Configure your Desktop -> System Administration -> Startup and Shutdown ->
Session Management -> Start with an empty session).

Suppose I have firefox running with several tabs open.

If I then manually kill firefox and then click on the Lock/Logout Icon
to restart the computer, KDE will start up and firefox will autostart
with a blank page (just like I want).

But if I leave firefox running and click on the Lock/Logout Icon to reboot
the computer, KDE will start up and firefox will autostart with all the
previously open tabs restored (which is not what I want).

This occurs identically if I "restart" directly, or "turn off computer"
and power it back on.  Again, if I quit firefox before I click on the
Logout widget, firefox will start up with a blank page.  Also, I did try
manually creating my own "shutdown" icon on the desktop where I wrote a
little script that first kills firefox if it's running, and then calls
shutdown, and that's works the way I want it to: firefox always starts
with a blank page. 

Is there any way I can get the behavior I want (using the Logout widget,
firefox always starts with a blank page)?  I'm hoping I mistakenly have
some preference set incorrectly...

xr200
*

Offline RAIDENSUB

  • Full Member
  • ***
  • Posts: 59
Re: KDE Logout Widget Firefox Tabs
« Reply #1 on: December 12, 2011, 09:11:54 AM »
Because Firefox is open when you reboot is closing unexpected . After closing unexpected the default is to restore all the tabs. This is a Firefox behavior, not KDE. If you want to disable it try this:


http://support.mozilla.com/en-US/kb/Session%20Restore


Go to the section Privacy issues.

Offline xr200

  • Full Member
  • ***
  • Posts: 95
Re: KDE Logout Widget Firefox Tabs
« Reply #2 on: December 12, 2011, 09:53:48 AM »
I followed the link and tried the suggestion: in firefox, go to about:config and set
browser.sessionstore.resume_from_crash to false.  Sure sounded like that was
the fix, but it did not work for me.   I get the exact same behavior as before:
firefox starts up with with all previously open tabs still open.

xr200

Offline xr200

  • Full Member
  • ***
  • Posts: 95
Re: KDE Logout Widget Firefox Tabs
« Reply #3 on: December 12, 2011, 01:21:20 PM »
Here's what I've done as a workaround; I don't consider this a real solution.

I created this executable shell script in $HOME/bin/ffclean


killall -9 -q firefox

ff=<path to my firefox profile directory>

rm -f $ff/lock
rm -f $ff/.parentlock
rm -f $ff/sessionstore*

I then editted the properties of my Autostart/Firefox script to do this:

$HOME/bin/ffclean && /usr/bin/firefox -P <my profile>

Thank you to the previous poster who understood that this was a Firefox, not KDE issue.

I'm just posting this workaround for anyone else who may be experiencing the same issue.

I would prefer a correct solution, but this is the best I can come up with right now...




Offline knome

  • Full Member
  • ***
  • Posts: 72
Re: KDE Logout Widget Firefox Tabs
« Reply #4 on: December 12, 2011, 06:46:30 PM »
I followed the link and tried the suggestion: in firefox, go to about:config and set
browser.sessionstore.resume_from_crash to false
.  Sure sounded like that was
the fix, but it did not work for me.   I get the exact same behavior as before:
firefox starts up with with all previously open tabs still open.

xr200

There are two more about:config settings that you may need to change...

Set browser.sessionstore.max_tabs_undo to 0

Set browser.sessionstore.max_windows_undo to 0
« Last Edit: December 12, 2011, 06:49:01 PM by knome »