Making WordPress.org

Changeset 6895


Ignore:
Timestamp:
03/21/2018 04:01:44 AM (7 years ago)
Author:
dd32
Message:

Trac: Stub out some compat-functions to wp-trac.js until the CDN trac.js is available.
This avoids the JS Errors, but some functionalities may not work.

See #3526.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/style/trac/wp-trac.js

    r6894 r6895  
    14051405                init: init
    14061406            };
    1407         }())
     1407        }()),
     1408
     1409        patchTracFor122Changes: function() {
     1410            console.log( "wp-trac: Applying compat patches for Trac 1.2.2" );
     1411            // From Trac 1.2.2 threaded_comments.js:
     1412            window.applyCommentsOrder = window.applyCommentsOrder || function() {}
     1413
     1414            // From Trac 1.2.2 trac.js:
     1415            $.loadScript                = $.loadScript                || function() {}
     1416            $.fn.exclusiveOnClick       = $.fn.exclusiveOnClick       || function() {}
     1417            $.fn.addSelectAllCheckboxes = $.fn.addSelectAllCheckboxes || function() {}
     1418            $.fn.disableOnSubmit        = $.fn.disableOnSubmit        || function() {}
     1419            $.fn.disableSubmit          = $.fn.disableSubmit          || function() {}
     1420        }
    14081421
    14091422    };
     
    14111424    $(document).ready( wpTrac.init );
    14121425
     1426    // Perform this as soon as this file loads.
     1427    wpTrac.patchTracFor122Changes();
     1428
    14131429})(jQuery);
Note: See TracChangeset for help on using the changeset viewer.