[gnome-commander] GnomeCmdData: set default color theme to GNOME_CMD_COLOR_GREEN_TIGER for root user



commit 752a4f691c4cd4df49be271c3dc2c14e17366041
Author: Piotr Eljasiak <epiotr src gnome org>
Date:   Tue Jun 28 20:14:19 2011 +0200

    GnomeCmdData: set default color theme to GNOME_CMD_COLOR_GREEN_TIGER for root user

 src/gnome-cmd-data.cc |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/gnome-cmd-data.cc b/src/gnome-cmd-data.cc
index 54aeec0..b4bde7d 100644
--- a/src/gnome-cmd-data.cc
+++ b/src/gnome-cmd-data.cc
@@ -36,6 +36,7 @@
 #include "gnome-cmd-user-actions.h"
 #include "filter.h"
 #include "utils.h"
+#include "owner.h"
 #include "dialogs/gnome-cmd-advrename-dialog.h"
 
 using namespace std;
@@ -1114,7 +1115,8 @@ void GnomeCmdData::load()
         g_free (tmp);
     }
 
-    color_mode = (GnomeCmdColorMode) gnome_cmd_data_get_int ("/colors/mode", GNOME_CMD_COLOR_DEEP_BLUE);
+    color_mode = (GnomeCmdColorMode) gnome_cmd_data_get_int ("/colors/mode", gcmd_owner.is_root() ? GNOME_CMD_COLOR_GREEN_TIGER :
+                                                                                                    GNOME_CMD_COLOR_DEEP_BLUE);
 
     gnome_cmd_data_get_color ("/colors/norm_fg", priv->color_themes[GNOME_CMD_COLOR_CUSTOM].norm_fg);
     gnome_cmd_data_get_color ("/colors/norm_bg", priv->color_themes[GNOME_CMD_COLOR_CUSTOM].norm_bg);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]