drachels / moodle-mod_mootyper

4 stars 18 forks source link

make default layout by set by name of the layout instead of id of the layout #110

Open andreasschenkel opened 1 year ago

andreasschenkel commented 1 year ago

It is possible to set the default defaultlayout for the keybord with a setting in the local/default.php $defaults['mod_mootyper']['defaultlayout'] = 21; So during installation this layout is set as default but it is still possible to choose a different default layout in the settings of the plugin. In some cases this number of the layout might be different an the layout should better be selected by name of the layout. A following pull request implements this feature. In the language-file the name is set by the filename but without the filetype. $string['default_defaultlayout_filenamewithoutfiletype'] = 'English(UKV5)'; Thus during installation this layout is set as the defaultlayout indipendent of the number the layout is stored in the database.