Skip to content

Commit

Permalink
MDL-51679 course: Update groupmode CSS class
Browse files Browse the repository at this point in the history
Changing groupmode of an activity via AJAX did not change the button's CSS class accordingly.
  • Loading branch information
Dagefoerde committed Oct 14, 2015
1 parent 35d3e8b commit ee20bdc
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -688,6 +688,8 @@ Y.extend(RESOURCETOOLBOX, TOOLBOX, {
newtitlestr = M.util.get_string('clicktochangeinbrackets', 'moodle', M.util.get_string(newtitle, 'moodle'));

// Change the UI
var oldAction = button.getData('action');
button.replaceClass('editing_' + oldAction, 'editing_' + newtitle);
buttonimg.setAttrs({
'src': iconsrc
});
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -688,6 +688,8 @@ Y.extend(RESOURCETOOLBOX, TOOLBOX, {
newtitlestr = M.util.get_string('clicktochangeinbrackets', 'moodle', M.util.get_string(newtitle, 'moodle'));

// Change the UI
var oldAction = button.getData('action');
button.replaceClass('editing_' + oldAction, 'editing_' + newtitle);
buttonimg.setAttrs({
'src': iconsrc
});
Expand Down
2 changes: 2 additions & 0 deletions course/yui/src/toolboxes/js/resource.js
Original file line number Diff line number Diff line change
Expand Up @@ -484,6 +484,8 @@ Y.extend(RESOURCETOOLBOX, TOOLBOX, {
newtitlestr = M.util.get_string('clicktochangeinbrackets', 'moodle', M.util.get_string(newtitle, 'moodle'));

// Change the UI
var oldAction = button.getData('action');
button.replaceClass('editing_' + oldAction, 'editing_' + newtitle);
buttonimg.setAttrs({
'src': iconsrc
});
Expand Down

0 comments on commit ee20bdc

Please sign in to comment.