=== modified file 'data/empathy.schemas.in'
--- data/empathy.schemas.in	2010-03-12 16:47:09 +0000
+++ data/empathy.schemas.in	2010-03-22 15:17:15 +0000
@@ -522,6 +522,20 @@
     </schema>
 
     <schema>
+      <key>/schemas/apps/empathy/autoaway</key>
+      <applyto>/apps/empathy/autoaway</applyto>
+      <owner>empathy</owner>
+      <type>bool</type>
+      <default>true</default>
+      <locale name="C">
+        <short>Empathy should auto-away when idle</short>
+        <long>
+        Whether Empathy should go into away mode automatically if user is idle.
+        </long>
+      </locale>
+    </schema>
+
+    <schema>
       <key>/schemas/apps/empathy/import_asked</key>
       <applyto>/apps/empathy/import_asked</applyto>
       <owner>empathy</owner>

=== modified file 'libempathy-gtk/empathy-conf.h'
--- libempathy-gtk/empathy-conf.h	2010-03-12 16:47:09 +0000
+++ libempathy-gtk/empathy-conf.h	2010-03-22 15:17:15 +0000
@@ -81,6 +81,7 @@
 #define EMPATHY_PREFS_HINTS_CLOSE_MAIN_WINDOW      EMPATHY_PREFS_PATH "/hints/close_main_window"
 #define EMPATHY_PREFS_USE_CONN                     EMPATHY_PREFS_PATH "/use_conn"
 #define EMPATHY_PREFS_AUTOCONNECT                  EMPATHY_PREFS_PATH "/autoconnect"
+#define EMPATHY_PREFS_AUTOAWAY                     EMPATHY_PREFS_PATH "/autoaway"
 #define EMPATHY_PREFS_IMPORT_ASKED                 EMPATHY_PREFS_PATH "/import_asked"
 #define EMPATHY_PREFS_BUTTERFLY_LOGS_MIGRATED      EMPATHY_PREFS_PATH "/butterfly_logs_migrated"
 #define EMPATHY_PREFS_FILE_TRANSFER_DEFAULT_FOLDER EMPATHY_PREFS_PATH "/file_transfer/default_folder"

=== modified file 'src/empathy.c'
--- src/empathy.c	2010-03-24 11:24:29 +0000
+++ src/empathy.c	2010-03-30 09:12:20 +0000
@@ -549,6 +549,18 @@
       account_manager_chatroom_ready_cb, chatroom_manager);
 }
 
+static void
+empathy_idle_set_auto_away_cb (EmpathyConf *conf, 
+				const gchar *key, 
+				gpointer user_data)
+{
+	gboolean autoaway;
+	empathy_conf_get_bool (conf, key, &autoaway);
+
+	empathy_idle_set_auto_away(empathy_idle_dup_singleton (),
+				   autoaway);
+}
+
 int
 main (int argc, char *argv[])
 {
@@ -572,7 +584,7 @@
   GError *error = NULL;
   UniqueApp *unique_app;
   gboolean chatroom_manager_ready;
-
+  gboolean autoaway = TRUE;
 #ifdef ENABLE_DEBUG
   TpDebugSender *debug_sender;
 #endif /* ENABLE_TPL */
@@ -641,7 +653,16 @@
 
   /* Setting up Idle */
   idle = empathy_idle_dup_singleton ();
-  empathy_idle_set_auto_away (idle, TRUE);
+
+  empathy_conf_get_bool (empathy_conf_get (),
+      EMPATHY_PREFS_AUTOAWAY, &autoaway);
+
+  empathy_conf_notify_add (empathy_conf_get (),
+			   EMPATHY_PREFS_AUTOAWAY,
+			   empathy_idle_set_auto_away_cb,
+			   NULL);
+
+  empathy_idle_set_auto_away (idle, autoaway);
 
   /* Setting up Connectivity */
   connectivity = empathy_connectivity_dup_singleton ();

