GNOME Bugzilla – Bug 306755
gnome-sound-recorder does not ask to save the files
Last modified: 2005-06-10 13:06:16 UTC
Steps to reproduce: -------------------- 1. Launch gnome-sound-recorder 2. Record some audio 3. Close the window. Bug: gnome-sound-recorder does not ask to save the files.
If there are any unsaved files, throw up a dialog before exiting, asking whether user wants to save the file or quit without saving. Will be attaching a patch soon.
Created attachment 47387 [details] [review] Proposed patch
Have added a gboolean value in the GSRWindowPrivate structure to store the state (saved/unsaved) of the current window. Before exiting, check whether this value is false. If it is false, then throw up a dialog asking whether user wants to save it or exit without saving. And then handle user response accordingly.
Hi Archana, two things: * button order seems odd; you have no, cancel, yes. I thought the normal order was cancel, no, yes. Can you change that? * if the user presses yes, you save the file, but the widget does not get destroyed. Is that intentional?
Hi Ronald, > * button order seems odd; you have no, cancel, yes. I thought the normal order > was cancel, no, yes. Can you change that? ui for the dialog is taken from gedit. Following is from the hig guidelines. -------------------------------------------------------------------------------- A confirmation alert... * uses the stock warning icon. * presents a button labelled with a verb or verb phrase describing the action to be confirmed, or labelled OK if such a phrase would be longer than three words. This button is placed in the bottom right corner of the alert. * presents a Cancel button that will prevent execution of the user's command. This button is placed to the immediate left of the OK or equivalent button. * may present an alternate action button or a convenience button. Place this button to the left of the Cancel button. -------------------------------------------------------------------------------- > * if the user presses yes, you save the file, but the widget does not get > destroyed. Is that intentional? Window should be destroyed after a save, attaching the patch with the changes. Please review.
Created attachment 47494 [details] [review] Patch with the suggested changes
Looks good, thanks Archana.
Committed the patch, Thanks.