[LON-CAPA-cvs] cvs: loncom(GCI_2) /interface lonpreferences.pm

gci gci@source.lon-capa.org
Wed, 23 Sep 2009 15:32:00 -0000


gci		Wed Sep 23 15:32:00 2009 EDT

  Modified files:              (Branch: GCI_2)
    /loncom/interface	lonpreferences.pm 
  Log:
  - Customization for GCI_2.
  
  
Index: loncom/interface/lonpreferences.pm
diff -u loncom/interface/lonpreferences.pm:1.125.8.1 loncom/interface/lonpreferences.pm:1.125.8.2
--- loncom/interface/lonpreferences.pm:1.125.8.1	Wed Sep 23 15:12:54 2009
+++ loncom/interface/lonpreferences.pm	Wed Sep 23 15:32:00 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Preferences
 #
-# $Id: lonpreferences.pm,v 1.125.8.1 2009/09/23 15:12:54 gci Exp $
+# $Id: lonpreferences.pm,v 1.125.8.2 2009/09/23 15:32:00 gci Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1857,22 +1857,24 @@
                       printmenu => 'yes',
                       subroutine => \&verify_and_change_colors,
                       }));
-    push (@Options,({ action => 'changelanguages',
-                      linktext => 'Change Language Preferences',
-                      href => '/adm/preferences',
-		      help => 'Prefs_Language',
-                      breadcrumb=>
-                          { href => '/adm/preferences?action=changelanguages',
-                            text => 'Change Language'},
-                      subroutine =>  \&languagechanger,
-                  },
-                    { action => 'verify_and_change_languages',
-                      breadcrumb=>
-                          {href => '/adm/preferences?action=changelanguages',
-                           text => 'Change Language'},
-                      printmenu => 'yes',
-                      subroutine=>\&verify_and_change_languages, }
+    if ($env{'user.adv'}) {
+        push (@Options,({ action => 'changelanguages',
+                          linktext => 'Change Language Preferences',
+                          href => '/adm/preferences',
+	    	          help => 'Prefs_Language',
+                          breadcrumb=>
+                              { href => '/adm/preferences?action=changelanguages',
+                                text => 'Change Language'},
+                          subroutine =>  \&languagechanger,
+                      },
+                        { action => 'verify_and_change_languages',
+                          breadcrumb=>
+                              {href => '/adm/preferences?action=changelanguages',
+                               text => 'Change Language'},
+                          printmenu => 'yes',
+                          subroutine=>\&verify_and_change_languages, }
                     ));
+    }
     push (@Options,({ action => 'changewysiwyg',
                       linktext => 'Change WYSIWYG Editor Preferences',
                       href => '/adm/preferences',
@@ -1965,22 +1967,23 @@
                             text => 'Change Main Menu'},
                       printmenu => 'yes',
                       }));
-
-    push (@Options,({ action   => 'changeclicker',
-                      linktext => 'Register Response Devices ("Clickers")',
-                      href     => '/adm/preferences',
-                      subroutine => \&clickerchanger,
-                      breadcrumb =>
-                          { href => '/adm/preferences?action=changeclicker',
-                            text => 'Register Clicker'},
-                      },
-                    { action   => 'verify_and_change_clicker',
-                      subroutine => \&verify_and_change_clicker,
-                      breadcrumb =>
-                          { href => '/adm/preferences?action=changeclicker',
-                            text => 'Register Clicker'},
-                      printmenu => 'yes',
-                      }));
+    if ($env{'user.adv'}) {
+        push (@Options,({ action   => 'changeclicker',
+                          linktext => 'Register Response Devices ("Clickers")',
+                          href     => '/adm/preferences',
+                          subroutine => \&clickerchanger,
+                          breadcrumb =>
+                              { href => '/adm/preferences?action=changeclicker',
+                                text => 'Register Clicker'},
+                          },
+                          { action   => 'verify_and_change_clicker',
+                          subroutine => \&verify_and_change_clicker,
+                          breadcrumb =>
+                              { href => '/adm/preferences?action=changeclicker',
+                                text => 'Register Clicker'},
+                          printmenu => 'yes',
+                          }));
+    }
     my %author_roles = &Apache::lonnet::get_my_roles($user,$domain,'userroles','',['au']);
     if (keys(%author_roles) > 0) {
       push (@Options,({ action   => 'changedomcoord',