Skip to content
This repository has been archived by the owner on Apr 8, 2022. It is now read-only.

Commit

Permalink
MDL-32773 Add a help icon for button 'Set main file' in filemanager
Browse files Browse the repository at this point in the history
  • Loading branch information
marinaglancy committed Sep 27, 2013
1 parent d45e65c commit 0fb7a8a
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 6 deletions.
3 changes: 2 additions & 1 deletion files/renderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,7 @@ private function fm_js_template_message() {
* @return string
*/
private function fm_js_template_fileselectlayout() {
global $OUTPUT;
$strloading = get_string('loading', 'repository');
$icon_progress = $this->pix_icon('i/loading_small', $strloading).'';
$rv = '
Expand All @@ -377,7 +378,7 @@ private function fm_js_template_fileselectlayout() {
<form>
<button class="{!}fp-file-download">'.get_string('download').'</button>
<button class="{!}fp-file-delete">'.get_string('delete').'</button>
<button class="{!}fp-file-setmain">'.get_string('setmainfile', 'repository').'</button>
<button class="{!}fp-file-setmain">'.get_string('setmainfile', 'repository').'</button><span class="fp-file-setmain-help">'.$OUTPUT->help_icon('setmainfile', 'repository').'</span>
<button class="{!}fp-file-zip">'.get_string('zip', 'editor').'</button>
<button class="{!}fp-file-unzip">'.get_string('unzip').'</button>
<div class="fp-hr"></div>
Expand Down
1 change: 1 addition & 0 deletions lang/en/repository.php
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,7 @@
$string['settings'] = 'Settings';
$string['setupdefaultplugins'] = 'Setting up default repository plugins';
$string['setmainfile'] = 'Set main file';
$string['setmainfile_help'] = 'If there are multiple files in the folder, the main file is the one that appears on the view page. Other files such as images or videos may be embedded in it. In filemanager the main file is indicated with a title in bold.';
$string['siteinstances'] = 'Repositories instances of the site';
$string['size'] = 'Size';
$string['submit'] = 'Submit';
Expand Down
6 changes: 4 additions & 2 deletions theme/base/style/filemanager.css
Original file line number Diff line number Diff line change
Expand Up @@ -377,8 +377,10 @@ a.ygtvspacer:hover {color: transparent;text-decoration: none;}
.filemanager.fp-select.fp-folder .fp-file-unzip,
.filemanager.fp-select.fp-file .fp-file-zip,
.filemanager.fp-select.fp-zip .fp-file-zip {display:none;}
.filemanager.fp-select .fp-file-setmain {display:none;}
.filemanager.fp-select.fp-cansetmain .fp-file-setmain {display:inline-block;}
.filemanager.fp-select .fp-file-setmain,
.filemanager.fp-select .fp-file-setmain-help {display:none;}
.filemanager.fp-select.fp-cansetmain .fp-file-setmain,
.filemanager.fp-select.fp-cansetmain .fp-file-setmain-help {display:inline-block;}
.filemanager .fp-mainfile .fp-filename {font-weight:bold;}
.filemanager.fp-select.fp-folder .fp-file-download {display:none;} /* to be implemented */
.fm-operation {font-weight: bold;}
Expand Down
6 changes: 4 additions & 2 deletions theme/bootstrapbase/less/moodle/filemanager.less
Original file line number Diff line number Diff line change
Expand Up @@ -1075,10 +1075,12 @@ a.ygtvspacer:hover {
.filemanager.fp-select.fp-zip .fp-file-zip {
display: none;
}
.filemanager.fp-select .fp-file-setmain {
.filemanager.fp-select .fp-file-setmain,
.filemanager.fp-select .fp-file-setmain-help {
display: none;
}
.filemanager.fp-select.fp-cansetmain .fp-file-setmain {
.filemanager.fp-select.fp-cansetmain .fp-file-setmain,
.filemanager.fp-select.fp-cansetmain .fp-file-setmain-help {
display: inline-block;
.ie7-inline-block();
}
Expand Down
2 changes: 1 addition & 1 deletion theme/bootstrapbase/style/moodle.css

Large diffs are not rendered by default.

0 comments on commit 0fb7a8a

Please sign in to comment.