MDL-47494 ddimageortext: Fix editing form javascript.
authorTim Hunt <T.J.Hunt@open.ac.uk>
Thu, 21 May 2015 14:59:03 +0000 (15:59 +0100)
committerTim Hunt <T.J.Hunt@open.ac.uk>
Thu, 21 May 2015 14:59:03 +0000 (15:59 +0100)
question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form-debug.js
question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form-min.js
question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form.js
question/type/ddimageortext/yui/src/form/js/form.js

index e872225..21affd0 100644 (file)
Binary files a/question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form-debug.js and b/question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form-debug.js differ
index c5fdf05..198e509 100644 (file)
Binary files a/question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form-min.js and b/question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form-min.js differ
index e872225..21affd0 100644 (file)
Binary files a/question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form.js and b/question/type/ddimageortext/yui/build/moodle-qtype_ddimageortext-form/moodle-qtype_ddimageortext-form.js differ
index a786dca..be13385 100644 (file)
@@ -58,10 +58,11 @@ Y.extend(DDIMAGEORTEXT_FORM, M.qtype_ddimageortext.dd_base_class, {
                                     .on('load', this.constrain_image_size, this, 'dragimage');
             this.doc.bg_img().after('load', this.poll_for_image_load, this,
                                                     true, 0, this.after_all_images_loaded);
-            this.doc.drag_item_homes() .after('load', this.poll_for_image_load, this,
+            this.doc.drag_item_homes().after('load', this.poll_for_image_load, this,
                                                     true, 0, this.after_all_images_loaded);
         } else {
             this.setup_form_events();
+            M.util.js_complete(this.pendingid);
         }
         this.update_visibility_of_file_pickers();
     },
@@ -230,6 +231,7 @@ Y.extend(DDIMAGEORTEXT_FORM, M.qtype_ddimageortext.dd_base_class, {
             var draginstanceno = drag.getData('draginstanceno');
             this.reposition_drag_for_form(draginstanceno);
         }, this);
+        M.util.js_complete(this.pendingid);
     },
 
     reposition_drag_for_form : function (draginstanceno) {