1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-03-03 10:15:45 +00:00

Add option to disable the annoying quit confirmation dialog.

This commit is contained in:
Josh Elsasser 2007-04-05 22:28:02 +00:00
parent 91f7df5efd
commit b7c6284dce
3 changed files with 14 additions and 0 deletions

View file

@ -560,6 +560,12 @@ askquit( GtkWindow * parent, callbackfunc_t func, void * cbdata )
struct quitdata * stuff;
GtkWidget * wind;
if( !tr_prefs_get_bool_with_default( PREF_ID_ASKQUIT ) )
{
func( cbdata );
return;
}
stuff = g_new( struct quitdata, 1 );
stuff->func = func;
stuff->cbdata = cbdata;

View file

@ -129,6 +129,11 @@ defs[] =
N_("Display an _icon in the system tray"),
N_("Use a system tray / dock / notification area icon") },
/* PREF_ID_ASKQUIT */
{ "ask-quit", G_TYPE_BOOLEAN, PR_ENABLED, NULL,
N_("Confirm _quit"),
N_("Prompt for confirmation when quitting") },
/* PREF_ID_ADDSTD */
{ "add-behavior-standard", G_TYPE_NONE, PR_ENABLED,
gtk_combo_box_get_type,
@ -187,6 +192,8 @@ defs_bool[] =
{ TRUE, -1, FALSE },
/* PREF_ID_ICON */
{ TRUE, -1, FALSE },
/* PREF_ID_ASKQUIT */
{ TRUE, -1, FALSE },
};
static struct

View file

@ -85,6 +85,7 @@ enum
PREF_ID_NAT,
PREF_ID_PEX,
PREF_ID_ICON,
PREF_ID_ASKQUIT,
PREF_ID_ADDSTD,
PREF_ID_ADDIPC,
PREF_ID_MSGLEVEL,