[Xfce-bugs] [Bug 5730] add a way to delete sessions

bugzilla-daemon at xfce.org bugzilla-daemon at xfce.org
Thu Mar 31 23:32:13 CEST 2011


https://bugzilla.xfce.org/show_bug.cgi?id=5730

--- Comment #12 from Jérôme Guelfucci <jeromeg at xfce.org> 2011-03-31 23:32:11 CEST ---
(In reply to comment #11)
> Created attachment 3590 [details]
> Proposed patch (2)
> 
> Thanks for the feedback!

Thanks for the quick follow up!

> 
> (In reply to comment #7)
> > The current patch looks ok.
> > 
> > I have two suggestions though:
> > 
> > 1) I think the button should only be sensitive when there is something to
> > delete. A check when creating the dialog is enough, no need to monitor. When
> > finishing the cache cleaning, we would just set the state to insensitive. It's
> > not a big deal but it makes sense IMO.
> > 
> > 2) The description in the confirmation dialog could be improved by saying what
> > could potentially be lost. I don't know everything we can store in session
> > files, but at least saved applications.
> > 
> > Re deleting Thunar and Xfwm4 session files, it makes sense IMO.
> 
> 1) I think it's more annoying than expected, because the "save session" button
> can write items in there, and restarting Thunar/xfwm4 also (and in this case,
> if the button stays greyed out it's misleading).

Good point which I hadn't considered, let's forget this then!

> 
> 2) I tried to improve that a bit, feel free to change it.

Looks fine to me.
> 
> (In reply to comment #9)
> > When you start a new session the thunar xfwm4 and other session files are
> > invalid because the app is assigned a new client-id, so you can safely delete
> > those too.
> 
> I included a check to delete them as well. However, when thunar/xfwm4 starts, a
> state file is written for them with their *current* client-id... Is it really
> safe to remove that?
> 
> (In reply to comment #10)
> > Officially xfce4-session does not depend on gio and because session files are
> > always local, I'd say a g_dir_open; walk; g_unlink; will do.
> 
> Done. It doesn't delete everything though (I'm thinking about people using
> several desktop environments who won't be happy if everything is deleted, so I
> only delete "xfce4-session-*", "Thunar-*", "xfwm4-*"...).

I just have one itch with the new patch, the g_critical and g_warning: I know
this shouldn't happen in most cases but I don't like throwing errors to the
console and filling logs which are never read. Shouldn't we warn the user with
a dialog that clearing the session failed (like in the first version of your
patch)?

-- 
Configure bugmail: https://bugzilla.xfce.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the Xfce-bugs mailing list