aboutsummaryrefslogtreecommitdiffstats
path: root/src/empathy.c
diff options
context:
space:
mode:
authorXavier Claessens <xclaesse@src.gnome.org>2008-01-12 19:02:46 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2008-01-12 19:02:46 +0800
commit1f97396a517a53b2699e6def6ef399d6266e0aa8 (patch)
tree0a0e0fc96c6cbbf8636d27ef006fa6c8446e99dc /src/empathy.c
parent923bbd44baad11ae987061a6bec4d572414b792e (diff)
downloadgsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.tar
gsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.tar.gz
gsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.tar.bz2
gsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.tar.lz
gsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.tar.xz
gsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.tar.zst
gsoc2013-empathy-1f97396a517a53b2699e6def6ef399d6266e0aa8.zip
Add option in preference to automatically connect at startup. Fixes bug #499885 (Carl-Anton Ingmarsson).
svn path=/trunk/; revision=539
Diffstat (limited to 'src/empathy.c')
-rw-r--r--src/empathy.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/src/empathy.c b/src/empathy.c
index cbb81931f..185b958dd 100644
--- a/src/empathy.c
+++ b/src/empathy.c
@@ -203,15 +203,8 @@ main (int argc, char *argv[])
MissionControl *mc;
McAccountMonitor *monitor;
EmpathyIdle *idle;
- gboolean no_connect = FALSE;
+ gboolean autoconnect = TRUE;
GError *error = NULL;
- GOptionEntry options[] = {
- { "no-connect", 'n',
- 0, G_OPTION_ARG_NONE, &no_connect,
- N_("Don't connect on startup"),
- NULL },
- { NULL }
- };
empathy_debug_set_log_file_from_env ();
@@ -221,7 +214,7 @@ main (int argc, char *argv[])
if (!gtk_init_with_args (&argc, &argv,
_("- Empathy Instant Messenger"),
- options, GETTEXT_PACKAGE, &error)) {
+ NULL, GETTEXT_PACKAGE, &error)) {
empathy_debug (DEBUG_DOMAIN, error->message);
return EXIT_FAILURE;
}
@@ -247,7 +240,11 @@ main (int argc, char *argv[])
G_CALLBACK (operation_error_cb),
NULL);
- if (!no_connect) {
+ empathy_conf_get_bool (empathy_conf_get(),
+ EMPATHY_PREFS_AUTOCONNECT,
+ &autoconnect);
+
+ if (autoconnect) {
start_mission_control (idle);
}