Home
Documentation
Downloads
Demo
Tracker
Development
Translation
Moodle.net
Search
projects
/
moodle.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e4aff89
)
MDL-59384 core_modal: trigger bodyRendered event
author
Simey Lameze
<simey@moodle.com>
Wed, 12 Jul 2017 11:57:22 +0000
(19:57 +0800)
committer
Simey Lameze
<simey@moodle.com>
Wed, 12 Jul 2017 11:57:22 +0000
(19:57 +0800)
Part of MDL-59333.
lib/amd/build/modal.min.js
patch
|
blob
|
blame
|
history
lib/amd/build/modal_events.min.js
patch
|
blob
|
blame
|
history
lib/amd/src/modal.js
patch
|
blob
|
blame
|
history
lib/amd/src/modal_events.js
patch
|
blob
|
blame
|
history
diff --git
a/lib/amd/build/modal.min.js
b/lib/amd/build/modal.min.js
index
1b1e4fd
..
a469dda
100644
(file)
Binary files a/lib/amd/build/modal.min.js and b/lib/amd/build/modal.min.js differ
diff --git
a/lib/amd/build/modal_events.min.js
b/lib/amd/build/modal_events.min.js
index
e7980b7
..
9b2eaab
100644
(file)
Binary files a/lib/amd/build/modal_events.min.js and b/lib/amd/build/modal_events.min.js differ
diff --git
a/lib/amd/src/modal.js
b/lib/amd/src/modal.js
index
36245c1
..
6cca43b
100644
(file)
--- a/
lib/amd/src/modal.js
+++ b/
lib/amd/src/modal.js
@@
-240,6
+240,7
@@
define(['jquery', 'core/templates', 'core/notification', 'core/key_codes',
// Just set the value if it's a string.
body.html(value);
Event.notifyFilterContentUpdated(body);
// Just set the value if it's a string.
body.html(value);
Event.notifyFilterContentUpdated(body);
+ this.getRoot().trigger(ModalEvents.bodyRendered, this);
} else {
// Otherwise we assume it's a promise to be resolved with
// html and javascript.
} else {
// Otherwise we assume it's a promise to be resolved with
// html and javascript.
@@
-259,6
+260,7
@@
define(['jquery', 'core/templates', 'core/notification', 'core/key_codes',
}
}
Event.notifyFilterContentUpdated(body);
}
}
Event.notifyFilterContentUpdated(body);
+ this.getRoot().trigger(ModalEvents.bodyRendered, this);
}.bind(this));
}.bind(this));
}
}.bind(this));
}.bind(this));
}
diff --git
a/lib/amd/src/modal_events.js
b/lib/amd/src/modal_events.js
index
1a1d9d5
..
bbd3979
100644
(file)
--- a/
lib/amd/src/modal_events.js
+++ b/
lib/amd/src/modal_events.js
@@
-28,6
+28,7
@@
define([], function() {
shown: 'modal:shown',
hidden: 'modal:hidden',
destroyed: 'modal:destroyed',
shown: 'modal:shown',
hidden: 'modal:hidden',
destroyed: 'modal:destroyed',
+ bodyRendered: 'modal:bodyRendered',
// ModalSaveCancel events.
save: 'modal-save-cancel:save',
cancel: 'modal-save-cancel:cancel',
// ModalSaveCancel events.
save: 'modal-save-cancel:save',
cancel: 'modal-save-cancel:cancel',