|
@@ -1065,7 +1065,9 @@ M.core_filepicker.init = function(Y, options) { |
|
|
}, false);
|
|
|
},
|
|
|
select_file: function(args) {
|
|
|
+ Y.one('#fp-file_label_'+this.options.client_id).setContent(Y.Escape.html(M.str.moodle.edit+' '+args.title));
|
|
|
this.selectui.show();
|
|
|
+ Y.one('#'+this.selectnode.get('id')).focus();
|
|
|
var client_id = this.options.client_id;
|
|
|
var selectnode = this.selectnode;
|
|
|
var return_types = this.options.repositories[this.active_repo.id].return_types;
|
|
@@ -1306,8 +1308,13 @@ M.core_filepicker.init = function(Y, options) { |
|
|
}
|
|
|
// create panel for selecting a file (initially hidden)
|
|
|
this.selectnode = Y.Node.createWithFilesSkin(M.core_filepicker.templates.selectlayout).
|
|
|
- set('id', 'filepicker-select-'+client_id);
|
|
|
+ set('id', 'filepicker-select-'+client_id).
|
|
|
+ set('aria-live', 'assertive').
|
|
|
+ set('role', 'dialog');
|
|
|
+
|
|
|
+ var fplabel = 'fp-file_label_'+ client_id;
|
|
|
this.selectui = new Y.Panel({
|
|
|
+ headerContent: '<span id="' + fplabel +'">'+M.str.moodle.edit+'</span>',
|
|
|
srcNode : this.selectnode,
|
|
|
zIndex : 7600,
|
|
|
centered : true,
|
|
@@ -1317,6 +1324,7 @@ M.core_filepicker.init = function(Y, options) { |
|
|
});
|
|
|
// allow to move the panel dragging it by it's header:
|
|
|
this.selectui.plug(Y.Plugin.Drag,{handles:['#filepicker-select-'+client_id+' .yui3-widget-hd']});
|
|
|
+ Y.one('#'+this.selectnode.get('id')).setAttribute('aria-labelledby', fplabel);
|
|
|
this.selectui.hide();
|
|
|
// event handler for lazy loading of thumbnails and next page
|
|
|
this.fpnode.one('.fp-content').on(['scroll','resize'], this.content_scrolled, this);
|
|
|
0 comments on commit
6ae1963