Index: gnome-theme-manager.c
===================================================================
RCS file: /cvs/gnome/gnome-control-center/capplets/theme-switcher/gnome-theme-manager.c,v
retrieving revision 1.60
diff -u -r1.60 gnome-theme-manager.c
--- gnome-theme-manager.c	25 Apr 2006 21:30:45 -0000	1.60
+++ gnome-theme-manager.c	22 Jul 2006 15:51:02 -0000
@@ -1238,7 +1238,22 @@
   gtk_widget_set_sensitive(WID("meta_theme_revert_button"), FALSE);  
   reverted = TRUE;
 }
-	
+
+
+/* Find out if the lockdown key has been set. Currently returns false on error... */
+static gboolean
+get_lockdown_status ()
+{
+  GConfClient *client;
+  gboolean result;
+
+  client = gconf_client_get_default ();
+  result = gconf_client_get_bool (client, LOCKDOWN_KEY, NULL);
+  g_object_unref (client);
+
+  return result;
+}
+
 static void
 setup_dialog (GladeXML *dialog)
 {
@@ -1341,6 +1356,16 @@
 
   update_font_button_state (dialog);
   update_background_button_state (dialog);
+
+  if (get_lockdown_status ())
+  {
+	/* theme changing has been disabled by the system administrator */
+	gtk_widget_set_sensitive (WID ("meta_theme_hbox"),FALSE);
+	gtk_widget_set_sensitive (WID ("meta_theme_notebook"),FALSE);
+	gtk_widget_show (WID ("lockdown_hbox"));
+  }
+
+
   gtk_widget_show (parent);
 
 }
Index: gnome-theme-manager.h
===================================================================
RCS file: /cvs/gnome/gnome-control-center/capplets/theme-switcher/gnome-theme-manager.h,v
retrieving revision 1.11
diff -u -r1.11 gnome-theme-manager.h
--- gnome-theme-manager.h	3 Jan 2006 10:06:50 -0000	1.11
+++ gnome-theme-manager.h	22 Jul 2006 15:51:02 -0000
@@ -7,10 +7,11 @@
 
 #define GTK_THEME_KEY      "/desktop/gnome/interface/gtk_theme"
 #define ICON_THEME_KEY     "/desktop/gnome/interface/icon_theme"
-#define FONT_KEY	   "/desktop/gnome/interface/font_name"
+#define FONT_KEY           "/desktop/gnome/interface/font_name"
 #define DESKTOP_FONT_KEY   "/apps/nautilus/preferences/desktop_font"
 #define MONOSPACE_FONT_KEY "/desktop/gnome/interface/monospace_font_name"
-#define BACKGROUND_KEY	   "/desktop/gnome/background/picture_filename"
+#define BACKGROUND_KEY     "/desktop/gnome/background/picture_filename"
+#define LOCKDOWN_KEY       "/desktop/gnome/lockdown/disable_theme_settings"
 
 #define METACITY_THEME_DIR "/apps/metacity/general"
 #define METACITY_THEME_KEY METACITY_THEME_DIR "/theme"
Index: theme-properties.glade
===================================================================
RCS file: /cvs/gnome/gnome-control-center/capplets/theme-switcher/theme-properties.glade,v
retrieving revision 1.35
diff -u -r1.35 theme-properties.glade
--- theme-properties.glade	28 Apr 2006 19:03:07 -0000	1.35
+++ theme-properties.glade	22 Jul 2006 15:51:02 -0000
@@ -17,6 +17,7 @@
   <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
   <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
   <property name="focus_on_map">True</property>
+  <property name="urgency_hint">False</property>
   <property name="has_separator">False</property>
 
   <child internal-child="vbox">
@@ -71,6 +72,60 @@
 	  <property name="spacing">6</property>
 
 	  <child>
+	    <widget class="GtkHBox" id="lockdown_hbox">
+	      <property name="homogeneous">False</property>
+	      <property name="spacing">6</property>
+
+	      <child>
+		<widget class="GtkImage" id="image23">
+		  <property name="visible">True</property>
+		  <property name="stock">gtk-dialog-warning</property>
+		  <property name="icon_size">4</property>
+		  <property name="xalign">0.5</property>
+		  <property name="yalign">0.5</property>
+		  <property name="xpad">0</property>
+		  <property name="ypad">0</property>
+		</widget>
+		<packing>
+		  <property name="padding">0</property>
+		  <property name="expand">False</property>
+		  <property name="fill">True</property>
+		</packing>
+	      </child>
+
+	      <child>
+		<widget class="GtkLabel" id="lockdown_label">
+		  <property name="visible">True</property>
+		  <property name="label" translatable="yes">&lt;b&gt;You do not have permission to change theme settings&lt;/b&gt;</property>
+		  <property name="use_underline">False</property>
+		  <property name="use_markup">True</property>
+		  <property name="justify">GTK_JUSTIFY_LEFT</property>
+		  <property name="wrap">False</property>
+		  <property name="selectable">False</property>
+		  <property name="xalign">0.5</property>
+		  <property name="yalign">0.5</property>
+		  <property name="xpad">0</property>
+		  <property name="ypad">0</property>
+		  <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+		  <property name="width_chars">-1</property>
+		  <property name="single_line_mode">False</property>
+		  <property name="angle">0</property>
+		</widget>
+		<packing>
+		  <property name="padding">0</property>
+		  <property name="expand">False</property>
+		  <property name="fill">False</property>
+		</packing>
+	      </child>
+	    </widget>
+	    <packing>
+	      <property name="padding">0</property>
+	      <property name="expand">False</property>
+	      <property name="fill">False</property>
+	    </packing>
+	  </child>
+
+	  <child>
 	    <widget class="GtkHBox" id="meta_theme_hbox">
 	      <property name="visible">True</property>
 	      <property name="homogeneous">False</property>
@@ -745,8 +800,8 @@
 	    </widget>
 	    <packing>
 	      <property name="padding">0</property>
-	      <property name="expand">False</property>
-	      <property name="fill">False</property>
+	      <property name="expand">True</property>
+	      <property name="fill">True</property>
 	    </packing>
 	  </child>
 	</widget>
@@ -774,6 +829,7 @@
   <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
   <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
   <property name="focus_on_map">True</property>
+  <property name="urgency_hint">False</property>
   <property name="has_separator">False</property>
 
   <child internal-child="vbox">
@@ -1562,6 +1618,7 @@
   <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
   <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
   <property name="focus_on_map">True</property>
+  <property name="urgency_hint">False</property>
   <property name="has_separator">False</property>
 
   <child internal-child="vbox">
