mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-11-21 11:04:24 +00:00
JavaScript "strict mode" fixes
This commit is contained in:
parent
adaba7790b
commit
57fe6ed01d
2
ui/jquery.ui.position.js
vendored
2
ui/jquery.ui.position.js
vendored
@ -414,7 +414,7 @@ $.ui.position = {
|
|||||||
|
|
||||||
// fraction support test
|
// fraction support test
|
||||||
(function () {
|
(function () {
|
||||||
var testElement, testElementParent, testElementStyle, offsetLeft, i
|
var testElement, testElementParent, testElementStyle, offsetLeft, i,
|
||||||
body = document.getElementsByTagName( "body" )[ 0 ],
|
body = document.getElementsByTagName( "body" )[ 0 ],
|
||||||
div = document.createElement( "div" );
|
div = document.createElement( "div" );
|
||||||
|
|
||||||
|
6
ui/jquery.ui.tabs.js
vendored
6
ui/jquery.ui.tabs.js
vendored
@ -947,9 +947,7 @@ if ( $.uiBackCompat !== false ) {
|
|||||||
|
|
||||||
// cookie option
|
// cookie option
|
||||||
var listId = 0;
|
var listId = 0;
|
||||||
function getNextListId() {
|
|
||||||
return ++listId;
|
|
||||||
}
|
|
||||||
$.widget( "ui.tabs", $.ui.tabs, {
|
$.widget( "ui.tabs", $.ui.tabs, {
|
||||||
options: {
|
options: {
|
||||||
cookie: null // e.g. { expires: 7, path: '/', domain: 'jquery.com', secure: true }
|
cookie: null // e.g. { expires: 7, path: '/', domain: 'jquery.com', secure: true }
|
||||||
@ -968,7 +966,7 @@ if ( $.uiBackCompat !== false ) {
|
|||||||
},
|
},
|
||||||
_cookie: function( active ) {
|
_cookie: function( active ) {
|
||||||
var cookie = [ this.cookie ||
|
var cookie = [ this.cookie ||
|
||||||
( this.cookie = this.options.cookie.name || "ui-tabs-" + getNextListId() ) ];
|
( this.cookie = this.options.cookie.name || "ui-tabs-" + ++listId ) ];
|
||||||
if ( arguments.length ) {
|
if ( arguments.length ) {
|
||||||
cookie.push( active === false ? -1 : active );
|
cookie.push( active === false ? -1 : active );
|
||||||
cookie.push( this.options.cookie );
|
cookie.push( this.options.cookie );
|
||||||
|
2
ui/jquery.ui.widget.js
vendored
2
ui/jquery.ui.widget.js
vendored
@ -182,7 +182,7 @@ $.widget.bridge = function( name, object ) {
|
|||||||
if ( instance ) {
|
if ( instance ) {
|
||||||
instance.option( options || {} )._init();
|
instance.option( options || {} )._init();
|
||||||
} else {
|
} else {
|
||||||
object( options, this );
|
new object( options, this );
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user