MDL-34741 use 2in3 in mod_wiki

This commit is contained in:
Petr Škoda
2012-08-11 20:40:05 +02:00
parent 080d05752e
commit 5f573e8efc
2 changed files with 4 additions and 3 deletions
+4 -2
View File
@@ -47,7 +47,9 @@ M.mod_wiki.renew_lock = function(Y, args) {
args['section'] = wiki.section;
}
var callback = {};
YAHOO.util.Connect.asyncRequest('GET', 'lock.php?' + build_querystring(args), callback);
Y.use('yui2-connection', function(Y) {
Y.YUI2.util.Connect.asyncRequest('GET', 'lock.php?' + build_querystring(args), callback);
});
}
setInterval(renewLock, wiki.renew_lock_timeout * 1000);
}
@@ -115,7 +117,7 @@ M.mod_wiki.deleteversion = function(Y, args) {
M.mod_wiki.init_tree = function(Y, expand_all, htmlid) {
Y.use('yui2-treeview', function(Y) {
var tree = new YAHOO.widget.TreeView(htmlid);
var tree = new Y.YUI2.widget.TreeView(htmlid);
tree.subscribe("clickEvent", function(node, event) {
// we want normal clicking which redirects to url
-1
View File
@@ -388,7 +388,6 @@ class page_wiki_edit extends page_wiki {
parent::__construct($wiki, $subwiki, $cm);
self::$attachmentoptions = array('subdirs' => false, 'maxfiles' => - 1, 'maxbytes' => $CFG->maxbytes, 'accepted_types' => '*');
$PAGE->requires->js_init_call('M.mod_wiki.renew_lock', null, true);
$PAGE->requires->yui2_lib('connection');
}
protected function print_pagetitle() {