MDL-45364 atto_rtl: Fix JS lint
authorAndrew Nicols <andrew@nicols.co.uk>
Tue, 24 Nov 2015 12:14:12 +0000 (20:14 +0800)
committerDan Poltawski <dan@moodle.com>
Thu, 26 Nov 2015 19:09:03 +0000 (19:09 +0000)
lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button-debug.js
lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button-min.js
lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button.js
lib/editor/atto/plugins/rtl/yui/src/button/js/button.js

index ba14c13..21c5cda 100644 (file)
Binary files a/lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button-debug.js and b/lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button-debug.js differ
index 51d0be4..21c5088 100644 (file)
Binary files a/lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button-min.js and b/lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button-min.js differ
index ba14c13..21c5cda 100644 (file)
Binary files a/lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button.js and b/lib/editor/atto/plugins/rtl/yui/build/moodle-atto_rtl-button/moodle-atto_rtl-button.js differ
index 2fb1543..88bf7c0 100644 (file)
@@ -63,7 +63,7 @@ Y.namespace('M.atto_rtl').Button = Y.Base.create('button', Y.M.editor_atto.Edito
      */
     _toggleRTL: function(e, direction) {
         var host = this.get('host'),
-            sourceSelection = rangy.saveSelection(),
+            sourceSelection = window.rangy.saveSelection(),
             selection = host.getSelection(),
             newDirection = {
                 rtl: 'ltr',
@@ -82,7 +82,7 @@ Y.namespace('M.atto_rtl').Button = Y.Base.create('button', Y.M.editor_atto.Edito
             }
 
             // Change selection from the containing paragraph to the original one.
-            rangy.restoreSelection(sourceSelection);
+            window.rangy.restoreSelection(sourceSelection);
             // Mark the text as having been updated.
             this.markUpdated();
         }