GNOME Bugzilla – Bug 149447
gnome-session-save presents a GUI - always!
Last modified: 2006-11-15 22:15:13 UTC
Description of Problem: --help documents the use of --gui for showing a GUI alert saying the session is saved. There is no --nogui command line option, and there is also no way to turn the dialog off, which results in on-battery UPS events presenting an alert. (UPS monitor autosaves the session upon going on battery backup and with less than 60 seconds of power remaining) Steps to reproduce the problem: 1. run gnome-session-save Actual Results: see the (unexpected and unswitchable, system modal) dialog Expected Results: no dialog at all How often does this happen? 100% of the time Additional Information: have a nice day! =)
Created attachment 46065 [details] [review] patch for HEAD This patch adds a --silent option. This is quite useful when interaction with the user is impossible or undesirable. Is this ok to commit?
Hmm, is this patch supposed to: - Log out - Shutdown Or restart the computer? Because that's the options I have available on my Fedora machine. + {"silent", '\0', POPT_ARG_NONE, &silent, 0, N_("No not require confirmation"), NULL}, And that's not english ;)
It is intended to allow a non-interactive, programmatic, clean session kill/logout. I have no excuse for the typo. :)
Created attachment 49096 [details] [review] updated patch Fixed typo.
for the record: I've tested this patch on Ubuntu and gnome-session 2.11.91-0ubuntu3, and it worked like it should, the user is logged off nicely.
the reason why I'd like to see this applied is that gnome-screensaver has an option to show a "logout" button on the password-dialog that is useful for computers where users are not allowed to lock the session for a long time (classrooms etc.) so, now that 2.13 is open, how about it?-)
still no progress?? This is desperately needed for gnome-screensaver..
This is desperately needed as it may help address bug 316037 (http://bugzilla.gnome.org/show_bug.cgi?id=316037) which is still driving me nuts. W
This looks okay to me, but: + we're feature frozen (release team might accept the patch, though) + what about --kill? Doesn't it do what you're looking for?
this would be used _with_ --kill, so that the session is saved and killed, without showing the confirmation dialog. I don't know why the dialog defaults to be shown (even without --gui)
would this make gnome-session work without --gui like it should (ie. not ask for a confirmation)? --- save-session.c-orig 2006-02-13 18:13:35.516679000 +0200 +++ save-session.c 2006-02-13 18:12:42.112138000 +0200 @@ -76,7 +76,8 @@ to. Some of them aren't particularly useful. Interestingly, there is no way to request a shutdown without a save. */ gnome_client_request_save (client, GNOME_SAVE_BOTH, zap, - GNOME_INTERACT_ANY, 0, 1); + gui ? GNOME_INTERACT_ANY: GNOME_INTERACT_NONE, + 0, 1);
I've now tested this simple patch with g-s-2.13.91, and it works like I expected: gnome-session-save --kill: no gui shown, logs the user out gnome-session-save --kill --gui: shows the "log out / switch user" dialog" so, why not apply this while we still have time. It doesn't break any string freeze while fixing an annoying bug =) No module should rely anymore on gnome-session-save showing a gui without the option.
I second the motion :) Please fix so hopefully I don't go insane with all the double-logging out stuff. W
_please_ apply this now that 2.14.0 is out.. it could make it in 2.14.1 right?
I can confirm the bug exists in 2.14.0 and I still need to hit the logout button 2x to actually logout/quit/restart.. (see http://bugzilla.gnome.org/show_bug.cgi?id=316037 ) Actually I get two unwanted dialog boxes: 1. A warning that certain windows do not support "save current setup" 2. "Your session has been saved" W
It's been 3 months.... Any chance of this getting into 2.15? W
four months.. anyone? I am *STILL* getting a double-logout dialog message.. W
This patch seems unobjectionable to me. If I could check it in, I would. I think the "Your session has been saved" dialog should be removed. It doesn't seem very useful. Is there some reason to present this info to the user?
*** Bug 324465 has been marked as a duplicate of this bug. ***
Created attachment 73478 [details] [review] patch to remove the dialog This patch removes the pesky dialog entirely. It doesn't seem very useful and there are several complaints about it in bugzilla, e.g. bug #316037. The GNOME_INTERACT_NONE part of the earlier patch here should be kept (and made conditional on --gui only); but otherwise I think with this we don't need --silent.
I committed Tom's patch. Jon's patch need to wait for 2.17 since it adds a new string. I also propose to make --gui the default behavior, and remove this option (or at least hide it).
If you make --gui the default then I think you need to add a new option to disable it. I think it would probably be preferable to just check in the patch in comment #11. The rest of the --silent patch is not really necessary.
(In reply to comment #22) > If you make --gui the default then I think you need to add a new > option to disable it. I think it would probably be preferable to > just check in the patch in comment #11. The rest of the --silent > patch is not really necessary. Applying the patch from comment #11 has the side-effect that people using gnome-session-save will see a change in the default behavior, which can be quite annoying if it makes you lose some data ;-)
Yeah, I see what you mean about changing the default behavior. I sure hope this isn't a safety issue, though. I think that would mean that there are some fairly severe application bugs...
Committed. At last!
Thanks, Vince!