[ Index ] |
PHP Cross Reference of moodle-2.8 |
[Summary view] [Print] [Text view]
1 <?php 2 3 // This file is part of Moodle - http://moodle.org/ 4 // 5 // Moodle is free software: you can redistribute it and/or modify 6 // it under the terms of the GNU General Public License as published by 7 // the Free Software Foundation, either version 3 of the License, or 8 // (at your option) any later version. 9 // 10 // Moodle is distributed in the hope that it will be useful, 11 // but WITHOUT ANY WARRANTY; without even the implied warranty of 12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 // GNU General Public License for more details. 14 // 15 // You should have received a copy of the GNU General Public License 16 // along with Moodle. If not, see <http://www.gnu.org/licenses/>. 17 18 /** 19 * Settings used by the lesson module, were moved from mod_edit 20 * 21 * @package mod_lesson 22 * @copyright 2009 Sam Hemelryk 23 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or late 24 **/ 25 26 defined('MOODLE_INTERNAL') || die; 27 28 if ($ADMIN->fulltree) { 29 require_once($CFG->dirroot.'/mod/lesson/locallib.php'); 30 31 /** Slideshow settings */ 32 $settings->add(new admin_setting_configtext('lesson_slideshowwidth', get_string('slideshowwidth', 'lesson'), 33 get_string('configslideshowwidth', 'lesson'), 640, PARAM_INT)); 34 35 $settings->add(new admin_setting_configtext('lesson_slideshowheight', get_string('slideshowheight', 'lesson'), 36 get_string('configslideshowheight', 'lesson'), 480, PARAM_INT)); 37 38 $settings->add(new admin_setting_configtext('lesson_slideshowbgcolor', get_string('slideshowbgcolor', 'lesson'), 39 get_string('configslideshowbgcolor', 'lesson'), '#FFFFFF', PARAM_TEXT)); 40 41 /** Media file popup settings */ 42 $settings->add(new admin_setting_configtext('lesson_mediawidth', get_string('mediawidth', 'lesson'), 43 get_string('configmediawidth', 'lesson'), 640, PARAM_INT)); 44 45 $settings->add(new admin_setting_configtext('lesson_mediaheight', get_string('mediaheight', 'lesson'), 46 get_string('configmediaheight', 'lesson'), 480, PARAM_INT)); 47 48 $settings->add(new admin_setting_configcheckbox('lesson_mediaclose', get_string('mediaclose', 'lesson'), 49 get_string('configmediaclose', 'lesson'), false, PARAM_TEXT)); 50 51 /** Misc lesson settings */ 52 $settings->add(new admin_setting_configtext('lesson_maxhighscores', get_string('maxhighscores', 'lesson'), 53 get_string('configmaxhighscores','lesson'), 10, PARAM_INT)); 54 55 /** Default lesson settings */ 56 $numbers = array(); 57 for ($i=20; $i>1; $i--) { 58 $numbers[$i] = $i; 59 } 60 $settings->add(new admin_setting_configselect('lesson_maxanswers', get_string('maximumnumberofanswersbranches','lesson'), 61 get_string('configmaxanswers', 'lesson'), 4, $numbers)); 62 63 $defaultnextpages = array(); 64 $defaultnextpages[0] = get_string("normal", "lesson"); 65 $defaultnextpages[LESSON_UNSEENPAGE] = get_string("showanunseenpage", "lesson"); 66 $defaultnextpages[LESSON_UNANSWEREDPAGE] = get_string("showanunansweredpage", "lesson"); 67 $settings->add(new admin_setting_configselect('lesson_defaultnextpage', get_string('actionaftercorrectanswer','lesson'), 68 get_string('configactionaftercorrectanswer', 'lesson'), 0, $defaultnextpages)); 69 $settings->add(new admin_setting_configcheckbox('lesson/requiremodintro', 70 get_string('requiremodintro', 'admin'), get_string('configrequiremodintro', 'admin'), 1)); 71 }
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Fri Nov 28 20:29:05 2014 | Cross-referenced by PHPXref 0.7.1 |