]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-18930 fixed behaviour of dropdown menu selector in gradebook - the headings are...
authorskodak <skodak>
Wed, 22 Apr 2009 20:54:06 +0000 (20:54 +0000)
committerskodak <skodak>
Wed, 22 Apr 2009 20:54:06 +0000 (20:54 +0000)
grade/lib.php
theme/standard/styles_fonts.css
theme/standard/styles_layout.css

index 24d41e16e7ba4c082a762a14697977bf09d78de5..7d81e657adfdcddba46ec0f823b4b5dfcd987352 100644 (file)
@@ -326,11 +326,7 @@ function print_grade_plugin_selector($plugin_info, $return=false) {
 
         $first_plugin = reset($plugins);
 
-        if (is_array($first_plugin)) {
-            $menu[$first_plugin['link'].'&amp;'] = '**header**'.$plugin_info['strings'][$plugin_type];
-        } else {
-            $menu[$plugins['link']] = '**header**'.$plugins['string'];
-        }
+        $menu[$first_plugin['link'].'&amp;'] = '--'.$plugin_info['strings'][$plugin_type];
 
         if (empty($plugins['id'])) {
             foreach ($plugins as $plugin) {
@@ -343,7 +339,6 @@ function print_grade_plugin_selector($plugin_info, $return=false) {
 /// finally print/return the popup form
     if ($count > 1) {
         $select = popup_form('', $menu, 'choosepluginreport', '', get_string('chooseaction', 'grades'), '', '', true, 'self');
-        $select = preg_replace('/\>\*\*header\*\*/', ' class="optionheader">', $select);
         if ($return) {
             return $select;
         } else {
@@ -455,7 +450,8 @@ function grade_get_plugin_info($courseid, $active_type, $active_plugin) {
             $active = $url;
         }
 
-        $plugin_info['settings'] = array('id' => 'coursesettings', 'link' => $url, 'string' => get_string('settings'));
+        $plugin_info['settings'] = array();
+        $plugin_info['settings']['course'] = array('id' => 'coursesettings', 'link' => $url, 'string' => get_string('course'));
         $count++;
     }
 
@@ -522,13 +518,15 @@ function grade_get_plugin_info($courseid, $active_type, $active_plugin) {
                 $active = $url;
             }
 
+            $plugin_info['scale'] = array();
+
             if ($active_type == 'scale' and $active_plugin == 'edit') {
                 $edit_url = $url_prefix.'edit/scale/edit.php?courseid='.$courseid.'&amp;id='.optional_param('id', 0, PARAM_INT);
                 $active = $edit_url;
-                $plugin_info['scale'] = array('id' => 'edit', 'link' => $edit_url, 'string' => get_string('edit'),
+                $plugin_info['scale']['view'] = array('id' => 'edit', 'link' => $edit_url, 'string' => get_string('edit'),
                     'parent' => array('id' => 'scale', 'link' => $url, 'string' => get_string('scales')));
             } else {
-                $plugin_info['scale'] = array('id' => 'scale', 'link' => $url, 'string' => get_string('scales'));
+                $plugin_info['scale']['view'] = array('id' => 'scale', 'link' => $url, 'string' => get_string('view'));
             }
 
             $count++;
index 7b1180a3e93229a9ffd4122e59fc19a7a9dc5f06..e7eb85aa818ddb944f0a1ccdcdc6bdd9e27bedf9 100644 (file)
@@ -618,9 +618,6 @@ body#grade-index .grades .header {
 #grade-aggregation-help code {
     font-style: normal;
 }
-#choosepluginreport_jump option.optionheader {
-    font-weight: bold;
-}
 
 /***
  *** Login
index e2b8531783915978fb32db4b57b2ed6bc7fd29f3..4e4a66b875e02c1eda05355f6218ce8e3b349333 100644 (file)
@@ -2654,14 +2654,6 @@ div.allcoursegrades {
     margin-top: 7px;
 }
 
-#choosepluginreport_jump option {
-    margin-left: 20px;
-}
-
-#choosepluginreport_jump option.optionheader {
-    margin-left: 0px;
-}
-
 /***
  *** Login
  ***/