Merge "Bypass login page if no user input is required."
[lhc/web/wiklou.git] / resources / src / mediawiki / mediawiki.confirmCloseWindow.js
index 8d1faa6..e3a8f7b 100644 (file)
@@ -1,9 +1,5 @@
-/* jshint devel: true */
 ( function ( mw, $ ) {
        /**
-        * @method confirmCloseWindow
-        * @member mw
-        *
         * Prevent the closing of a window with a confirm message (the onbeforeunload event seems to
         * work in most browsers.)
         *
@@ -25,6 +21,8 @@
         *         // do whatever you wanted to do
         *     }
         *
+        * @method confirmCloseWindow
+        * @member mw
         * @param {Object} [options]
         * @param {string} [options.namespace] Namespace for the event registration
         * @param {string} [options.message]
 
                /**
                 * Return the object with functions to release and manually trigger the confirm alert
+                *
                 * @ignore
                 */
                return {
                        /**
                         * Remove all event listeners and don't show an alert anymore, if the user wants to leave
                         * the page.
+                        *
                         * @ignore
                         */
                        release: function () {
@@ -92,8 +92,9 @@
                         * Trigger the module's function manually: Check, if options.test() returns true and show
                         * an alert to the user if he/she want to leave this page. Returns false, if options.test() returns
                         * false or the user cancelled the alert window (~don't leave the page), true otherwise.
+                        *
                         * @ignore
-                        * @return boolean
+                        * @return {boolean}
                         */
                        trigger: function () {
                                // use confirm to show the message to the user (if options.text() is true)
                        }
                };
        };
-} )( mediaWiki, jQuery );
+}( mediaWiki, jQuery ) );