]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-15498: Completion system, help buttons aren't supposed to show when editing
authorsam_marshall <sam_marshall>
Fri, 22 Aug 2008 15:46:30 +0000 (15:46 +0000)
committersam_marshall <sam_marshall>
Fri, 22 Aug 2008 15:46:30 +0000 (15:46 +0000)
course/lib.php

index ff9e5ad341aed7f731b54cf8562f444d682761f7..7697482271bda66aa5832cc5dcefd0af351fd287 100644 (file)
@@ -1503,7 +1503,7 @@ function print_section($course, $section, $mods, $modnamesused, $absolute=false,
                         // In manual mode the icon is a toggle form.
                         echo "
 <form class='togglecompletion' method='post' action='togglecompletion.php'><div>";
-                        if(!$shownhelp) {
+                        if(!$shownhelp && !$isediting) {
                             helpbutton('completionicons',get_string('completionicons','completion'),'completion');
                             $shownhelp=true;
                         }
@@ -1515,7 +1515,7 @@ function print_section($course, $section, $mods, $modnamesused, $absolute=false,
                     } else {
                         // In auto mode, or when editing, the icon is just an image
                         echo "<span class='autocompletion'>";
-                        if(!$shownhelp) {
+                        if(!$shownhelp && !$isediting) {
                             helpbutton('completionicons',get_string('completionicons','completion'),'completion');
                             $shownhelp=true;
                         }