Skip to content

Commit

Permalink
MDL-73914 course: move both options to more menu
Browse files Browse the repository at this point in the history
This commit moves the 'Download course content' and 'Unenrol me from course'
options to more menu.
  • Loading branch information
lameze committed Mar 22, 2022
1 parent b74b470 commit 37bf03b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/enrollib.php
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ function enrol_add_course_navigation(navigation_node $coursenode, $course) {
if ($unenrollink = $plugin->get_unenrolself_link($instance)) {
$shortname = format_string($course->shortname, true, array('context' => $coursecontext));
$coursenode->add(get_string('unenrolme', 'core_enrol', $shortname), $unenrollink, navigation_node::TYPE_SETTING, null, 'unenrolself', new pix_icon('i/user', ''));
$coursenode->get('unenrolself')->set_force_into_more_menu();
$coursenode->get('unenrolself')->set_force_into_more_menu(true);
break;
//TODO. deal with multiple unenrol links - not likely case, but still...
}
Expand Down
2 changes: 1 addition & 1 deletion lib/navigationlib.php
Original file line number Diff line number Diff line change
Expand Up @@ -4743,7 +4743,7 @@ protected function load_course_settings($forceopen = false) {

$coursenode->add($linkattr->displaystring, $actionlink, self::TYPE_SETTING, null, 'download',
new pix_icon('t/download', ''));
$coursenode->get('download')->set_force_into_more_menu();
$coursenode->get('download')->set_force_into_more_menu(true);
}

// Return we are done
Expand Down

0 comments on commit 37bf03b

Please sign in to comment.