MDL-17310 scorm: Install asks for scorm &auth questions on install rather than just...
[moodle.git] / mod / scorm / settings.php
CommitLineData
220a90c5 1<?php //$Id$
30fc6e2d 2require_once('../mod/scorm/locallib.php');
3$yesno = array(0 => get_string('no'),
4 1 => get_string('yes'));
5
76d56ed5 6$settings->add(new admin_setting_configselect('scorm/grademethod', get_string('grademethod', 'scorm'),get_string('grademethoddesc', 'scorm'), GRADESCOES, scorm_get_grade_method_array()));
220a90c5 7
30fc6e2d 8for ($i=0; $i<=100; $i++) {
9 $grades[$i] = "$i";
10}
76d56ed5 11$settings->add(new admin_setting_configselect('scorm/maxgrade', get_string('maximumgrade'),get_string('maximumgradedesc','scorm'), 100, $grades));
30fc6e2d 12
13
14$settings->add(new admin_setting_configtext('scorm/maxattempts', get_string('maximumattempts', 'scorm'),
76d56ed5 15 '', 6, PARAM_INT));
30fc6e2d 16
17
76d56ed5 18$settings->add(new admin_setting_configselect('scorm/displayattemptstatus', get_string('displayattemptstatus', 'scorm'),get_string('displayattemptstatusdesc', 'scorm'),0,$yesno));
30fc6e2d 19
76d56ed5 20$settings->add(new admin_setting_configselect('scorm/displaycoursestructure', get_string('displaycoursestructure', 'scorm'),get_string('displaycoursestructuredesc', 'scorm'),0,$yesno));
30fc6e2d 21
76d56ed5 22$settings->add(new admin_setting_configselect('scorm/forcecompleted', get_string('forcecompleted', 'scorm'),get_string('forcecompleteddesc', 'scorm'),0,$yesno));
30fc6e2d 23
76d56ed5 24$settings->add(new admin_setting_configselect('scorm/forcenewattempt', get_string('forcenewattempt', 'scorm'),get_string('forcenewattemptdesc', 'scorm'),0,$yesno));
30fc6e2d 25
76d56ed5 26$settings->add(new admin_setting_configselect('scorm/lastattemptlock', get_string('lastattemptlock', 'scorm'),get_string('lastattemptlockdesc', 'scorm'),0,$yesno));
30fc6e2d 27
76d56ed5 28$settings->add(new admin_setting_configselect('scorm/whatgrade', get_string('whatgrade', 'scorm'), get_string('whatgradedesc', 'scorm'), HIGHESTATTEMPT, scorm_get_what_grade_array()));
30fc6e2d 29
30$settings->add(new admin_setting_configtext('scorm/framewidth', get_string('width', 'scorm'),
76d56ed5 31 get_string('framewidth', 'scorm'), 100, PARAM_INT));
220a90c5 32
30fc6e2d 33$settings->add(new admin_setting_configtext('scorm/frameheight', get_string('height', 'scorm'),
76d56ed5 34 get_string('frameheight', 'scorm'), 500, PARAM_INT));
220a90c5 35
30fc6e2d 36
37
76d56ed5 38$settings->add(new admin_setting_configselect('scorm/popup', get_string('display','scorm'), get_string('displaydesc','scorm'), 0, scorm_get_popup_display_array()));
30fc6e2d 39
40foreach(scorm_get_popup_options_array() as $key => $value){
41 $settings->add(new admin_setting_configcheckbox('scorm/'.$key, get_string($key, 'scorm'),'',$value));
42}
43
76d56ed5 44$settings->add(new admin_setting_configselect('scorm/skipview', get_string('skipview', 'scorm'), get_string('skipviewdesc', 'scorm'), 0, scorm_get_skip_view_array()));
30fc6e2d 45
76d56ed5 46$settings->add(new admin_setting_configselect('scorm/hidebrowse', get_string('hidebrowse', 'scorm'), get_string('hidebrowsedesc', 'scorm'), 0, $yesno));
30fc6e2d 47
76d56ed5 48$settings->add(new admin_setting_configselect('scorm/hidetoc', get_string('hidetoc', 'scorm'), get_string('hidetocdesc', 'scorm'), 0, scorm_get_hidetoc_array()));
30fc6e2d 49
76d56ed5 50$settings->add(new admin_setting_configselect('scorm/hidenav', get_string('hidenav', 'scorm'), get_string('hidenavdesc', 'scorm'), 0, $yesno));
30fc6e2d 51
76d56ed5 52$settings->add(new admin_setting_configselect('scorm/auto', get_string('autocontinue', 'scorm'), get_string('autocontinuedesc', 'scorm'), 0, $yesno));
30fc6e2d 53
76d56ed5 54$settings->add(new admin_setting_configselect('scorm/updatefreq', get_string('updatefreq', 'scorm'), get_string('updatefreqdesc', 'scorm'), 0, scorm_get_updatefreq_array()));
9528568b 55
30fc6e2d 56$settings->add(new admin_setting_configtext('scorm/updatetime', get_string('updatetime', 'scorm'),
76d56ed5 57 '', 2, PARAM_INT));
9528568b 58
30fc6e2d 59$settings->add(new admin_setting_configcheckbox('scorm/allowtypeexternal', get_string('allowtypeexternal', 'scorm'),
9528568b 60 '', 0));
61
30fc6e2d 62$settings->add(new admin_setting_configcheckbox('scorm/allowtypelocalsync', get_string('allowtypelocalsync', 'scorm'),
9528568b 63 '', 0));
64
30fc6e2d 65$settings->add(new admin_setting_configcheckbox('scorm/allowtypeimsrepository', get_string('allowtypeimsrepository', 'scorm'),
9528568b 66 '', 0));
67
30fc6e2d 68$settings->add(new admin_setting_configcheckbox('scorm/allowapidebug', get_string('allowapidebug', 'scorm'),
1881df27 69 '', 0));
9528568b 70
30fc6e2d 71$settings->add(new admin_setting_configtext('scorm/apidebugmask', get_string('apidebugmask', 'scorm'),
1881df27 72 '', '.*'));