mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
Merge branch 'MDL-42752-master' of git://github.com/phalacee/moodle
This commit is contained in:
commit
c5afe577c9
2 changed files with 10 additions and 6 deletions
|
@ -602,13 +602,13 @@ class core_files_renderer extends plugin_renderer_base {
|
||||||
<div class="fp-tb-message"></div>
|
<div class="fp-tb-message"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="fp-viewbar">
|
<div class="fp-viewbar">
|
||||||
<a title="'. get_string('displayicons', 'repository') .'" class="fp-vb-icons" href="#">
|
<a role="button" title="'. get_string('displayicons', 'repository') .'" class="fp-vb-icons" href="#">
|
||||||
<img alt="" src="'. $this->pix_url('fp/view_icon_active', 'theme') .'" />
|
<img alt="" src="'. $this->pix_url('fp/view_icon_active', 'theme') .'" />
|
||||||
</a>
|
</a>
|
||||||
<a title="'. get_string('displaydetails', 'repository') .'" class="fp-vb-details" href="#">
|
<a role="button" title="'. get_string('displaydetails', 'repository') .'" class="fp-vb-details" href="#">
|
||||||
<img alt="" src="'. $this->pix_url('fp/view_list_active', 'theme') .'" />
|
<img alt="" src="'. $this->pix_url('fp/view_list_active', 'theme') .'" />
|
||||||
</a>
|
</a>
|
||||||
<a title="'. get_string('displaytree', 'repository') .'" class="fp-vb-tree" href="#">
|
<a role="button" title="'. get_string('displaytree', 'repository') .'" class="fp-vb-tree" href="#">
|
||||||
<img alt="" src="'. $this->pix_url('fp/view_tree_active', 'theme') .'" />
|
<img alt="" src="'. $this->pix_url('fp/view_tree_active', 'theme') .'" />
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1266,12 +1266,16 @@ M.core_filepicker.init = function(Y, options) {
|
||||||
var viewbar = this.fpnode.one('.fp-viewbar')
|
var viewbar = this.fpnode.one('.fp-viewbar')
|
||||||
if (viewbar) {
|
if (viewbar) {
|
||||||
if (mode) {
|
if (mode) {
|
||||||
viewbar.addClass('enabled').removeClass('disabled')
|
viewbar.addClass('enabled').removeClass('disabled');
|
||||||
|
this.fpnode.all('.fp-vb-icons,.fp-vb-tree,.fp-vb-details').setAttribute("aria-disabled", "false");
|
||||||
|
this.fpnode.all('.fp-vb-icons,.fp-vb-tree,.fp-vb-details').setAttribute("tabindex", "");
|
||||||
} else {
|
} else {
|
||||||
viewbar.removeClass('enabled').addClass('disabled')
|
viewbar.removeClass('enabled').addClass('disabled');
|
||||||
|
this.fpnode.all('.fp-vb-icons,.fp-vb-tree,.fp-vb-details').setAttribute("aria-disabled", "true");
|
||||||
|
this.fpnode.all('.fp-vb-icons,.fp-vb-tree,.fp-vb-details').setAttribute("tabindex", "-1");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.fpnode.all('.fp-vb-icons,.fp-vb-tree,.fp-vb-details').removeClass('checked')
|
this.fpnode.all('.fp-vb-icons,.fp-vb-tree,.fp-vb-details').removeClass('checked');
|
||||||
var modes = {1:'icons', 2:'tree', 3:'details'};
|
var modes = {1:'icons', 2:'tree', 3:'details'};
|
||||||
this.fpnode.all('.fp-vb-'+modes[this.viewmode]).addClass('checked');
|
this.fpnode.all('.fp-vb-'+modes[this.viewmode]).addClass('checked');
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue