Jquery-Ui-1 8 24
Jquery-Ui-1 8 24
*
* Microsoft grants you the right to use these script files for the sole
* purpose of either: (i) interacting through your browser with the Microsoft
* website or online service, subject to the applicable licensing or use
* terms; or (ii) using the files as included with a Microsoft product subject
* to that product's license terms. Microsoft reserves all other rights to the
* files not expressly granted by Microsoft, whether by implication, estoppel
* or otherwise. Insofar as a script file is dual licensed under GPL,
* Microsoft neither took the code under GPL nor distributes it thereunder but
* under the terms set out in this paragraph. All notices and licenses
* below are for informational purposes only.
*
* jQuery UI; Copyright (c) 2012 Paul Bakaus; [Link]
*
* Includes jQuery Easing v1.3; Copyright 2008 George McGinley Smith;
[Link]
*
* NUGET: END LICENSE TEXT */
/*! jQuery UI - v1.8.24 - 2012-09-28
* [Link]
* Includes: [Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link], [Link], [Link],
[Link]
* Copyright (c) 2012 [Link]; Licensed MIT */
(function( $, undefined ) {
$.extend( $.ui, {
version: "1.8.24",
keyCode: {
ALT: 18,
BACKSPACE: 8,
CAPS_LOCK: 20,
COMMA: 188,
COMMAND: 91,
COMMAND_LEFT: 91, // COMMAND
COMMAND_RIGHT: 93,
CONTROL: 17,
DELETE: 46,
DOWN: 40,
END: 35,
ENTER: 13,
ESCAPE: 27,
HOME: 36,
INSERT: 45,
LEFT: 37,
MENU: 93, // COMMAND_RIGHT
NUMPAD_ADD: 107,
NUMPAD_DECIMAL: 110,
NUMPAD_DIVIDE: 111,
NUMPAD_ENTER: 108,
NUMPAD_MULTIPLY: 106,
NUMPAD_SUBTRACT: 109,
PAGE_DOWN: 34,
PAGE_UP: 33,
PERIOD: 190,
RIGHT: 39,
SHIFT: 16,
SPACE: 32,
TAB: 9,
UP: 38,
WINDOWS: 91 // COMMAND
}
});
// plugins
$.[Link]({
propAttr: $.[Link] || $.[Link],
_focus: $.[Link],
focus: function( delay, fn ) {
return typeof delay === "number" ?
[Link](function() {
var elem = this;
setTimeout(function() {
$( elem ).focus();
if ( fn ) {
[Link]( elem );
}
}, delay );
}) :
this._focus.apply( this, arguments );
},
scrollParent: function() {
var scrollParent;
if (($.[Link] && (/(static|
relative)/).test([Link]('position'))) || (/absolute/).test([Link]('position')))
{
scrollParent = [Link]().filter(function() {
return (/(relative|absolute|
fixed)/).test($.curCSS(this,'position',1)) && (/(auto|
scroll)/).test($.curCSS(this,'overflow',1)+$.curCSS(this,'overflow-y',1)+
$.curCSS(this,'overflow-x',1));
}).eq(0);
} else {
scrollParent = [Link]().filter(function() {
return (/(auto|scroll)/).test($.curCSS(this,'overflow',1)+
$.curCSS(this,'overflow-y',1)+$.curCSS(this,'overflow-x',1));
}).eq(0);
}
if ( [Link] ) {
var elem = $( this[ 0 ] ), position, value;
while ( [Link] && elem[ 0 ] !== document ) {
// Ignore z-index if position is set to a value where z-
index is ignored by the browser
// This makes behavior of this function consistent across
browsers
// WebKit always returns auto if the element is positioned
position = [Link]( "position" );
if ( position === "absolute" || position === "relative" ||
position === "fixed" ) {
// IE returns 0 when zIndex is not specified
// other browsers return a string
// we ignore the case of nested elements with an
explicit value of 0
// <div style="z-index: -10;"><div style="z-index:
0;"></div></div>
value = parseInt( [Link]( "zIndex" ), 10 );
if ( !isNaN( value ) && value !== 0 ) {
return value;
}
}
elem = [Link]();
}
}
return 0;
},
disableSelection: function() {
return [Link]( ( $.[Link] ? "selectstart" : "mousedown"
) +
".ui-disableSelection", function( event ) {
[Link]();
});
},
enableSelection: function() {
return [Link]( ".ui-disableSelection" );
}
});
return [Link](function() {
$( this ).css( type, reduce( this, size ) + "px" );
});
};
return [Link](function() {
$( this).css( type, reduce( this, size, true, margin ) +
"px" );
});
};
});
}
// selectors
function focusable( element, isTabIndexNotNaN ) {
var nodeName = [Link]();
if ( "area" === nodeName ) {
var map = [Link],
mapName = [Link],
img;
if ( ![Link] || !mapName || [Link]() !==
"map" ) {
return false;
}
img = $( "img[usemap=#" + mapName + "]" )[0];
return !!img && visible( img );
}
return ( /input|select|textarea|button|object/.test( nodeName )
? ![Link]
: "a" == nodeName
? [Link] || isTabIndexNotNaN
: isTabIndexNotNaN)
// the element and all of its ancestors must be visible
&& visible( element );
}
// support
$(function() {
var body = [Link],
div = [Link]( div = [Link]( "div" ) );
$.extend( [Link], {
minHeight: "100px",
height: "auto",
padding: 0,
borderWidth: 0
});
// jQuery <1.4.3 uses curCSS, in 1.4.3 - 1.7.2 curCSS = css, 1.8+ only has css
if ( !$.curCSS ) {
$.curCSS = $.css;
}
// deprecated
$.extend( $.ui, {
// $.[Link] is deprecated. Use the proxy pattern instead.
plugin: {
add: function( module, option, set ) {
var proto = $.ui[ module ].prototype;
for ( var i in set ) {
[Link][ i ] = [Link][ i ] || [];
[Link][ i ].push( [ option, set[ i ] ] );
}
},
call: function( instance, name, args ) {
var set = [Link][ name ];
if ( !set || ![Link][ 0 ].parentNode ) {
return;
}
//If overflow is hidden, the element might have extra content, but the
user wants to hide it
if ( $( el ).css( "overflow" ) === "hidden") {
return false;
}
// these are odd functions, fix the API or move into individual plugins
isOverAxis: function( x, reference, size ) {
//Determines when x coordinate is over "b" element axis
return ( x > reference ) && ( x < ( reference + size ) );
},
isOver: function( y, x, top, left, height, width ) {
//Determines when x, y coordinates is over "b" element
return $.[Link]( y, top, height ) && $.[Link]( x, left,
width );
}
});
})( jQuery );
(function( $, undefined ) {
// jQuery 1.4+
if ( $.cleanData ) {
var _cleanData = $.cleanData;
$.cleanData = function( elems ) {
for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) {
try {
$( elem ).triggerHandler( "remove" );
// [Link]
} catch( e ) {}
}
_cleanData( elems );
};
} else {
var _remove = $.[Link];
$.[Link] = function( selector, keepData ) {
return [Link](function() {
if ( !keepData ) {
if ( !selector || $.filter( selector, [ this ] ).length ) {
$( "*", this ).add( [ this ] ).each(function() {
try {
$( this ).triggerHandler( "remove" );
// [Link]
} catch( e ) {}
});
}
}
return _remove.call( $(this), selector, keepData );
});
};
}
if ( !prototype ) {
prototype = base;
base = $.Widget;
}
if ( isMethodCall ) {
[Link](function() {
var instance = $.data( this, name ),
methodValue = instance &&
$.isFunction( instance[options] ) ?
instance[ options ].apply( instance, args ) :
instance;
// TODO: add this back in 1.9 and use $.error() (see #5972)
// if ( !instance ) {
// throw "cannot call methods on " + name + " prior to
initialization; " +
// "attempted to call method '" + options + "'";
// }
// if ( !$.isFunction( instance[options] ) ) {
// throw "no such method '" + options + "' for " + name
+ " widget instance";
// }
// var methodValue = instance[ options ].apply( instance, args
);
if ( methodValue !== instance && methodValue !==
undefined ) {
returnValue = methodValue;
return false;
}
});
} else {
[Link](function() {
var instance = $.data( this, name );
if ( instance ) {
[Link]( options || {} )._init();
} else {
$.data( this, name, new object( options, this ) );
}
});
}
return returnValue;
};
};
$.[Link] = {
widgetName: "widget",
widgetEventPrefix: "",
options: {
disabled: false
},
_createWidget: function( options, element ) {
// $.[Link] stores the plugin instance, but we do it anyway
// so that it's stored even before the _create function runs
$.data( element, [Link], this );
[Link] = $( element );
[Link] = $.extend( true, {},
[Link],
this._getCreateOptions(),
options );
this._create();
this._trigger( "create" );
this._init();
},
_getCreateOptions: function() {
return $.metadata && $.[Link]( [Link][0] )[ [Link]
];
},
_create: function() {},
_init: function() {},
destroy: function() {
[Link]
.unbind( "." + [Link] )
.removeData( [Link] );
[Link]()
.unbind( "." + [Link] )
.removeAttr( "aria-disabled" )
.removeClass(
[Link] + "-disabled " +
"ui-state-disabled" );
},
widget: function() {
return [Link];
},
if ( [Link] === 0 ) {
// don't return a reference to the internal hash
return $.extend( {}, [Link] );
}
this._setOptions( options );
return this;
},
_setOptions: function( options ) {
var self = this;
$.each( options, function( key, value ) {
self._setOption( key, value );
});
return this;
},
_setOption: function( key, value ) {
[Link][ key ] = value;
return this;
},
enable: function() {
return this._setOption( "disabled", false );
},
disable: function() {
return this._setOption( "disabled", true );
},
})( jQuery );
(function( $, undefined ) {
$.widget("[Link]", {
options: {
cancel: ':input,option',
distance: 1,
delay: 0
},
_mouseInit: function() {
var self = this;
[Link]
.bind('mousedown.'+[Link], function(event) {
return self._mouseDown(event);
})
.bind('click.'+[Link], function(event) {
if (true === $.data([Link], [Link] +
'.preventClickEvent')) {
$.removeData([Link], [Link] +
'.preventClickEvent');
[Link]();
return false;
}
});
[Link] = false;
},
// TODO: make sure destroying one instance of mouse doesn't mess with
// other instances of mouse
_mouseDestroy: function() {
[Link]('.'+[Link]);
if ( this._mouseMoveDelegate ) {
$(document)
.unbind('mousemove.'+[Link],
this._mouseMoveDelegate)
.unbind('mouseup.'+[Link], this._mouseUpDelegate);
}
},
_mouseDown: function(event) {
// don't let more than one widget handle mouseStart
if( mouseHandled ) { return };
this._mouseDownEvent = event;
[Link] = ![Link];
if (![Link]) {
this._mouseDelayTimer = setTimeout(function() {
[Link] = true;
}, [Link]);
}
[Link]();
mouseHandled = true;
return true;
},
_mouseMove: function(event) {
// IE mouseup check - mouseup happened when mouse was out of window
if ($.[Link] && !([Link] >= 9) && ![Link]) {
return this._mouseUp(event);
}
if (this._mouseStarted) {
this._mouseDrag(event);
return [Link]();
}
if (this._mouseDistanceMet(event) && this._mouseDelayMet(event)) {
this._mouseStarted =
(this._mouseStart(this._mouseDownEvent, event) !== false);
(this._mouseStarted ? this._mouseDrag(event) :
this._mouseUp(event));
}
return !this._mouseStarted;
},
_mouseUp: function(event) {
$(document)
.unbind('mousemove.'+[Link], this._mouseMoveDelegate)
.unbind('mouseup.'+[Link], this._mouseUpDelegate);
if (this._mouseStarted) {
this._mouseStarted = false;
if ([Link] == this._mouseDownEvent.target) {
$.data([Link], [Link] + '.preventClickEvent',
true);
}
this._mouseStop(event);
}
return false;
},
_mouseDistanceMet: function(event) {
return ([Link](
[Link](this._mouseDownEvent.pageX - [Link]),
[Link](this._mouseDownEvent.pageY - [Link])
) >= [Link]
);
},
_mouseDelayMet: function(event) {
return [Link];
},
})(jQuery);
(function( $, undefined ) {
$.widget("[Link]", $.[Link], {
widgetEventPrefix: "drag",
options: {
addClasses: true,
appendTo: "parent",
axis: false,
connectToSortable: false,
containment: false,
cursor: "auto",
cursorAt: false,
grid: false,
handle: false,
helper: "original",
iframeFix: false,
opacity: false,
refreshPositions: false,
revert: false,
revertDuration: 500,
scope: "default",
scroll: true,
scrollSensitivity: 20,
scrollSpeed: 20,
snap: false,
snapMode: "both",
snapTolerance: 20,
stack: false,
zIndex: false
},
_create: function() {
this._mouseInit();
},
destroy: function() {
if() return;
[Link]
.removeData("draggable")
.unbind(".draggable")
.removeClass("ui-draggable"
+ " ui-draggable-dragging"
+ " ui-draggable-disabled");
this._mouseDestroy();
return this;
},
_mouseCapture: function(event) {
var o = [Link];
if ( [Link] ) {
$([Link] === true ? "iframe" : [Link]).each(function()
{
$('<div class="ui-draggable-iframeFix" style="background:
#fff;"></div>')
.css({
width: [Link]+"px", height:
[Link]+"px",
position: "absolute", opacity: "0.001", zIndex: 1000
})
.css($(this).offset())
.appendTo("body");
});
}
return true;
},
_mouseStart: function(event) {
var o = [Link];
[Link]("ui-draggable-dragging");
/*
* - Position generation -
* This block generates everything position related - it's the core of
draggables.
*/
//If the ddmanager is used for droppables, inform the manager that
dragging has started (see #5003)
if ( $.[Link] ) $.[Link](this, event);
return true;
},
return false;
},
_mouseStop: function(event) {
//If we are using droppables, inform the manager about the drop
var dropped = false;
if ($.[Link] && ![Link])
dropped = $.[Link](this, event);
return false;
},
_mouseUp: function(event) {
//Remove frame helpers
$("[Link]-draggable-iframeFix").each(function() {
[Link](this);
});
//If the ddmanager is used for droppables, inform the manager that
dragging has stopped (see #5003)
if( $.[Link] ) $.[Link](this, event);
cancel: function() {
if([Link](".ui-draggable-dragging")) {
this._mouseUp({});
} else {
this._clear();
}
return this;
},
_getHandle: function(event) {
return handle;
},
_createHelper: function(event) {
var o = [Link];
var helper = $.isFunction([Link]) ? $([Link]([Link][0],
[event])) : ([Link] == 'clone' ? [Link]().removeAttr('id') :
[Link]);
if(.length)
[Link](([Link] == 'parent' ?
[Link][0].parentNode : [Link]));
return helper;
},
_adjustOffsetFromHelper: function(obj) {
if (typeof obj == 'string') {
obj = [Link](' ');
}
if ($.isArray(obj)) {
obj = {left: +obj[0], top: +obj[1] || 0};
}
if ('left' in obj) {
[Link] = [Link] + [Link];
}
if ('right' in obj) {
[Link] = [Link] - [Link]
+ [Link];
}
if ('top' in obj) {
[Link] = [Link] + [Link];
}
if ('bottom' in obj) {
[Link] = [Link] -
[Link] + [Link];
}
},
_getParentOffset: function() {
return {
top: [Link] +
(parseInt([Link]("borderTopWidth"),10) || 0),
left: [Link] +
(parseInt([Link]("borderLeftWidth"),10) || 0)
};
},
_getRelativeOffset: function() {
if([Link] == "relative") {
var p = [Link]();
return {
top: [Link] - (parseInt([Link]("top"),10) || 0) +
[Link](),
left: [Link] - (parseInt([Link]("left"),10) || 0)
+ [Link]()
};
} else {
return { top: 0, left: 0 };
}
},
_cacheMargins: function() {
[Link] = {
left: (parseInt([Link]("marginLeft"),10) || 0),
top: (parseInt([Link]("marginTop"),10) || 0),
right: (parseInt([Link]("marginRight"),10) || 0),
bottom: (parseInt([Link]("marginBottom"),10) || 0)
};
},
_cacheHelperProportions: function() {
[Link] = {
width: [Link](),
height: [Link]()
};
},
_setContainment: function() {
var o = [Link];
if([Link] == 'parent') [Link] =
[Link][0].parentNode;
if([Link] == 'document' || [Link] == 'window')
[Link] = [
[Link] == 'document' ? 0 : $(window).scrollLeft() -
[Link] - [Link],
[Link] == 'document' ? 0 : $(window).scrollTop() -
[Link] - [Link],
([Link] == 'document' ? 0 : $(window).scrollLeft()) + $
([Link] == 'document' ? document : window).width() -
[Link] - [Link],
([Link] == 'document' ? 0 : $(window).scrollTop()) + ($
([Link] == 'document' ? document : window).height() ||
[Link]) - [Link] -
[Link]
];
if(!(/^(document|window|parent)$/).test([Link]) &&
[Link] != Array) {
var c = $([Link]);
var ce = c[0]; if(!ce) return;
var co = [Link]();
var over = ($(ce).css("overflow") != 'hidden');
[Link] = [
(parseInt($(ce).css("borderLeftWidth"),10) || 0) +
(parseInt($(ce).css("paddingLeft"),10) || 0),
(parseInt($(ce).css("borderTopWidth"),10) || 0) +
(parseInt($(ce).css("paddingTop"),10) || 0),
(over ? [Link]([Link],[Link]) :
[Link]) - (parseInt($(ce).css("borderLeftWidth"),10) || 0) - (parseInt($
(ce).css("paddingRight"),10) || 0) - [Link] -
[Link] - [Link],
(over ? [Link]([Link],[Link]) :
[Link]) - (parseInt($(ce).css("borderTopWidth"),10) || 0) - (parseInt($
(ce).css("paddingBottom"),10) || 0) - [Link] -
[Link] - [Link]
];
this.relative_container = c;
},
return {
top: (
[Link]
// The absolute mouse position
+ [Link] * mod
// Only for relative positioned nodes: Relative
offset from element to offset parent
+ [Link] * mod
// The offsetParent's offset without borders
(offset + border)
- ($.[Link] && $.[Link] < 526 &&
[Link] == 'fixed' ? 0 : ( [Link] == 'fixed' ? -
[Link]() : ( scrollIsRootNode ? 0 : [Link]() ) ) *
mod)
),
left: (
[Link]
// The absolute mouse position
+ [Link] * mod
// Only for relative positioned nodes: Relative
offset from element to offset parent
+ [Link] * mod
// The offsetParent's offset without borders
(offset + border)
- ($.[Link] && $.[Link] < 526 &&
[Link] == 'fixed' ? 0 : ( [Link] == 'fixed' ? -
[Link]() : scrollIsRootNode ? 0 : [Link]() ) *
mod)
)
};
},
_generatePosition: function(event) {
/*
* - Position constraining -
* Constrain the position to a mix of grid, containment.
*/
if([Link]) {
//Check for grid elements set to 0 to prevent divide by 0
error causing invalid argument errors in IE (see ticket #6950)
var top = [Link][1] ? [Link] +
[Link]((pageY - [Link]) / [Link][1]) * [Link][1] :
[Link];
pageY = containment ? (!(top - [Link] <
containment[1] || top - [Link] > containment[3]) ? top : (!(top -
[Link] < containment[1]) ? top - [Link][1] : top + [Link][1])) :
top;
return {
top: (
pageY
// The absolute mouse position
- [Link]
// Click offset (relative to the element)
- [Link]
// Only for relative positioned nodes: Relative
offset from element to offset parent
- [Link]
// The offsetParent's offset without borders
(offset + border)
+ ($.[Link] && $.[Link] < 526 &&
[Link] == 'fixed' ? 0 : ( [Link] == 'fixed' ? -
[Link]() : ( scrollIsRootNode ? 0 : [Link]() ) ))
),
left: (
pageX
// The absolute mouse position
- [Link]
// Click offset (relative to the element)
- [Link]
// Only for relative positioned nodes: Relative
offset from element to offset parent
- [Link]
// The offsetParent's offset without borders
(offset + border)
+ ($.[Link] && $.[Link] < 526 &&
[Link] == 'fixed' ? 0 : ( [Link] == 'fixed' ? -
[Link]() : scrollIsRootNode ? 0 : [Link]() ))
)
};
},
_clear: function() {
[Link]("ui-draggable-dragging");
if([Link][0] != [Link][0] && ![Link])
[Link]();
//if($.[Link]) $.[Link] = null;
[Link] = null;
[Link] = false;
},
plugins: {},
_uiHash: function(event) {
return {
helper: [Link],
position: [Link],
originalPosition: [Link],
offset: [Link]
};
}
});
$.extend($.[Link], {
version: "1.8.24"
});
$.[Link]("draggable", "connectToSortable", {
start: function(event, ui) {
},
stop: function(event, ui) {
//If we are still over the sortable, we fake the stop event of the
sortable, but also remove helper
var inst = $(this).data("draggable"),
uiSortable = $.extend({}, ui, { item: [Link] });
$.each([Link], function() {
if([Link]) {
[Link] = 0;
[Link] =
[Link]._helper;
} else {
[Link] = false; //Remove the
helper in the sortable instance
[Link]._trigger("deactivate", event, uiSortable);
}
});
},
drag: function(event, ui) {
$.each([Link], function(i) {
if([Link]._intersectsWith([Link])) {
[Link] = 1;
//Now we fake the start of dragging for the sortable
instance,
//by cloning the list group item, appending it to the
sortable and using it as [Link]
//We can then fire the start event of the sortable
with our passed browser event, and our own helper (so it doesn't create a new one)
[Link] = $
(self).clone().removeAttr('id').appendTo([Link]).data("sortable-
item", true);
[Link]._helper =
[Link]; //Store helper option to later restore it
[Link] = function() { return
[Link][0]; };
[Link] = [Link][0];
[Link]._mouseCapture(event, true);
[Link]._mouseStart(event, true, true);
inst._trigger("toSortable", event);
[Link] = [Link]; //draggable
revert needs that
//hack so receive/update callbacks work (mostly)
[Link] = [Link];
[Link] = inst;
} else {
[Link] = 0;
[Link] = true;
inst._trigger("fromSortable", event);
[Link] = false; //draggable revert needs that
}
};
});
}
});
$.[Link]("draggable", "cursor", {
start: function(event, ui) {
var t = $('body'), o = $(this).data('draggable').options;
if ([Link]("cursor")) o._cursor = [Link]("cursor");
[Link]("cursor", [Link]);
},
stop: function(event, ui) {
var o = $(this).data('draggable').options;
if (o._cursor) $('body').css("cursor", o._cursor);
}
});
$.[Link]("draggable", "opacity", {
start: function(event, ui) {
var t = $([Link]), o = $(this).data('draggable').options;
if([Link]("opacity")) o._opacity = [Link]("opacity");
[Link]('opacity', [Link]);
},
stop: function(event, ui) {
var o = $(this).data('draggable').options;
if(o._opacity) $([Link]).css('opacity', o._opacity);
}
});
$.[Link]("draggable", "scroll", {
start: function(event, ui) {
var i = $(this).data("draggable");
if([Link][0] != document && [Link][0].tagName !=
'HTML') [Link] = [Link]();
},
drag: function(event, ui) {
} else {
}
});
$.[Link]("draggable", "snap", {
start: function(event, ui) {
},
drag: function(event, ui) {
var l = [Link][i].left, r = l +
[Link][i].width,
t = [Link][i].top, b = t +
[Link][i].height;
if([Link] != 'inner') {
var ts = [Link](t - y2) <= d;
var bs = [Link](b - y1) <= d;
var ls = [Link](l - x2) <= d;
var rs = [Link](r - x1) <= d;
if(ts) [Link] =
inst._convertPositionTo("relative", { top: t - [Link], left:
0 }).top - [Link];
if(bs) [Link] =
inst._convertPositionTo("relative", { top: b, left: 0 }).top - [Link];
if(ls) [Link] =
inst._convertPositionTo("relative", { top: 0, left: l -
[Link] }).left - [Link];
if(rs) [Link] =
inst._convertPositionTo("relative", { top: 0, left: r }).left - [Link];
}
if([Link] != 'outer') {
var ts = [Link](t - y1) <= d;
var bs = [Link](b - y2) <= d;
var ls = [Link](l - x1) <= d;
var rs = [Link](r - x2) <= d;
if(ts) [Link] =
inst._convertPositionTo("relative", { top: t, left: 0 }).top - [Link];
if(bs) [Link] =
inst._convertPositionTo("relative", { top: b - [Link], left:
0 }).top - [Link];
if(ls) [Link] =
inst._convertPositionTo("relative", { top: 0, left: l }).left - [Link];
if(rs) [Link] =
inst._convertPositionTo("relative", { top: 0, left: r -
[Link] }).left - [Link];
}
};
}
});
$.[Link]("draggable", "stack", {
start: function(event, ui) {
var o = $(this).data("draggable").options;
}
});
$.[Link]("draggable", "zIndex", {
start: function(event, ui) {
var t = $([Link]), o = $(this).data("draggable").options;
if([Link]("zIndex")) o._zIndex = [Link]("zIndex");
[Link]('zIndex', [Link]);
},
stop: function(event, ui) {
var o = $(this).data("draggable").options;
if(o._zIndex) $([Link]).css('zIndex', o._zIndex);
}
});
})(jQuery);
(function( $, undefined ) {
$.widget("[Link]", {
widgetEventPrefix: "drop",
options: {
accept: '*',
activeClass: false,
addClasses: true,
greedy: false,
hoverClass: false,
scope: 'default',
tolerance: 'intersect'
},
_create: function() {
},
destroy: function() {
var drop = $.[Link][[Link]];
for ( var i = 0; i < [Link]; i++ )
if ( drop[i] == this )
[Link](i, 1);
[Link]
.removeClass("ui-droppable ui-droppable-disabled")
.removeData("droppable")
.unbind(".droppable");
return this;
},
if(key == 'accept') {
[Link] = $.isFunction(value) ? value : function(d) {
return [Link](value);
};
}
$.[Link]._setOption.apply(this, arguments);
},
_activate: function(event) {
var draggable = $.[Link];
if([Link])
[Link]([Link]);
(draggable && this._trigger('activate', event, [Link](draggable)));
},
_deactivate: function(event) {
var draggable = $.[Link];
if([Link])
[Link]([Link]);
(draggable && this._trigger('deactivate', event, [Link](draggable)));
},
_over: function(event) {
if ([Link]([Link][0],([Link] ||
[Link]))) {
if([Link])
[Link]([Link]);
this._trigger('over', event, [Link](draggable));
}
},
_out: function(event) {
if ([Link]([Link][0],([Link] ||
[Link]))) {
if([Link])
[Link]([Link]);
this._trigger('out', event, [Link](draggable));
}
},
_drop: function(event,custom) {
if([Link]([Link][0],([Link] ||
[Link]))) {
if([Link])
[Link]([Link]);
if([Link])
[Link]([Link]);
this._trigger('drop', event, [Link](draggable));
return [Link];
}
return false;
},
ui: function(c) {
return {
draggable: ([Link] || [Link]),
helper: [Link],
position: [Link],
offset: [Link]
};
}
});
$.extend($.[Link], {
version: "1.8.24"
});
switch (toleranceMode) {
case 'fit':
return (l <= x1 && x2 <= r
&& t <= y1 && y2 <= b);
break;
case 'intersect':
return (l < x1 + ([Link] / 2) // Right
Half
&& x2 - ([Link] / 2) < r // Left
Half
&& t < y1 + ([Link] / 2) //
Bottom Half
&& y2 - ([Link] / 2) < b ); //
Top Half
break;
case 'pointer':
var draggableLeft = (([Link] ||
[Link]).left + ([Link] ||
[Link]).left),
draggableTop = (([Link] ||
[Link]).top + ([Link] ||
[Link]).top),
isOver = $.[Link](draggableTop, draggableLeft, t, l,
[Link], [Link]);
return isOver;
break;
case 'touch':
return (
(y1 >= t && y1 <= b) || // Top edge touching
(y2 >= t && y2 <= b) || // Bottom edge touching
(y1 < t && y2 > b) // Surrounded vertically
) && (
(x1 >= l && x1 <= r) || // Left edge touching
(x2 >= l && x2 <= r) || // Right edge touching
(x1 < l && x2 > r) // Surrounded
horizontally
);
break;
default:
return false;
break;
}
};
/*
This manager tracks offsets of draggables and droppables
*/
$.[Link] = {
current: null,
droppables: { 'default': [] },
prepareOffsets: function(t, event) {
if(m[i].[Link] || (t && !
m[i].[Link](m[i].element[0],([Link] || [Link])))) continue; //No
disabled and non-accepted
for (var j=0; j < [Link]; j++) { if(list[j] ==
m[i].element[0]) { m[i].[Link] = 0; continue droppablesLoop; } };
//Filter out elements in the current dragged item
m[i].visible = m[i].[Link]("display") != "none"; if(!
m[i].visible) continue; //If
the element is not visible, continue
m[i].offset = m[i].[Link]();
m[i].proportions = { width: m[i].element[0].offsetWidth, height:
m[i].element[0].offsetHeight };
},
drop: function(draggable, event) {
if(![Link]) return;
if (![Link] && [Link] &&
$.[Link](draggable, this, [Link]))
dropped = this._drop.call(this, event) || dropped;
});
return dropped;
},
dragStart: function( draggable, event ) {
//Listen for scrolling so that if the dragging causes scrolling the
position of the droppables can be recalculated (see #5003)
//If you have a highly dynamic page, you might try this option. It
renders positions every time you move the mouse.
if([Link])
$.[Link](draggable, event);
var parentInstance;
if ([Link]) {
// find droppable parents with same scope
var scope = [Link];
var parent =
[Link](':data(droppable)').filter(function () {
return $.data(this, 'droppable').[Link] ===
scope;
});
if ([Link]) {
parentInstance = $.data(parent[0], 'droppable');
[Link] = (c == 'isover' ? 1 : 0);
}
}
},
dragStop: function( draggable, event ) {
})(jQuery);
(function( $, undefined ) {
$.widget("[Link]", $.[Link], {
widgetEventPrefix: "resize",
options: {
alsoResize: false,
animate: false,
animateDuration: "slow",
animateEasing: "swing",
aspectRatio: false,
autoHide: false,
containment: false,
ghost: false,
grid: false,
handles: "e,s,se",
helper: false,
maxHeight: null,
maxWidth: null,
minHeight: 10,
minWidth: 10,
zIndex: 1000
},
_create: function() {
$.extend(this, {
_aspectRatio: !!([Link]),
aspectRatio: [Link],
originalElement: [Link],
_proportionallyResizeElements: [],
_helper: [Link] || [Link] || [Link] ? [Link] || 'ui-
resizable-helper' : null
});
//Create a wrapper element and set the wrapper to the new current
internal element
[Link](
$('<div class="ui-wrapper" style="overflow:
hidden;"></div>').css({
position: [Link]('position'),
width: [Link](),
height: [Link](),
top: [Link]('top'),
left: [Link]('left')
})
);
[Link] = true;
this._proportionallyResizeElements.push([Link]({ position:
'static', zoom: 1, display: 'block' }));
this._renderAxis = function(target) {
for(var i in [Link]) {
if([Link][i].constructor == String)
[Link][i] = $([Link][i],
[Link]).show();
[Link](padPos, padWrapper);
this._proportionallyResize();
}
};
},
destroy: function() {
this._mouseDestroy();
[Link]('resize', [Link]);
_destroy([Link]);
return this;
},
_mouseCapture: function(event) {
var handle = false;
for (var i in [Link]) {
if ($([Link][i])[0] == [Link]) {
handle = true;
}
}
_mouseStart: function(event) {
[Link] = true;
[Link] = { top: $(document).scrollTop(), left: $
(document).scrollLeft() };
this._renderProxy();
if ([Link]) {
curleft += $([Link]).scrollLeft() || 0;
curtop += $([Link]).scrollTop() || 0;
}
//Aspect Ratio
[Link] = (typeof [Link] == 'number') ? [Link] :
(([Link] / [Link]) || 1);
[Link]("ui-resizable-resizing");
this._propagate("start", event);
return true;
},
_mouseDrag: function(event) {
// Put this in the mouseDrag handler since the user can start pressing
shift while resizing
this._updateVirtualBoundaries([Link]);
if (this._aspectRatio || [Link])
data = this._updateRatio(data, event);
[Link]({
top: [Link] + "px", left: [Link] + "px",
width: [Link] + "px", height: [Link] + "px"
});
this._updateCache(data);
return false;
},
_mouseStop: function(event) {
[Link] = false;
var o = [Link], self = this;
if(this._helper) {
var pr = this._proportionallyResizeElements, ista = [Link] &&
(/textarea/i).test(pr[0].nodeName),
soffseth = ista && $.[Link](pr[0], 'left') /* TODO -
jump height */ ? 0 : [Link],
soffsetw = ista ? 0 : [Link];
if (![Link])
[Link]($.extend(s, { top: top, left: left }));
[Link]([Link]);
[Link]([Link]);
if (this._helper && ![Link]) this._proportionallyResize();
}
$('body').css('cursor', 'auto');
[Link]("ui-resizable-resizing");
this._propagate("stop", event);
if (this._helper) [Link]();
return false;
},
_updateVirtualBoundaries: function(forceAspectRatio) {
var o = [Link], pMinWidth, pMaxWidth, pMinHeight, pMaxHeight, b;
b = {
minWidth: isNumber([Link]) ? [Link] : 0,
maxWidth: isNumber([Link]) ? [Link] : Infinity,
minHeight: isNumber([Link]) ? [Link] : 0,
maxHeight: isNumber([Link]) ? [Link] : Infinity
};
if(this._aspectRatio || forceAspectRatio) {
// We want to create an enclosing box whose aspect ration is the
requested one
// First, compute the "projected" size for each dimension based on the
aspect ratio and other dimension
pMinWidth = [Link] * [Link];
pMinHeight = [Link] / [Link];
pMaxWidth = [Link] * [Link];
pMaxHeight = [Link] / [Link];
_updateCache: function(data) {
var o = [Link];
[Link] = [Link]();
if (isNumber([Link])) [Link] = [Link];
if (isNumber([Link])) [Link] = [Link];
if (isNumber([Link])) [Link] = [Link];
if (isNumber([Link])) [Link] = [Link];
},
if (a == 'sw') {
[Link] = [Link] + ([Link] - [Link]);
[Link] = null;
}
if (a == 'nw') {
[Link] = [Link] + ([Link] - [Link]);
[Link] = [Link] + ([Link] - [Link]);
}
return data;
},
return data;
},
_proportionallyResize: function() {
var o = [Link];
if (!this._proportionallyResizeElements.length) return;
var element = [Link] || [Link];
if (![Link]) {
var b = [[Link]('borderTopWidth'),
[Link]('borderRightWidth'), [Link]('borderBottomWidth'),
[Link]('borderLeftWidth')],
p = [[Link]('paddingTop'),
[Link]('paddingRight'), [Link]('paddingBottom'), [Link]('paddingLeft')];
[Link]({
height: ([Link]() - [Link][0] -
[Link][2]) || 0,
width: ([Link]() - [Link][1] -
[Link][3]) || 0
});
};
},
_renderProxy: function() {
if(this._helper) {
[Link](this._helper).css({
width: [Link]() + pxyoffset,
height: [Link]() + pxyoffset,
position: 'absolute',
left: [Link] - ie6offset +'px',
top: [Link] - ie6offset +'px',
zIndex: ++[Link] //TODO: Don't modify option
});
[Link]
.appendTo("body")
.disableSelection();
} else {
[Link] = [Link];
}
},
_change: {
e: function(event, dx, dy) {
return { width: [Link] + dx };
},
w: function(event, dx, dy) {
var o = [Link], cs = [Link], sp =
[Link];
return { left: [Link] + dx, width: [Link] - dx };
},
n: function(event, dx, dy) {
var o = [Link], cs = [Link], sp =
[Link];
return { top: [Link] + dy, height: [Link] - dy };
},
s: function(event, dx, dy) {
return { height: [Link] + dy };
},
se: function(event, dx, dy) {
return $.extend(this._change.[Link](this, arguments),
this._change.[Link](this, [event, dx, dy]));
},
sw: function(event, dx, dy) {
return $.extend(this._change.[Link](this, arguments),
this._change.[Link](this, [event, dx, dy]));
},
ne: function(event, dx, dy) {
return $.extend(this._change.[Link](this, arguments),
this._change.[Link](this, [event, dx, dy]));
},
nw: function(event, dx, dy) {
return $.extend(this._change.[Link](this, arguments),
this._change.[Link](this, [event, dx, dy]));
}
},
plugins: {},
ui: function() {
return {
originalElement: [Link],
element: [Link],
helper: [Link],
position: [Link],
size: [Link],
originalSize: [Link],
originalPosition: [Link]
};
}
});
$.extend($.[Link], {
version: "1.8.24"
});
/*
* Resizable Extensions
*/
$.[Link]("resizable", "alsoResize", {
var delta = {
height: ([Link] - [Link]) || 0, width:
([Link] - [Link]) || 0,
top: ([Link] - [Link]) || 0, left: ([Link]
- [Link]) || 0
},
[Link](style);
});
};
$.[Link]("resizable", "animate", {
[Link](
$.extend(style, top && left ? { top: top, left: left } : {}), {
duration: [Link],
easing: [Link],
step: function() {
var data = {
width: parseInt([Link]('width'), 10),
height: parseInt([Link]('height'),
10),
top: parseInt([Link]('top'), 10),
left: parseInt([Link]('left'), 10)
};
}
}
);
}
});
$.[Link]("resizable", "containment", {
[Link] = $(ce);
if (/document/.test(oc) || oc == document) {
[Link] = { left: 0, top: 0 };
[Link] = { left: 0, top: 0 };
[Link] = {
element: $(document), left: 0, top: 0,
width: $(document).width(), height: $(document).height() ||
[Link]
};
}
[Link] = [Link]();
[Link] = [Link]();
[Link] = { height: ([Link]() - p[3]),
width: ([Link]() - p[1]) };
[Link] = {
element: ce, left: [Link], top: [Link], width: width,
height: height
};
}
},
[Link] = [Link]+[Link];
[Link] = [Link]+[Link];
}
});
$.[Link]("resizable", "ghost", {
[Link] = [Link]();
[Link]
.css({ opacity: .25, display: 'block', position: 'relative',
height: [Link], width: [Link], margin: 0, left: 0, top: 0 })
.addClass('ui-resizable-ghost')
.addClass(typeof [Link] == 'string' ? [Link] : '');
[Link]([Link]);
},
});
$.[Link]("resizable", "grid", {
if (/^(se|s|e)$/.test(a)) {
[Link] = [Link] + ox;
[Link] = [Link] + oy;
}
else if (/^(ne)$/.test(a)) {
[Link] = [Link] + ox;
[Link] = [Link] + oy;
[Link] = [Link] - oy;
}
else if (/^(sw)$/.test(a)) {
[Link] = [Link] + ox;
[Link] = [Link] + oy;
[Link] = [Link] - ox;
}
else {
[Link] = [Link] + ox;
[Link] = [Link] + oy;
[Link] = [Link] - oy;
[Link] = [Link] - ox;
}
}
});
})(jQuery);
(function( $, undefined ) {
$.widget("[Link]", $.[Link], {
options: {
appendTo: 'body',
autoRefresh: true,
distance: 0,
filter: '*',
tolerance: 'touch'
},
_create: function() {
var self = this;
[Link]("ui-selectable");
[Link] = false;
[Link] = [Link]("ui-selectee");
this._mouseInit();
destroy: function() {
[Link]
.removeClass("ui-selectee")
.removeData("selectable-item");
[Link]
.removeClass("ui-selectable ui-selectable-disabled")
.removeData("selectable")
.unbind(".selectable");
this._mouseDestroy();
return this;
},
_mouseStart: function(event) {
var self = this;
if ([Link])
return;
this._trigger("start", event);
$([Link]).append([Link]);
// position helper (lasso)
[Link]({
"left": [Link],
"top": [Link],
"width": 0,
"height": 0
});
if ([Link]) {
[Link]();
}
[Link]('.ui-selected').each(function() {
var selectee = $.data(this, "selectable-item");
[Link] = true;
if (![Link] && ![Link]) {
selectee.$[Link]('ui-selected');
[Link] = false;
selectee.$[Link]('ui-unselecting');
[Link] = true;
// selectable UNSELECTING callback
self._trigger("unselecting", event, {
unselecting: [Link]
});
}
});
$([Link]).parents().andSelf().each(function() {
var selectee = $.data(this, "selectable-item");
if (selectee) {
var doSelect = (![Link] && ![Link]) || !
selectee.$[Link]('ui-selected');
selectee.$element
.removeClass(doSelect ? "ui-unselecting" : "ui-
selected")
.addClass(doSelect ? "ui-selecting" : "ui-
unselecting");
[Link] = !doSelect;
[Link] = doSelect;
[Link] = doSelect;
// selectable (UN)SELECTING callback
if (doSelect) {
self._trigger("selecting", event, {
selecting: [Link]
});
} else {
self._trigger("unselecting", event, {
unselecting: [Link]
});
}
return false;
}
});
},
_mouseDrag: function(event) {
var self = this;
[Link] = true;
if ([Link])
return;
[Link](function() {
var selectee = $.data(this, "selectable-item");
//prevent helper from being selected if appendTo: selectable
if (!selectee || [Link] == [Link][0])
return;
var hit = false;
if ([Link] == 'touch') {
hit = ( !([Link] > x2 || [Link] < x1 ||
[Link] > y2 || [Link] < y1) );
} else if ([Link] == 'fit') {
hit = ([Link] > x1 && [Link] < x2 &&
[Link] > y1 && [Link] < y2);
}
if (hit) {
// SELECT
if ([Link]) {
selectee.$[Link]('ui-selected');
[Link] = false;
}
if ([Link]) {
selectee.$[Link]('ui-unselecting');
[Link] = false;
}
if (![Link]) {
selectee.$[Link]('ui-selecting');
[Link] = true;
// selectable SELECTING callback
self._trigger("selecting", event, {
selecting: [Link]
});
}
} else {
// UNSELECT
if ([Link]) {
if (([Link] || [Link]) &&
[Link]) {
selectee.$[Link]('ui-selecting');
[Link] = false;
selectee.$[Link]('ui-selected');
[Link] = true;
} else {
selectee.$[Link]('ui-selecting');
[Link] = false;
if ([Link]) {
selectee.$[Link]('ui-
unselecting');
[Link] = true;
}
// selectable UNSELECTING callback
self._trigger("unselecting", event, {
unselecting: [Link]
});
}
}
if ([Link]) {
if (![Link] && ![Link] && !
[Link]) {
selectee.$[Link]('ui-selected');
[Link] = false;
selectee.$[Link]('ui-unselecting');
[Link] = true;
// selectable UNSELECTING callback
self._trigger("unselecting", event, {
unselecting: [Link]
});
}
}
}
});
return false;
},
_mouseStop: function(event) {
var self = this;
[Link] = false;
$('.ui-unselecting', [Link][0]).each(function() {
var selectee = $.data(this, "selectable-item");
selectee.$[Link]('ui-unselecting');
[Link] = false;
[Link] = false;
self._trigger("unselected", event, {
unselected: [Link]
});
});
$('.ui-selecting', [Link][0]).each(function() {
var selectee = $.data(this, "selectable-item");
selectee.$[Link]('ui-selecting').addClass('ui-
selected');
[Link] = false;
[Link] = true;
[Link] = true;
self._trigger("selected", event, {
selected: [Link]
});
});
this._trigger("stop", event);
[Link]();
return false;
}
});
$.extend($.[Link], {
version: "1.8.24"
});
})(jQuery);
(function( $, undefined ) {
$.widget("[Link]", $.[Link], {
widgetEventPrefix: "sort",
ready: false,
options: {
appendTo: "parent",
axis: false,
connectWith: false,
containment: false,
cursor: 'auto',
cursorAt: false,
dropOnEmpty: true,
forcePlaceholderSize: false,
forceHelperSize: false,
grid: false,
handle: false,
helper: "original",
items: '> *',
opacity: false,
placeholder: false,
revert: false,
scroll: true,
scrollSensitivity: 20,
scrollSpeed: 20,
scope: "default",
tolerance: "intersect",
zIndex: 1000
},
_create: function() {
var o = [Link];
[Link] = {};
[Link]("ui-sortable");
//We're ready to go
[Link] = true
},
destroy: function() {
$.[Link]( this );
[Link]
.removeClass("ui-sortable ui-sortable-disabled");
this._mouseDestroy();
return this;
},
[Link]()
[ value ? "addClass" : "removeClass"]( "ui-sortable-
disabled" );
} else {
// Don't call widget base _setOption for disable as it adds ui-
state-disabled class
$.[Link]._setOption.apply(this, arguments);
}
},
if ([Link]) {
return false;
}
//Find out if the clicked node (or one of its parents) is a actual item
in [Link]
var currentItem = null, self = this, nodes = $
([Link]).parents().each(function() {
if($.data(this, [Link] + '-item') == self) {
currentItem = $(this);
return false;
}
});
if($.data([Link], [Link] + '-item') == self) currentItem
= $([Link]);
$([Link],
currentItem).find("*").andSelf().each(function() { if(this == [Link])
validHandle = true; });
if(!validHandle) return false;
}
[Link] = currentItem;
this._removeCurrentsFromItems();
return true;
},
/*
* - Position generation -
* This block generates everything position related - it's the core of
draggables.
*/
$.extend([Link], {
click: { //Where the click happened, relative to the element
left: [Link] - [Link],
top: [Link] - [Link]
},
parent: this._getParentOffset(),
relative: this._getRelativeOffset() //This is a relative to
absolute position minus the actual position calculation - only used for relative
positioned helper
});
// Only after we got the offset, we can change the helper's position to
absolute
// TODO: Still need to figure out a way to make relative sorting
possible
[Link]("position", "absolute");
[Link] = [Link]("position");
//Prepare scrolling
if([Link][0] != document && [Link][0].tagName !=
'HTML')
[Link] = [Link]();
//Call callbacks
this._trigger("start", event, this._uiHash());
[Link] = true;
[Link]("ui-sortable-helper");
this._mouseDrag(event); //Execute the drag once - this causes the
helper not to be visible before getting its correct position
return true;
},
_mouseDrag: function(event) {
if (![Link]) {
[Link] = [Link];
}
//Do scrolling
if([Link]) {
var o = [Link], scrolled = false;
if([Link][0] != document &&
[Link][0].tagName != 'HTML') {
if(([Link] +
[Link][0].offsetHeight) - [Link] < [Link])
[Link][0].scrollTop = scrolled =
[Link][0].scrollTop + [Link];
else if([Link] - [Link] <
[Link])
[Link][0].scrollTop = scrolled =
[Link][0].scrollTop - [Link];
if(([Link] +
[Link][0].offsetWidth) - [Link] < [Link])
[Link][0].scrollLeft = scrolled =
[Link][0].scrollLeft + [Link];
else if([Link] - [Link] <
[Link])
[Link][0].scrollLeft = scrolled =
[Link][0].scrollLeft - [Link];
} else {
//Rearrange
for (var i = [Link] - 1; i >= 0; i--) {
if ([Link] == "pointer" ||
this._intersectsWithSides(item)) {
this._rearrange(event, item);
} else {
break;
}
//Call callbacks
this._trigger('sort', event, this._uiHash());
[Link] = [Link];
return false;
},
if(!event) return;
//If we are using droppables, inform the manager about the drop
if ($.[Link] && ![Link])
$.[Link](this, event);
if([Link]) {
var self = this;
var cur = [Link]();
[Link] = true;
$([Link]).animate({
left: [Link] - [Link] -
[Link] + ([Link][0] == [Link] ? 0 :
[Link][0].scrollLeft),
top: [Link] - [Link] - [Link] +
([Link][0] == [Link] ? 0 : [Link][0].scrollTop)
}, parseInt([Link], 10) || 500, function() {
self._clear(event);
});
} else {
this._clear(event, noPropagation);
}
return false;
},
cancel: function() {
if([Link]) {
if([Link] == "original")
[Link](this._storedCSS).removeClass("ui-
sortable-helper");
else
[Link]();
if ([Link]) {
//$([Link][0]).remove(); would have been the jQuery way
- unfortunately, it unbinds ALL events from the original node!
if([Link][0].parentNode)
[Link][0].[Link]([Link][0]);
if([Link] != "original" && [Link] &&
[Link][0].parentNode) [Link]();
$.extend(this, {
helper: null,
dragging: false,
reverting: false,
_noFinalSort: null
});
if([Link]) {
$([Link]).after([Link]);
} else {
$([Link]).prepend([Link]);
}
}
return this;
},
serialize: function(o) {
$(items).each(function() {
var res = ($([Link] || this).attr([Link] || 'id') ||
'').match([Link] || (/(.+)[-=_](.+)/));
if(res) [Link](([Link] || res[1]+'[]')+'='+([Link] &&
[Link] ? res[1] : res[2]));
});
return [Link]('&');
},
toArray: function(o) {
},
var x1 = [Link],
x2 = x1 + [Link],
y1 = [Link],
y2 = y1 + [Link];
var l = [Link],
r = l + [Link],
t = [Link],
b = t + [Link];
var isOverElement = (y1 + dyClick) > t && (y1 + dyClick) < b && (x1 +
dxClick) > l && (x1 + dxClick) < r;
}
},
_intersectsWithPointer: function(item) {
if (!isOverElement)
return false;
return [Link] ?
( ((horizontalDirection && horizontalDirection == "right") ||
verticalDirection == "down") ? 2 : 1 )
: ( verticalDirection && (verticalDirection == "down" ? 2 : 1) );
},
_intersectsWithSides: function(item) {
},
_getDragVerticalDirection: function() {
var delta = [Link] - [Link];
return delta != 0 && (delta > 0 ? "down" : "up");
},
_getDragHorizontalDirection: function() {
var delta = [Link] - [Link];
return delta != 0 && (delta > 0 ? "right" : "left");
},
refresh: function(event) {
this._refreshItems(event);
[Link]();
return this;
},
_connectWith: function() {
var options = [Link];
return [Link] == String
? [[Link]]
: [Link];
},
_getItemsAsjQuery: function(connected) {
var self = this;
var items = [];
var queries = [];
var connectWith = this._connectWith();
[Link]([$.isFunction([Link]) ?
[Link]([Link]) : $([Link],
[Link]).not(".ui-sortable-helper").not('.ui-sortable-placeholder'), inst]);
}
};
};
}
[Link]([$.isFunction([Link]) ?
[Link]([Link], null, { options: [Link], item:
[Link] }) : $([Link], [Link]).not(".ui-sortable-
helper").not('.ui-sortable-placeholder'), this]);
return $(items);
},
_removeCurrentsFromItems: function() {
};
},
_refreshItems: function(event) {
[Link] = [];
[Link] = [this];
var items = [Link];
var self = this;
var queries = [[$.isFunction([Link]) ?
[Link]([Link][0], event, { item: [Link] }) : $
([Link], [Link]), this]];
var connectWith = this._connectWith();
[Link]([$.isFunction([Link]) ?
[Link]([Link][0], event, { item: [Link] }) : $
([Link], [Link]), inst]);
[Link](inst);
}
};
};
}
[Link]({
item: item,
instance: targetData,
width: 0, height: 0,
left: 0, top: 0
});
};
};
},
refreshPositions: function(fast) {
//This has to be redone because due to the item being moved out/into
the offsetParent, the offsetParent's position will change
if([Link] && [Link]) {
[Link] = this._getParentOffset();
}
if (!fast) {
[Link] = [Link]();
[Link] = [Link]();
}
var p = [Link]();
[Link] = [Link];
[Link] = [Link];
};
return this;
},
_createPlaceholder: function(that) {
var el = $
([Link]([Link][0].nodeName))
.addClass(className ||
[Link][0].className+" ui-sortable-placeholder")
.removeClass("ui-sortable-helper")[0];
if(!className)
[Link] = "hidden";
return el;
},
update: function(container, p) {
//Update the size of the placeholder (TODO: Logic to fuzzy, see line
316/317)
[Link](self, [Link]);
},
_contactContainers: function(event) {
if(this._intersectsWith([Link][i].containerCache)) {
innermostContainer = [Link][i];
innermostIndex = i;
} else {
// container doesn't intersect. trigger "out" event if
necessary
if([Link][i].[Link]) {
[Link][i]._trigger("out", event,
this._uiHash(this));
[Link][i].[Link] = 0;
}
}
// move the item into the container if it's not there already
if([Link] === 1) {
[Link][innermostIndex]._trigger("over", event,
this._uiHash(this));
[Link][innermostIndex].[Link] = 1;
} else if([Link] != [Link][innermostIndex]) {
//When entering a new container, we will find the item with the
least distance and append our item near it
var dist = 10000; var itemWithLeastDistance = null; var base =
[Link][[Link][innermostIndex].floating ? 'left' : 'top'];
for (var j = [Link] - 1; j >= 0; j--) {
if(!
$.[Link]([Link][innermostIndex].element[0], [Link][j].item[0]))
continue;
var cur = [Link][innermostIndex].floating ?
[Link][j].[Link]().left : [Link][j].[Link]().top;
if([Link](cur - base) < dist) {
dist = [Link](cur - base); itemWithLeastDistance =
[Link][j];
[Link] = (cur - base > 0) ? 'down' : 'up';
}
}
[Link] = [Link][innermostIndex];
itemWithLeastDistance ? this._rearrange(event,
itemWithLeastDistance, null, true) : this._rearrange(event, null,
[Link][innermostIndex].element, true);
this._trigger("change", event, this._uiHash());
[Link][innermostIndex]._trigger("change", event,
this._uiHash(this));
[Link][innermostIndex]._trigger("over", event,
this._uiHash(this));
[Link][innermostIndex].[Link] = 1;
}
},
_createHelper: function(event) {
var o = [Link];
var helper = $.isFunction([Link]) ? $([Link]([Link][0],
[event, [Link]])) : ([Link] == 'clone' ? [Link]() :
[Link]);
if(helper[0] == [Link][0])
this._storedCSS = { width: [Link][0].[Link],
height: [Link][0].[Link], position:
[Link]("position"), top: [Link]("top"), left:
[Link]("left") };
return helper;
},
_adjustOffsetFromHelper: function(obj) {
if (typeof obj == 'string') {
obj = [Link](' ');
}
if ($.isArray(obj)) {
obj = {left: +obj[0], top: +obj[1] || 0};
}
if ('left' in obj) {
[Link] = [Link] + [Link];
}
if ('right' in obj) {
[Link] = [Link] - [Link]
+ [Link];
}
if ('top' in obj) {
[Link] = [Link] + [Link];
}
if ('bottom' in obj) {
[Link] = [Link] -
[Link] + [Link];
}
},
_getParentOffset: function() {
return {
top: [Link] +
(parseInt([Link]("borderTopWidth"),10) || 0),
left: [Link] +
(parseInt([Link]("borderLeftWidth"),10) || 0)
};
},
_getRelativeOffset: function() {
if([Link] == "relative") {
var p = [Link]();
return {
top: [Link] - (parseInt([Link]("top"),10) || 0) +
[Link](),
left: [Link] - (parseInt([Link]("left"),10) || 0)
+ [Link]()
};
} else {
return { top: 0, left: 0 };
}
},
_cacheMargins: function() {
[Link] = {
left: (parseInt([Link]("marginLeft"),10) || 0),
top: (parseInt([Link]("marginTop"),10) || 0)
};
},
_cacheHelperProportions: function() {
[Link] = {
width: [Link](),
height: [Link]()
};
},
_setContainment: function() {
var o = [Link];
if([Link] == 'parent') [Link] =
[Link][0].parentNode;
if([Link] == 'document' || [Link] == 'window')
[Link] = [
0 - [Link] - [Link],
0 - [Link] - [Link],
$([Link] == 'document' ? document : window).width() -
[Link] - [Link],
($([Link] == 'document' ? document : window).height() ||
[Link]) - [Link] -
[Link]
];
if(!(/^(document|window|parent)$/).test([Link])) {
var ce = $([Link])[0];
var co = $([Link]).offset();
var over = ($(ce).css("overflow") != 'hidden');
[Link] = [
[Link] + (parseInt($(ce).css("borderLeftWidth"),10) || 0)
+ (parseInt($(ce).css("paddingLeft"),10) || 0) - [Link],
[Link] + (parseInt($(ce).css("borderTopWidth"),10) || 0) +
(parseInt($(ce).css("paddingTop"),10) || 0) - [Link],
[Link]+(over ? [Link]([Link],[Link]) :
[Link]) - (parseInt($(ce).css("borderLeftWidth"),10) || 0) - (parseInt($
(ce).css("paddingRight"),10) || 0) - [Link] -
[Link],
[Link]+(over ? [Link]([Link],[Link]) :
[Link]) - (parseInt($(ce).css("borderTopWidth"),10) || 0) - (parseInt($
(ce).css("paddingBottom"),10) || 0) - [Link] -
[Link]
];
}
},
return {
top: (
[Link]
// The absolute mouse position
+ [Link] * mod
// Only for relative positioned nodes: Relative
offset from element to offset parent
+ [Link] * mod
// The offsetParent's offset without borders
(offset + border)
- ($.[Link] && [Link] == 'fixed' ? 0 :
( [Link] == 'fixed' ? -[Link]() : ( scrollIsRootNode
? 0 : [Link]() ) ) * mod)
),
left: (
[Link]
// The absolute mouse position
+ [Link] * mod
// Only for relative positioned nodes: Relative
offset from element to offset parent
+ [Link] * mod
// The offsetParent's offset without borders
(offset + border)
- ($.[Link] && [Link] == 'fixed' ? 0 :
( [Link] == 'fixed' ? -[Link]() :
scrollIsRootNode ? 0 : [Link]() ) * mod)
)
};
},
_generatePosition: function(event) {
// This is another very weird special case that only happens for
relative elements:
// 1. If the css position is relative
// 2. and the scroll parent is the document or similar to the offset
parent
// we have to refresh the relative offset during the scroll so there
are no jumps
if([Link] == 'relative' && !([Link][0] != document
&& [Link][0] != [Link][0])) {
[Link] = this._getRelativeOffset();
}
/*
* - Position constraining -
* Constrain the position to a mix of grid, containment.
*/
if([Link]) {
if([Link] - [Link] <
[Link][0]) pageX = [Link][0] + [Link];
if([Link] - [Link] <
[Link][1]) pageY = [Link][1] + [Link];
if([Link] - [Link] >
[Link][2]) pageX = [Link][2] + [Link];
if([Link] - [Link] >
[Link][3]) pageY = [Link][3] + [Link];
}
if([Link]) {
var top = [Link] + [Link]((pageY -
[Link]) / [Link][1]) * [Link][1];
pageY = [Link] ? (!(top - [Link] <
[Link][1] || top - [Link] > [Link][3]) ? top :
(!(top - [Link] < [Link][1]) ? top - [Link][1] : top +
[Link][1])) : top;
return {
top: (
pageY
// The absolute mouse position
- [Link]
// Click offset (relative to the element)
- [Link]
// Only for relative positioned nodes: Relative
offset from element to offset parent
- [Link]
// The offsetParent's offset without borders
(offset + border)
+ ($.[Link] && [Link] == 'fixed' ? 0 :
( [Link] == 'fixed' ? -[Link]() : ( scrollIsRootNode
? 0 : [Link]() ) ))
),
left: (
pageX
// The absolute mouse position
- [Link]
// Click offset (relative to the element)
- [Link]
// Only for relative positioned nodes: Relative
offset from element to offset parent
- [Link]
// The offsetParent's offset without borders
(offset + border)
+ ($.[Link] && [Link] == 'fixed' ? 0 :
( [Link] == 'fixed' ? -[Link]() :
scrollIsRootNode ? 0 : [Link]() ))
)
};
},
a ? a[0].appendChild([Link][0]) :
[Link][0].[Link]([Link][0], ([Link] == 'down' ?
[Link][0] : [Link][0].nextSibling));
[Link](function() {
if(counter == [Link]) [Link](!
hardRefresh); //Precompute after each DOM insertion, NOT on mousemove
},0);
},
[Link] = false;
// We delay all events that have to be triggered to after the point
where the placeholder has been removed and
// everything else normalized again
var delayedTriggers = [], self = this;
if([Link][0] == [Link][0]) {
for(var i in this._storedCSS) {
if(this._storedCSS[i] == 'auto' || this._storedCSS[i] ==
'static') this._storedCSS[i] = '';
}
[Link](this._storedCSS).removeClass("ui-sortable-
helper");
} else {
[Link]();
}
[Link] = false;
if([Link]) {
if(!noPropagation) {
this._trigger("beforeStop", event, this._uiHash());
for (var i=0; i < [Link]; i++)
{ delayedTriggers[i].call(this, event); }; //Trigger all delayed events
this._trigger("stop", event, this._uiHash());
}
[Link] = false;
return false;
}
if(!noPropagation) {
for (var i=0; i < [Link]; i++)
{ delayedTriggers[i].call(this, event); }; //Trigger all delayed events
this._trigger("stop", event, this._uiHash());
}
[Link] = false;
return true;
},
_trigger: function() {
if ($.[Link]._trigger.apply(this, arguments) === false) {
[Link]();
}
},
_uiHash: function(inst) {
var self = inst || this;
return {
helper: [Link],
placeholder: [Link] || $([]),
position: [Link],
originalPosition: [Link],
offset: [Link],
item: [Link],
sender: inst ? [Link] : null
};
}
});
$.extend($.[Link], {
version: "1.8.24"
});
})(jQuery);
$.effects = {};
/******************************************************************************/
/****************************** COLOR ANIMATIONS ******************************/
/******************************************************************************/
[Link][attr] = 'rgb(' +
[Link]([Link](parseInt(([Link] * ([Link][0] - [Link][0])) +
[Link][0], 10), 255), 0) + ',' +
[Link]([Link](parseInt(([Link] * ([Link][1] - [Link][1])) +
[Link][1], 10), 255), 0) + ',' +
[Link]([Link](parseInt(([Link] * ([Link][2] - [Link][2])) +
[Link][2], 10), 255), 0) + ')';
};
});
// Color Conversion functions from highlightFade
// By Blair Mitchelmore
// [Link]
do {
// jQuery <1.4.3 uses curCSS, in 1.4.3 - 1.7.2 curCSS =
css, 1.8+ only has css
color = ($.curCSS || $.css)(elem, attr);
attr = "backgroundColor";
} while ( elem = [Link] );
return getRGB(color);
};
var colors = {
aqua:[0,255,255],
azure:[240,255,255],
beige:[245,245,220],
black:[0,0,0],
blue:[0,0,255],
brown:[165,42,42],
cyan:[0,255,255],
darkblue:[0,0,139],
darkcyan:[0,139,139],
darkgrey:[169,169,169],
darkgreen:[0,100,0],
darkkhaki:[189,183,107],
darkmagenta:[139,0,139],
darkolivegreen:[85,107,47],
darkorange:[255,140,0],
darkorchid:[153,50,204],
darkred:[139,0,0],
darksalmon:[233,150,122],
darkviolet:[148,0,211],
fuchsia:[255,0,255],
gold:[255,215,0],
green:[0,128,0],
indigo:[75,0,130],
khaki:[240,230,140],
lightblue:[173,216,230],
lightcyan:[224,255,255],
lightgreen:[144,238,144],
lightgrey:[211,211,211],
lightpink:[255,182,193],
lightyellow:[255,255,224],
lime:[0,255,0],
magenta:[255,0,255],
maroon:[128,0,0],
navy:[0,0,128],
olive:[128,128,0],
orange:[255,165,0],
pink:[255,192,203],
purple:[128,0,128],
violet:[128,0,128],
red:[255,0,0],
silver:[192,192,192],
white:[255,255,255],
yellow:[255,255,0],
transparent: [255,255,255]
};
/******************************************************************************/
/****************************** CLASS ANIMATIONS ******************************/
/******************************************************************************/
function getElementStyles() {
var style = [Link]
? [Link](this, null)
: [Link],
newStyle = {},
key,
camelCase;
return newStyle;
}
function filterStyles(styles) {
var name, value;
for (name in styles) {
value = styles[name];
if (
// ignore null and undefined values
value == null ||
// ignore functions (when does this occur?)
$.isFunction(value) ||
// shorthand styles that need to be expanded
name in shorthandStyles ||
// ignore scrollbars (break in IE)
(/scrollbar/).test(name) ||
return styles;
}
return diff;
}
return [Link](function() {
var that = $(this),
originalStyleAttr = [Link]('style') || ' ',
originalStyle = filterStyles([Link](this)),
newStyle,
className = [Link]('class') || "";
[Link](styleDifference(originalStyle, newStyle), {
queue: false,
duration: duration,
easing: easing,
complete: function() {
$.each(classAnimationActions, function(i, action) {
if (value[action]) { that[action + 'Class']
(value[action]); }
});
// work around bug in IE by clearing the cssText before
setting it
if (typeof [Link]('style') == 'object') {
[Link]('style').cssText = '';
[Link]('style').cssText = originalStyleAttr;
} else {
[Link]('style', originalStyleAttr);
}
if (callback) { [Link](this, arguments); }
$.dequeue( this );
}
});
});
};
$.[Link]({
_addClass: $.[Link],
addClass: function(classNames, speed, easing, callback) {
return speed ? $.[Link](this, [{ add:
classNames },speed,easing,callback]) : this._addClass(classNames);
},
_removeClass: $.[Link],
removeClass: function(classNames,speed,easing,callback) {
return speed ? $.[Link](this, [{ remove: classNames
},speed,easing,callback]) : this._removeClass(classNames);
},
_toggleClass: $.[Link],
toggleClass: function(classNames, force, speed, easing, callback) {
if ( typeof force == "boolean" || force === undefined ) {
if ( !speed ) {
// without speed parameter;
return this._toggleClass(classNames, force);
} else {
return $.[Link](this, [(force?
{add:classNames}:{remove:classNames}),speed,easing,callback]);
}
} else {
// without switch parameter;
return $.[Link](this, [{ toggle:
classNames },force,speed,easing]);
}
},
switchClass: function(remove,add,speed,easing,callback) {
return $.[Link](this, [{ add: add, remove:
remove },speed,easing,callback]);
}
});
/******************************************************************************/
/*********************************** EFFECTS **********************************/
/******************************************************************************/
$.extend($.effects, {
version: "1.8.24",
// support: Firefox
// Firefox incorrectly exposes anonymous content
// [Link]
try {
[Link];
} catch( e ) {
active = [Link];
}
[Link]( wrapper );
return [Link](props).show();
},
removeWrapper: function(element) {
var parent,
active = [Link];
if ([Link]().is('.ui-effects-wrapper')) {
parent = [Link]().replaceWith(element);
// Fixes #7595 - Elements lose focus when wrapped.
if ( element[ 0 ] === active || $.contains( element[ 0 ],
active ) ) {
$( active ).focus();
}
return parent;
}
return element;
},
return false;
}
$.[Link]({
effect: function(effect, options, speed, callback) {
var args = _normalizeArguments.apply(this, arguments),
// TODO: make effects take actual parameters instead of a hash
args2 = {
options: args[1],
duration: args[2],
callback: args[3]
},
mode = [Link],
effectMethod = $.effects[effect];
if ( $.[Link] || !effectMethod ) {
// delegate to the original method (e.g., .show()) if possible
if ( mode ) {
return this[ mode ]( [Link], [Link] );
} else {
return [Link](function() {
if ( [Link] ) {
[Link]( this );
}
});
}
}
_show: $.[Link],
show: function(speed) {
if ( standardSpeed( speed ) ) {
return this._show.apply(this, arguments);
} else {
var args = _normalizeArguments.apply(this, arguments);
args[1].mode = 'show';
return [Link](this, args);
}
},
_hide: $.[Link],
hide: function(speed) {
if ( standardSpeed( speed ) ) {
return this._hide.apply(this, arguments);
} else {
var args = _normalizeArguments.apply(this, arguments);
args[1].mode = 'hide';
return [Link](this, args);
}
},
// helper functions
cssUnit: function(key) {
var style = [Link](key), val = [];
$.each( ['em','px','%','pt'], function(i, unit){
if([Link](unit) > 0)
val = [parseFloat(style), unit];
});
return val;
}
});
/******************************************************************************/
/*********************************** EASING ***********************************/
/******************************************************************************/
$.extend( baseEasings, {
Sine: function ( p ) {
return 1 - [Link]( p * [Link] / 2 );
},
Circ: function ( p ) {
return 1 - [Link]( 1 - p * p );
},
Elastic: function( p ) {
return p === 0 || p === 1 ? p :
-[Link]( 2, 8 * (p - 1) ) * [Link]( ( (p - 1) * 80 - 7.5 ) *
[Link] / 15 );
},
Back: function( p ) {
return p * p * ( 3 * p - 2 );
},
Bounce: function ( p ) {
var pow2,
bounce = 4;
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props = ['position','top','bottom','left','right'];
// Set options
var mode = $.[Link](el, [Link] || 'hide'); // Set Mode
var direction = [Link] || 'vertical'; // Default direction
// Adjust
$.[Link](el, props); [Link](); // Save & Show
var wrapper = $.[Link](el).css({overflow:'hidden'}); //
Create Wrapper
var ref = (direction == 'vertical') ? 'height' : 'width';
var distance = (direction == 'vertical') ? [Link]() :
[Link]();
if(mode == 'show') [Link](ref, 0); // Shift
// Animation
var animation = {};
animation[ref] = mode == 'show' ? distance : 0;
// Animate
[Link](animation, [Link], [Link], function() {
if(mode == 'hide') [Link](); // Hide
$.[Link](el, props); $.[Link](el); //
Restore
if([Link]) [Link](el[0], arguments); // Callback
[Link]();
});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props = ['position','top','bottom','left','right'];
// Set options
var mode = $.[Link](el, [Link] || 'effect'); // Set
Mode
var direction = [Link] || 'up'; // Default direction
var distance = [Link] || 20; // Default distance
var times = [Link] || 5; // Default # of times
var speed = [Link] || 250; // Default speed per bounce
if (/show|hide/.test(mode)) [Link]('opacity'); // Avoid touching
opacity to prevent clearType and PNG issues in IE
// Adjust
$.[Link](el, props); [Link](); // Save & Show
$.[Link](el); // Create Wrapper
var ref = (direction == 'up' || direction == 'down') ? 'top' : 'left';
var motion = (direction == 'up' || direction == 'left') ? 'pos' :
'neg';
var distance = [Link] || (ref == 'top' ?
[Link](true) / 3 : [Link](true) / 3);
if (mode == 'show') [Link]('opacity', 0).css(ref, motion == 'pos' ? -
distance : distance); // Shift
if (mode == 'hide') distance = distance / (times * 2);
if (mode != 'hide') times--;
// Animate
if (mode == 'show') { // Show Bounce
var animation = {opacity: 1};
animation[ref] = (motion == 'pos' ? '+=' : '-=') + distance;
[Link](animation, speed / 2, [Link]);
distance = distance / 2;
times--;
};
for (var i = 0; i < times; i++) { // Bounces
var animation1 = {}, animation2 = {};
animation1[ref] = (motion == 'pos' ? '-=' : '+=') + distance;
animation2[ref] = (motion == 'pos' ? '+=' : '-=') + distance;
[Link](animation1, speed / 2,
[Link]).animate(animation2, speed / 2, [Link]);
distance = (mode == 'hide') ? distance * 2 : distance / 2;
};
if (mode == 'hide') { // Last Bounce
var animation = {opacity: 0};
animation[ref] = (motion == 'pos' ? '-=' : '+=') + distance;
[Link](animation, speed / 2, [Link], function(){
[Link](); // Hide
$.[Link](el, props);
$.[Link](el); // Restore
if([Link]) [Link](this, arguments); //
Callback
});
} else {
var animation1 = {}, animation2 = {};
animation1[ref] = (motion == 'pos' ? '-=' : '+=') + distance;
animation2[ref] = (motion == 'pos' ? '+=' : '-=') + distance;
[Link](animation1, speed / 2,
[Link]).animate(animation2, speed / 2, [Link], function(){
$.[Link](el, props);
$.[Link](el); // Restore
if([Link]) [Link](this, arguments); //
Callback
});
};
[Link]('fx', function() { [Link](); });
[Link]();
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props =
['position','top','bottom','left','right','height','width'];
// Set options
var mode = $.[Link](el, [Link] || 'hide'); // Set Mode
var direction = [Link] || 'vertical'; // Default direction
// Adjust
$.[Link](el, props); [Link](); // Save & Show
var wrapper = $.[Link](el).css({overflow:'hidden'}); //
Create Wrapper
var animate = el[0].tagName == 'IMG' ? wrapper : el;
var ref = {
size: (direction == 'vertical') ? 'height' : 'width',
position: (direction == 'vertical') ? 'top' : 'left'
};
var distance = (direction == 'vertical') ? [Link]() :
[Link]();
if(mode == 'show') { [Link]([Link], 0);
[Link]([Link], distance / 2); } // Shift
// Animation
var animation = {};
animation[[Link]] = mode == 'show' ? distance : 0;
animation[[Link]] = mode == 'show' ? 0 : distance / 2;
// Animate
[Link](animation, { queue: false, duration: [Link],
easing: [Link], complete: function() {
if(mode == 'hide') [Link](); // Hide
$.[Link](el, props); $.[Link](el); //
Restore
if([Link]) [Link](el[0], arguments); // Callback
[Link]();
}});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props =
['position','top','bottom','left','right','opacity'];
// Set options
var mode = $.[Link](el, [Link] || 'hide'); // Set Mode
var direction = [Link] || 'left'; // Default Direction
// Adjust
$.[Link](el, props); [Link](); // Save & Show
$.[Link](el); // Create Wrapper
var ref = (direction == 'up' || direction == 'down') ? 'top' : 'left';
var motion = (direction == 'up' || direction == 'left') ? 'pos' :
'neg';
var distance = [Link] || (ref == 'top' ?
[Link]( true ) / 2 : [Link]( true ) / 2);
if (mode == 'show') [Link]('opacity', 0).css(ref, motion == 'pos' ? -
distance : distance); // Shift
// Animation
var animation = {opacity: mode == 'show' ? 1 : 0};
animation[ref] = (mode == 'show' ? (motion == 'pos' ? '+=' : '-=') :
(motion == 'pos' ? '-=' : '+=')) + distance;
// Animate
[Link](animation, { queue: false, duration: [Link], easing:
[Link], complete: function() {
if(mode == 'hide') [Link](); // Hide
$.[Link](el, props); $.[Link](el); //
Restore
if([Link]) [Link](this, arguments); // Callback
[Link]();
}});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
var rows = [Link] ? [Link]([Link]([Link])) : 3;
var cells = [Link] ? [Link]([Link]([Link])) : 3;
for(var i=0;i<rows;i++) { // =
for(var j=0;j<cells;j++) { // ||
el
.clone()
.appendTo('body')
.wrap('<div></div>')
.css({
position: 'absolute',
visibility: 'visible',
left: -j*(width/cells),
top: -i*(height/rows)
})
.parent()
.addClass('ui-effects-explode')
.css({
position: 'absolute',
overflow: 'hidden',
width: width/cells,
height: height/rows,
left: [Link] + j*(width/cells) + ([Link]
== 'show' ? ([Link](cells/2))*(width/cells) : 0),
top: [Link] + i*(height/rows) + ([Link]
== 'show' ? ([Link](rows/2))*(height/rows) : 0),
opacity: [Link] == 'show' ? 0 : 1
}).animate({
left: [Link] + j*(width/cells) + ([Link]
== 'show' ? 0 : ([Link](cells/2))*(width/cells)),
top: [Link] + i*(height/rows) + ([Link]
== 'show' ? 0 : ([Link](rows/2))*(height/rows)),
opacity: [Link] == 'show' ? 1 : 0
}, [Link] || 500);
}
}
// Set a timeout, to call the callback approx. when the other animations have
finished
setTimeout(function() {
}, [Link] || 500);
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
var elem = $(this),
mode = $.[Link](elem, [Link] || 'hide');
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props = ['position','top','bottom','left','right'];
// Set options
var mode = $.[Link](el, [Link] || 'hide'); // Set Mode
var size = [Link] || 15; // Default fold size
var horizFirst = !(![Link]); // Ensure a boolean value
var duration = [Link] ? [Link] / 2 : $.[Link]._default / 2;
// Adjust
$.[Link](el, props); [Link](); // Save & Show
var wrapper = $.[Link](el).css({overflow:'hidden'}); //
Create Wrapper
var widthFirst = ((mode == 'show') != horizFirst);
var ref = widthFirst ? ['width', 'height'] : ['height', 'width'];
var distance = widthFirst ? [[Link](), [Link]()] :
[[Link](), [Link]()];
var percent = /([0-9]+)%/.exec(size);
if(percent) size = parseInt(percent[1],10) / 100 * distance[mode ==
'hide' ? 0 : 1];
if(mode == 'show') [Link](horizFirst ? {height: 0, width: size} :
{height: size, width: 0}); // Shift
// Animation
var animation1 = {}, animation2 = {};
animation1[ref[0]] = mode == 'show' ? distance[0] : size;
animation2[ref[1]] = mode == 'show' ? distance[1] : 0;
// Animate
[Link](animation1, duration, [Link])
.animate(animation2, duration, [Link], function() {
if(mode == 'hide') [Link](); // Hide
$.[Link](el, props); $.[Link](el); //
Restore
if([Link]) [Link](el[0], arguments); // Callback
[Link]();
});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
var elem = $(this),
props = ['backgroundImage', 'backgroundColor', 'opacity'],
mode = $.[Link](elem, [Link] || 'show'),
animation = {
backgroundColor: [Link]('backgroundColor')
};
if (mode == 'hide') {
[Link] = 0;
}
$.[Link](elem, props);
elem
.show()
.css({
backgroundImage: 'none',
backgroundColor: [Link] || '#ffff99'
})
.animate(animation, {
queue: false,
duration: [Link],
easing: [Link],
complete: function() {
(mode == 'hide' && [Link]());
$.[Link](elem, props);
(mode == 'show' && !$.[Link] &&
[Link]('filter'));
([Link] && [Link](this, arguments));
[Link]();
}
});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
var elem = $(this),
mode = $.[Link](elem, [Link] || 'show'),
times = (([Link] || 5) * 2) - 1,
duration = [Link] ? [Link] / 2 : $.[Link]._default /
2,
isVisible = [Link](':visible'),
animateTo = 0;
if (!isVisible) {
[Link]('opacity', 0).show();
animateTo = 1;
}
elem
.queue('fx', function() { [Link](); })
.dequeue();
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
var elem = $(this),
mode = $.[Link](elem, [Link] || 'hide'),
percent = parseInt([Link], 10) || 150,
factor = percent / 100,
original = { height: [Link](), width: [Link]() };
$.extend([Link], {
fade: true,
mode: mode,
percent: mode == 'hide' ? percent : 100,
from: mode == 'hide'
? original
: {
height: [Link] * factor,
width: [Link] * factor
}
});
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this);
// Set options
var options = $.extend(true, {}, [Link]);
var mode = $.[Link](el, [Link] || 'effect'); // Set
Mode
var percent = parseInt([Link],10) ||
(parseInt([Link],10) == 0 ? 0 : (mode == 'hide' ? 0 : 100)); // Set
default scaling percent
var direction = [Link] || 'both'; // Set default axis
var origin = [Link]; // The origin of the scaling
if (mode != 'effect') { // Set default origin and restore for show/hide
[Link] = origin || ['middle','center'];
[Link] = true;
}
var original = {height: [Link](), width: [Link]()}; // Save
original
[Link] = [Link] || (mode == 'show' ? {height: 0, width: 0} :
original); // Default from state
// Adjust
var factor = { // Set scaling factor
y: direction != 'horizontal' ? (percent / 100) : 1,
x: direction != 'vertical' ? (percent / 100) : 1
};
[Link] = {height: [Link] * factor.y, width: [Link] *
factor.x}; // Set to state
// Animation
[Link] = [Link]; [Link] = [Link]; [Link] = mode;
// Animate
[Link]('size', options, [Link], [Link]);
[Link]();
});
};
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props =
['position','top','bottom','left','right','width','height','overflow','opacity'];
var props1 =
['position','top','bottom','left','right','overflow','opacity']; // Always restore
var props2 = ['width','height','overflow']; // Copy for children
var cProps = ['fontSize'];
var vProps = ['borderTopWidth', 'borderBottomWidth', 'paddingTop',
'paddingBottom'];
var hProps = ['borderLeftWidth', 'borderRightWidth', 'paddingLeft',
'paddingRight'];
// Set options
var mode = $.[Link](el, [Link] || 'effect'); // Set
Mode
var restore = [Link] || false; // Default restore
var scale = [Link] || 'both'; // Default scale mode
var origin = [Link]; // The origin of the sizing
var original = {height: [Link](), width: [Link]()}; // Save
original
[Link] = [Link] || original; // Default from state
[Link] = [Link] || original; // Default to state
// Adjust
if (origin) { // Calculate baseline shifts
var baseline = $.[Link](origin, original);
[Link] = ([Link] - [Link]) * baseline.y;
[Link] = ([Link] - [Link]) * baseline.x;
[Link] = ([Link] - [Link]) * baseline.y;
[Link] = ([Link] - [Link]) * baseline.x;
};
var factor = { // Set scaling factor
from: {y: [Link] / [Link], x: [Link] /
[Link]},
to: {y: [Link] / [Link], x: [Link] /
[Link]}
};
if (scale == 'box' || scale == 'both') { // Scale the css box
if ([Link].y != [Link].y) { // Vertical props scaling
props = [Link](vProps);
[Link] = $.[Link](el, vProps,
[Link].y, [Link]);
[Link] = $.[Link](el, vProps, [Link].y,
[Link]);
};
if ([Link].x != [Link].x) { // Horizontal props scaling
props = [Link](hProps);
[Link] = $.[Link](el, hProps,
[Link].x, [Link]);
[Link] = $.[Link](el, hProps, [Link].x,
[Link]);
};
};
if (scale == 'content' || scale == 'both') { // Scale the content
if ([Link].y != [Link].y) { // Vertical props scaling
props = [Link](cProps);
[Link] = $.[Link](el, cProps,
[Link].y, [Link]);
[Link] = $.[Link](el, cProps, [Link].y,
[Link]);
};
};
$.[Link](el, restore ? props : props1); [Link](); // Save & Show
$.[Link](el); // Create Wrapper
[Link]('overflow','hidden').css([Link]); // Shift
// Animate
if (scale == 'content' || scale == 'both') { // Scale the children
vProps =
[Link](['marginTop','marginBottom']).concat(cProps); // Add margins/font-
size
hProps = [Link](['marginLeft','marginRight']); // Add
margins
props2 = [Link](vProps).concat(hProps); // Concat
[Link]("*[width]").each(function(){
var child = $(this);
if (restore) $.[Link](child, props2);
var c_original = {height: [Link](), width:
[Link]()}; // Save original
[Link] = {height: c_original.height * [Link].y,
width: c_original.width * [Link].x};
[Link] = {height: c_original.height * [Link].y, width:
c_original.width * [Link].x};
if ([Link].y != [Link].y) { // Vertical props
scaling
[Link] = $.[Link](child, vProps,
[Link].y, [Link]);
[Link] = $.[Link](child, vProps,
[Link].y, [Link]);
};
if ([Link].x != [Link].x) { // Horizontal props
scaling
[Link] = $.[Link](child, hProps,
[Link].x, [Link]);
[Link] = $.[Link](child, hProps,
[Link].x, [Link]);
};
[Link]([Link]); // Shift children
[Link]([Link], [Link], [Link],
function(){
if (restore) $.[Link](child, props2); //
Restore children
}); // Animate children
});
};
// Animate
[Link]([Link], { queue: false, duration: [Link], easing:
[Link], complete: function() {
if ([Link] === 0) {
[Link]('opacity', [Link]);
}
if(mode == 'hide') [Link](); // Hide
$.[Link](el, restore ? props : props1);
$.[Link](el); // Restore
if([Link]) [Link](this, arguments); // Callback
[Link]();
}});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props = ['position','top','bottom','left','right'];
// Set options
var mode = $.[Link](el, [Link] || 'effect'); // Set
Mode
var direction = [Link] || 'left'; // Default direction
var distance = [Link] || 20; // Default distance
var times = [Link] || 3; // Default # of times
var speed = [Link] || [Link] || 140; // Default speed
per shake
// Adjust
$.[Link](el, props); [Link](); // Save & Show
$.[Link](el); // Create Wrapper
var ref = (direction == 'up' || direction == 'down') ? 'top' : 'left';
var motion = (direction == 'up' || direction == 'left') ? 'pos' :
'neg';
// Animation
var animation = {}, animation1 = {}, animation2 = {};
animation[ref] = (motion == 'pos' ? '-=' : '+=') + distance;
animation1[ref] = (motion == 'pos' ? '+=' : '-=') + distance * 2;
animation2[ref] = (motion == 'pos' ? '-=' : '+=') + distance * 2;
// Animate
[Link](animation, speed, [Link]);
for (var i = 1; i < times; i++) { // Shakes
[Link](animation1, speed,
[Link]).animate(animation2, speed, [Link]);
};
[Link](animation1, speed, [Link]).
animate(animation, speed / 2, [Link], function(){ // Last
shake
$.[Link](el, props); $.[Link](el); //
Restore
if([Link]) [Link](this, arguments); // Callback
});
[Link]('fx', function() { [Link](); });
[Link]();
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
// Create element
var el = $(this), props = ['position','top','bottom','left','right'];
// Set options
var mode = $.[Link](el, [Link] || 'show'); // Set Mode
var direction = [Link] || 'left'; // Default Direction
// Adjust
$.[Link](el, props); [Link](); // Save & Show
$.[Link](el).css({overflow:'hidden'}); // Create Wrapper
var ref = (direction == 'up' || direction == 'down') ? 'top' : 'left';
var motion = (direction == 'up' || direction == 'left') ? 'pos' :
'neg';
var distance = [Link] || (ref == 'top' ?
[Link]( true ) : [Link]( true ));
if (mode == 'show') [Link](ref, motion == 'pos' ? (isNaN(distance) ?
"-" + distance : -distance) : distance); // Shift
// Animation
var animation = {};
animation[ref] = (mode == 'show' ? (motion == 'pos' ? '+=' : '-=') :
(motion == 'pos' ? '-=' : '+=')) + distance;
// Animate
[Link](animation, { queue: false, duration: [Link], easing:
[Link], complete: function() {
if(mode == 'hide') [Link](); // Hide
$.[Link](el, props); $.[Link](el); //
Restore
if([Link]) [Link](this, arguments); // Callback
[Link]();
}});
});
};
})(jQuery);
(function( $, undefined ) {
$.[Link] = function(o) {
return [Link](function() {
var elem = $(this),
target = $([Link]),
endPosition = [Link](),
animation = {
top: [Link],
left: [Link],
height: [Link](),
width: [Link]()
},
startPosition = [Link](),
transfer = $('<div class="ui-effects-transfer"></div>')
.appendTo([Link])
.addClass([Link])
.css({
top: [Link],
left: [Link],
height: [Link](),
width: [Link](),
position: 'absolute'
})
.animate(animation, [Link], [Link],
function() {
[Link]();
([Link] && [Link](elem[0], arguments));
[Link]();
});
});
};
})(jQuery);
(function( $, undefined ) {
$.widget( "[Link]", {
options: {
active: 0,
animated: "slide",
autoHeight: true,
clearStyle: false,
collapsible: false,
event: "click",
fillSpace: false,
header: "> li > :first-child,> :not(li):even",
icons: {
header: "ui-icon-triangle-1-e",
headerSelected: "ui-icon-triangle-1-s"
},
navigation: false,
navigationFilter: function() {
return [Link]() === [Link]();
}
},
_create: function() {
var self = this,
options = [Link];
[Link] = 0;
[Link]
.addClass( "ui-accordion ui-widget ui-helper-reset" )
// in lack of child-selectors in CSS
// we need to mark top-LIs in a UL-accordion for some IE-fix
.children( "li" )
.addClass( "ui-accordion-li-fix" );
[Link]()
.addClass( "ui-accordion-content ui-helper-reset ui-widget-
content ui-corner-bottom" );
if ( [Link] ) {
var current =
[Link]( "a" ).filter( [Link] ).eq( 0 );
if ( [Link] ) {
var header = [Link]( ".ui-accordion-header" );
if ( [Link] ) {
// anchor within header
[Link] = header;
} else {
// anchor within content
[Link] = [Link]( ".ui-accordion-
content" ).prev();
}
}
}
self._createIcons();
[Link]();
// ARIA
[Link]( "role", "tablist" );
[Link]
.attr( "role", "tab" )
.bind( "[Link]", function( event ) {
return self._keydown( event );
})
.next()
.attr( "role", "tabpanel" );
[Link]
.not( [Link] || "" )
.attr({
"aria-expanded": "false",
"aria-selected": "false",
tabIndex: -1
})
.next()
.hide();
if ( [Link] ) {
[Link]( [Link](" ").join(".accordion ") +
".accordion", function(event) {
self._clickHandler.call( self, event, this );
[Link]();
});
}
},
_createIcons: function() {
var options = [Link];
if ( [Link] ) {
$( "<span></span>" )
.addClass( "ui-icon " + [Link] )
.prependTo( [Link] );
[Link]( ".ui-icon" )
.toggleClass([Link])
.toggleClass([Link]);
[Link]( "ui-accordion-icons" );
}
},
_destroyIcons: function() {
[Link]( ".ui-icon" ).remove();
[Link]( "ui-accordion-icons" );
},
destroy: function() {
var options = [Link];
[Link]
.removeClass( "ui-accordion ui-widget ui-helper-reset" )
.removeAttr( "role" );
[Link]
.unbind( ".accordion" )
.removeClass( "ui-accordion-header ui-accordion-disabled ui-
helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-
corner-top" )
.removeAttr( "role" )
.removeAttr( "aria-expanded" )
.removeAttr( "aria-selected" )
.removeAttr( "tabIndex" );
if ( key == "active" ) {
[Link]( value );
}
if ( key == "icons" ) {
this._destroyIcons();
if ( value ) {
this._createIcons();
}
}
// #5332 - opacity doesn't cascade to positioned elements in IE
// so we need to add the disabled class to the headers and panels
if ( key == "disabled" ) {
[Link]([Link]())
[ value ? "addClass" : "removeClass" ](
"ui-accordion-disabled ui-state-disabled" );
}
},
_keydown: function( event ) {
if ( [Link] || [Link] || [Link] ) {
return;
}
switch ( [Link] ) {
case [Link]:
case [Link]:
toFocus = [Link][ ( currentIndex + 1 ) % length ];
break;
case [Link]:
case [Link]:
toFocus = [Link][ ( currentIndex - 1 + length ) %
length ];
break;
case [Link]:
case [Link]:
this._clickHandler( { target: [Link] },
[Link] );
[Link]();
}
if ( toFocus ) {
$( [Link] ).attr( "tabIndex", -1 );
$( toFocus ).attr( "tabIndex", 0 );
[Link]();
return false;
}
return true;
},
resize: function() {
var options = [Link],
maxHeight;
if ( [Link] ) {
if ( $.[Link] ) {
var defOverflow = [Link]().css( "overflow" );
[Link]().css( "overflow", "hidden");
}
maxHeight = [Link]().height();
if ($.[Link]) {
[Link]().css( "overflow", defOverflow );
}
[Link](function() {
maxHeight -= $( this ).outerHeight( true );
});
[Link]()
.each(function() {
$( this ).height( [Link]( 0, maxHeight -
$( this ).innerHeight() + $
( this ).height() ) );
})
.css( "overflow", "auto" );
} else if ( [Link] ) {
maxHeight = 0;
[Link]()
.each(function() {
maxHeight = [Link]( maxHeight, $( this ).height( ""
).height() );
})
.height( maxHeight );
}
return this;
},
return this;
},
// switch classes
active
.removeClass( "ui-state-active ui-corner-top" )
.addClass( "ui-state-default ui-corner-all" )
.children( ".ui-icon" )
.removeClass( [Link] )
.addClass( [Link] );
if ( !clickedIsActive ) {
clicked
.removeClass( "ui-state-default ui-corner-all" )
.addClass( "ui-state-active ui-corner-top" )
.children( ".ui-icon" )
.removeClass( [Link] )
.addClass( [Link] );
clicked
.next()
.addClass( "ui-accordion-content-active" );
}
return;
},
[Link] = toShow;
[Link] = toHide;
[Link] = data;
if ( [Link] ) {
var animOptions = {};
if ( ![Link] ) {
[Link] = [Link];
}
if ( ![Link] ) {
[Link] = [Link];
}
complete( true );
}
// TODO assert that the blur and focus triggers are really necessary,
remove otherwise
[Link]()
.attr({
"aria-expanded": "false",
"aria-selected": "false",
tabIndex: -1
})
.blur();
[Link]()
.attr({
"aria-expanded": "true",
"aria-selected": "true",
tabIndex: 0
})
.focus();
},
if ( [Link] ) {
[Link]( [Link] ).css({
height: "",
overflow: ""
});
}
// other classes are removed before the animation; this one needs to
stay until completed
[Link]( "ui-accordion-content-active" );
// Work around for rendering bug in IE (#5421)
if ( [Link] ) {
[Link]()[0].className = [Link]()
[0].className;
}
$.extend( $.[Link], {
version: "1.8.24",
animations: {
slide: function( options, additions ) {
options = $.extend({
easing: "swing",
duration: 300
}, options, additions );
if ( ![Link]() ) {
[Link]({
height: "show",
paddingTop: "show",
paddingBottom: "show"
}, options );
return;
}
if ( ![Link]() ) {
[Link]({
height: "hide",
paddingTop: "hide",
paddingBottom: "hide"
}, options );
return;
}
var overflow = [Link]( "overflow" ),
percentDone = 0,
showProps = {},
hideProps = {},
fxAttrs = [ "height", "paddingTop", "paddingBottom" ],
originalWidth;
// fix width before calculating height of hidden element
var s = [Link];
originalWidth = s[0].[Link];
[Link]( [Link]().width()
- parseFloat( [Link]( "paddingLeft" ) )
- parseFloat( [Link]( "paddingRight" ) )
- ( parseFloat( [Link]( "borderLeftWidth" ) ) || 0 )
- ( parseFloat( [Link]( "borderRightWidth" ) ) || 0 ) );
})( jQuery );
(function( $, undefined ) {
$.widget( "[Link]", {
options: {
appendTo: "body",
autoFocus: false,
delay: 300,
minLength: 1,
position: {
my: "left top",
at: "left bottom",
collision: "none"
},
source: null
},
pending: 0,
_create: function() {
var self = this,
doc = [Link][ 0 ].ownerDocument,
suppressKeyPress;
[Link] = [Link]( "textarea" );
[Link]
.addClass( "ui-autocomplete-input" )
.attr( "autocomplete", "off" )
// TODO verify these actually work as intended
.attr({
role: "textbox",
"aria-autocomplete": "list",
"aria-haspopup": "true"
})
.bind( "[Link]", function( event ) {
if ( [Link] ||
[Link]( "readOnly" ) ) {
return;
}
suppressKeyPress = false;
var keyCode = $.[Link];
switch( [Link] ) {
case keyCode.PAGE_UP:
self._move( "previousPage", event );
break;
case keyCode.PAGE_DOWN:
self._move( "nextPage", event );
break;
case [Link]:
self._keyEvent( "previous", event );
break;
case [Link]:
self._keyEvent( "next", event );
break;
case [Link]:
case keyCode.NUMPAD_ENTER:
// when menu is open and has focus
if ( [Link] ) {
// #6055 - Opera still allows the keypress to
occur
// which causes forms to submit
suppressKeyPress = true;
[Link]();
}
//passthrough - ENTER and TAB both select the current
element
case [Link]:
if ( ![Link] ) {
return;
}
[Link]( event );
break;
case [Link]:
[Link]( [Link] );
[Link]( event );
break;
default:
// keypress is triggered before the input value is
changed
clearTimeout( [Link] );
[Link] = setTimeout(function() {
// only search if the value has changed
if ( [Link] != [Link]() ) {
[Link] = null;
[Link]( null, event );
}
}, [Link] );
break;
}
})
.bind( "[Link]", function( event ) {
if ( suppressKeyPress ) {
suppressKeyPress = false;
[Link]();
}
})
.bind( "[Link]", function() {
if ( [Link] ) {
return;
}
[Link] = null;
[Link] = [Link]();
})
.bind( "[Link]", function( event ) {
if ( [Link] ) {
return;
}
clearTimeout( [Link] );
// clicks on the menu (or a button to trigger a search)
will cause a blur event
[Link] = setTimeout(function() {
[Link]( event );
self._change( event );
}, 150 );
});
this._initSource();
[Link] = $( "<ul></ul>" )
.addClass( "ui-autocomplete" )
.appendTo( $( [Link] || "body", doc )[0] )
// prevent the close-on-blur in case of a "slow" click on the
menu (long mousedown)
.mousedown(function( event ) {
// clicking on the scrollbar causes focus to shift to the
body
// but we can't detect a mouseup or a click immediately
afterward
// so we have to track the next mousedown and close the
menu if
// the user clicks somewhere outside of the autocomplete
var menuElement = [Link][ 0 ];
if ( !$( [Link] ).closest( ".ui-menu-item" ).length )
{
setTimeout(function() {
$( document ).one( 'mousedown', function( event
) {
if ( [Link] !== [Link][ 0 ]
&&
[Link] !== menuElement &&
!$.[Link]( menuElement,
[Link] ) ) {
[Link]();
}
});
}, 1 );
}
[Link]( event );
[Link] = item;
},
blur: function( event, ui ) {
// don't set the value of the text field if it's
already correct
// this prevents moving the cursor unnecessarily
if ( [Link](":visible") &&
( [Link]() !== [Link] ) ) {
[Link]( [Link] );
}
}
})
.zIndex( [Link]() + 1 )
// workaround for jQuery bug #5781
[Link]
.css({ top: 0, left: 0 })
.hide()
.data( "menu" );
if ( $.[Link] ) {
[Link]();
}
// turning off autocomplete prevents the browser from remembering the
// value when navigating through history, so we re-enable autocomplete
// if the page is unloaded before the widget is destroyed. #7790
[Link] = function() {
[Link]( "autocomplete" );
};
$( window ).bind( "beforeunload", [Link] );
},
destroy: function() {
[Link]
.removeClass( "ui-autocomplete-input" )
.removeAttr( "autocomplete" )
.removeAttr( "role" )
.removeAttr( "aria-autocomplete" )
.removeAttr( "aria-haspopup" );
[Link]();
$( window ).unbind( "beforeunload", [Link] );
$.[Link]( this );
},
_initSource: function() {
var self = this,
array,
url;
if ( $.isArray([Link]) ) {
array = [Link];
[Link] = function( request, response ) {
response( $.[Link](array, [Link]) );
};
} else if ( typeof [Link] === "string" ) {
url = [Link];
[Link] = function( request, response ) {
if ( [Link] ) {
[Link]();
}
[Link] = $.ajax({
url: url,
data: request,
dataType: "json",
success: function( data, status ) {
response( data );
},
error: function() {
response( [] );
}
});
};
} else {
[Link] = [Link];
}
},
// always save the actual value, not the one passed as an argument
[Link] = [Link]();
clearTimeout( [Link] );
if ( this._trigger( "search", event ) === false ) {
return;
}
_response: function() {
var that = this,
index = ++requestIndex;
[Link]--;
if ( ![Link] ) {
[Link]( "ui-autocomplete-loading" );
}
};
},
if ( [Link] ) {
[Link]( new $.Event("mouseover") );
}
},
_resizeMenu: function() {
var ul = [Link];
[Link]( [Link](
// Firefox wraps long text (possibly a rounding bug)
// so we add 1px to avoid the wrapping (#7513)
[Link]( "" ).outerWidth() + 1,
[Link]()
) );
},
widget: function() {
return [Link];
},
_keyEvent: function( keyEvent, event ) {
if ( ![Link] || [Link]( ":visible" ) ) {
this._move( keyEvent, event );
$.extend( $.[Link], {
escapeRegex: function( value ) {
return [Link](/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
},
filter: function(array, term) {
var matcher = new RegExp( $.[Link](term), "i" );
return $.grep( array, function(value) {
return [Link]( [Link] || [Link] || value );
});
}
});
}( jQuery ));
/*
* jQuery UI Menu (not officially released)
*
* This widget isn't yet finished and the API is subject to change. We plan to
finish
* it for the next release. You're welcome to give it a try anyway and give us
feedback,
* as long as you're okay with migrating your code later on. We can help with that,
too.
*
* Copyright 2010, [Link] ([Link]
* Licensed under the MIT license.
* [Link]
*
* [Link]
*
* Depends:
* [Link]
* [Link]
*/
(function($) {
$.widget("[Link]", {
_create: function() {
var self = this;
[Link]
.addClass("ui-menu ui-widget ui-widget-content ui-corner-all")
.attr({
role: "listbox",
"aria-activedescendant": "ui-active-menuitem"
})
.click(function( event ) {
if ( !$( [Link] ).closest( ".ui-menu-item a" ).length
) {
return;
}
// temporary
[Link]();
[Link]( event );
});
[Link]();
},
refresh: function() {
var self = this;
[Link]("a")
.addClass("ui-corner-all")
.attr("tabindex", -1)
// mouseenter doesn't work with event delegation
.mouseenter(function( event ) {
[Link]( event, $(this).parent() );
})
.mouseleave(function() {
[Link]();
});
},
deactivate: function() {
if (![Link]) { return; }
[Link]("a")
.removeClass("ui-state-hover")
.removeAttr("id");
this._trigger("blur");
[Link] = null;
},
next: function(event) {
[Link]("next", ".ui-menu-item:first", event);
},
previous: function(event) {
[Link]("prev", ".ui-menu-item:last", event);
},
first: function() {
return [Link] && .length;
},
last: function() {
return [Link] && .length;
},
hasScroll: function() {
return [Link]() < [Link][ $.[Link] ? "prop" :
"attr" ]("scrollHeight");
},
}(jQuery));
(function( $, undefined ) {
$.widget( "[Link]", {
options: {
disabled: null,
text: true,
label: null,
icons: {
primary: null,
secondary: null
}
},
_create: function() {
[Link]( "form" )
.unbind( "[Link]" )
.bind( "[Link]", formResetHandler );
if ( typeof [Link] !== "boolean" ) {
[Link] = !;
} else {
[Link]( "disabled", [Link] );
}
this._determineButtonType();
[Link] = !;
[Link]
.addClass( baseClasses )
.attr( "role", "button" )
.bind( "[Link]", function() {
if ( [Link] ) {
return;
}
$( this ).addClass( "ui-state-hover" );
if ( this === lastActive ) {
$( this ).addClass( "ui-state-active" );
}
})
.bind( "[Link]", function() {
if ( [Link] ) {
return;
}
$( this ).removeClass( hoverClass );
})
.bind( "[Link]", function( event ) {
if ( [Link] ) {
[Link]();
[Link]();
}
});
[Link]
.bind( "[Link]", function() {
// no need to check disabled, focus won't be triggered
anyway
[Link]( focusClass );
})
.bind( "[Link]", function() {
[Link]( focusClass );
});
if ( toggleButton ) {
[Link]( "[Link]", function() {
if ( clickDragged ) {
return;
}
[Link]();
});
// if mouse moves between mousedown and mouseup (drag) set
clickDragged flag
// prevents issue where button state changes but checkbox/radio
checked state
// does not in Firefox (see ticket #6970)
[Link]
.bind( "[Link]", function( event ) {
if ( [Link] ) {
return;
}
clickDragged = false;
startXPos = [Link];
startYPos = [Link];
})
.bind( "[Link]", function( event ) {
if ( [Link] ) {
return;
}
if ( startXPos !== [Link] || startYPos !==
[Link] ) {
clickDragged = true;
}
});
}
if ( [Link]("a") ) {
[Link](function(event) {
if ( [Link] === $.[Link] ) {
// TODO pass through original event correctly
(just as 2nd argument doesn't work)
$( this ).click();
}
});
}
}
// TODO: pull out $.Widget's handling for the disabled option into
// $.[Link]._setOptionDisabled so it's easy to proxy and can
// be overridden by individual plugins
this._setOption( "disabled", [Link] );
this._resetButton();
},
_determineButtonType: function() {
if ( [Link](":checkbox") ) {
[Link] = "checkbox";
} else if ( [Link](":radio") ) {
[Link] = "radio";
} else if ( [Link]("input") ) {
[Link] = "input";
} else {
[Link] = "button";
}
widget: function() {
return [Link];
},
destroy: function() {
[Link]
.removeClass( "ui-helper-hidden-accessible" );
[Link]
.removeClass( baseClasses + " " + stateClasses + " " +
typeClasses )
.removeAttr( "role" )
.removeAttr( "aria-pressed" )
.html( [Link](".ui-button-text").html() );
if ( ![Link] ) {
[Link]( "title" );
}
$.[Link]( this );
},
_resetButton: function() {
if ( [Link] === "input" ) {
if ( [Link] ) {
[Link]( [Link] );
}
return;
}
var buttonElement = [Link]( typeClasses ),
buttonText = $( "<span></span>", [Link][0].ownerDocument )
.addClass( "ui-button-text" )
.html( [Link] )
.appendTo( [Link]() )
.text(),
icons = [Link],
multipleIcons = [Link] && [Link],
buttonClasses = [];
if ( [Link] || [Link] ) {
if ( [Link] ) {
[Link]( "ui-button-text-icon" + ( multipleIcons
? "s" : ( [Link] ? "-primary" : "-secondary" ) ) );
}
if ( [Link] ) {
[Link]( "<span class='ui-button-icon-primary
ui-icon " + [Link] + "'></span>" );
}
if ( [Link] ) {
[Link]( "<span class='ui-button-icon-
secondary ui-icon " + [Link] + "'></span>" );
}
if ( ![Link] ) {
[Link]( multipleIcons ? "ui-button-icons-
only" : "ui-button-icon-only" );
if ( ![Link] ) {
[Link]( "title", buttonText );
}
}
} else {
[Link]( "ui-button-text-only" );
}
[Link]( [Link]( " " ) );
}
});
$.widget( "[Link]", {
options: {
items: ":button, :submit, :reset, :checkbox, :radio, a, :data(button)"
},
_create: function() {
[Link]( "ui-buttonset" );
},
_init: function() {
[Link]();
},
refresh: function() {
var rtl = [Link]( "direction" ) === "rtl";
destroy: function() {
[Link]( "ui-buttonset" );
[Link]
.map(function() {
return $( this ).button( "widget" )[ 0 ];
})
.removeClass( "ui-corner-left ui-corner-right" )
.end()
.button( "destroy" );
$.[Link]( this );
}
});
}( jQuery ) );
(function( $, undefined ) {
function Datepicker() {
[Link] = false; // Change this to true to start debugging
this._curInst = null; // The current instance in use
this._keyEvent = false; // If the last event was a key event
this._disabledInputs = []; // List of date picker inputs that have been
disabled
this._datepickerShowing = false; // True if the popup picker is showing ,
false if not
this._inDialog = false; // True if showing within a "dialog", false if not
this._mainDivId = 'ui-datepicker-div'; // The ID of the main datepicker
division
this._inlineClass = 'ui-datepicker-inline'; // The name of the inline marker
class
this._appendClass = 'ui-datepicker-append'; // The name of the append marker
class
this._triggerClass = 'ui-datepicker-trigger'; // The name of the trigger
marker class
this._dialogClass = 'ui-datepicker-dialog'; // The name of the dialog marker
class
this._disableClass = 'ui-datepicker-disabled'; // The name of the disabled
covering marker class
this._unselectableClass = 'ui-datepicker-unselectable'; // The name of the
unselectable cell marker class
this._currentClass = 'ui-datepicker-current-day'; // The name of the current
day marker class
this._dayOverClass = 'ui-datepicker-days-cell-over'; // The name of the day
hover marker class
[Link] = []; // Available regional settings, indexed by language code
[Link][''] = { // Default regional settings
closeText: 'Done', // Display text for close link
prevText: 'Prev', // Display text for previous month link
nextText: 'Next', // Display text for next month link
currentText: 'Today', // Display text for current month link
monthNames: ['January','February','March','April','May','June',
'July','August','September','October','November','December'], //
Names of months for drop-down and formatting
monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul',
'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], // For formatting
dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday',
'Friday', 'Saturday'], // For formatting
dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'], //
For formatting
dayNamesMin: ['Su','Mo','Tu','We','Th','Fr','Sa'], // Column headings
for days starting at Sunday
weekHeader: 'Wk', // Column header for week of the year
dateFormat: 'mm/dd/yy', // See format options on parseDate
firstDay: 0, // The first day of the week, Sun = 0, Mon = 1, ...
isRTL: false, // True if right-to-left language, false if left-to-right
showMonthAfterYear: false, // True if the year select precedes month,
false for month then year
yearSuffix: '' // Additional text to append to the year in the month
headers
};
this._defaults = { // Global defaults for all the date picker instances
showOn: 'focus', // 'focus' for popup on focus,
// 'button' for trigger button, or 'both' for either
showAnim: 'fadeIn', // Name of jQuery animation for popup
showOptions: {}, // Options for enhanced animations
defaultDate: null, // Used when field is blank: actual date,
// +/-number for offset from today, null for today
appendText: '', // Display text following the input box, e.g. showing
the format
buttonText: '...', // Text for trigger button
buttonImage: '', // URL for trigger button image
buttonImageOnly: false, // True if the image appears alone, false if it
appears on a button
hideIfNoPrevNext: false, // True to hide next/previous month links
// if not applicable, false to just disable them
navigationAsDateFormat: false, // True if date formatting applied to
prev/today/next links
gotoCurrent: false, // True if today link goes back to current
selection instead
changeMonth: false, // True if month can be selected directly, false if
only prev/next
changeYear: false, // True if year can be selected directly, false if
only prev/next
yearRange: 'c-10:c+10', // Range of years to display in drop-down,
// either relative to today's year (-nn:+nn), relative to
currently displayed year
// (c-nn:c+nn), absolute (nnnn:nnnn), or a combination of the
above (nnnn:-n)
showOtherMonths: false, // True to show dates in other months, false to
leave blank
selectOtherMonths: false, // True to allow selection of dates in other
months, false for unselectable
showWeek: false, // True to show week of the year, false to not show it
calculateWeek: this.iso8601Week, // How to calculate the week of the
year,
// takes a Date and returns the number of the week for it
shortYearCutoff: '+10', // Short year values < this are in the current
century,
// > this are in the previous century,
// string value starting with '+' for current year + value
minDate: null, // The earliest selectable date, or null for no limit
maxDate: null, // The latest selectable date, or null for no limit
duration: 'fast', // Duration of display/closure
beforeShowDay: null, // Function that takes a date and returns an array
with
// [0] = true if selectable, false if not, [1] = custom CSS class
name(s) or '',
// [2] = cell title (optional), e.g. $.[Link]
beforeShow: null, // Function that takes an input field and
// returns a set of custom settings for the date picker
onSelect: null, // Define a callback function when a date is selected
onChangeMonthYear: null, // Define a callback function when the month
or year is changed
onClose: null, // Define a callback function when the datepicker is
closed
numberOfMonths: 1, // Number of months to show at a time
showCurrentAtPos: 0, // The position in multipe months at which to show
the current month (starting at 0)
stepMonths: 1, // Number of months to step back/forward
stepBigMonths: 12, // Number of months to step back/forward for the big
links
altField: '', // Selector for an alternate field to store selected
dates into
altFormat: '', // The date format to use for the alternate field
constrainInput: true, // The input is constrained by the current date
format
showButtonPanel: false, // True to show button panel, false to not show
it
autoSize: false, // True to size the input for the date format, false
to leave as is
disabled: false // The initial disabled state
};
$.extend(this._defaults, [Link]['']);
[Link] = bindHover($('<div id="' + this._mainDivId + '" class="ui-
datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>'));
}
$.extend([Link], {
/* Class name added to elements to indicate already configured with a date
picker. */
markerClassName: 'hasDatepicker',
/* Override the default settings for all instances of the date picker.
@param settings object - the new settings to use as defaults (anonymous
object)
@return the manager object */
setDefaults: function(settings) {
extendRemove(this._defaults, settings || {});
return this;
},
/* Handle keystrokes. */
_doKeyDown: function(event) {
var inst = $.datepicker._getInst([Link]);
var handled = true;
var isRTL = [Link]('.ui-datepicker-rtl');
inst._keyEvent = true;
if ($.datepicker._datepickerShowing)
switch ([Link]) {
case 9: $.datepicker._hideDatepicker();
handled = false;
break; // hide on tab out
case 13: var sel = $('td.' + $.datepicker._dayOverClass +
':not(.' +
$.datepicker._currentClass +
')', [Link]);
if (sel[0])
$.datepicker._selectDay([Link],
[Link], [Link], sel[0]);
var onSelect = $.datepicker._get(inst,
'onSelect');
if (onSelect) {
var dateStr =
$.datepicker._formatDate(inst);
return offset;
},
/* Generate the HTML for the current state of the date picker. */
_generateHTML: function(inst) {
var today = new Date();
today = this._daylightSavingAdjust(
new Date([Link](), [Link](),
[Link]())); // clear time
var isRTL = this._get(inst, 'isRTL');
var showButtonPanel = this._get(inst, 'showButtonPanel');
var hideIfNoPrevNext = this._get(inst, 'hideIfNoPrevNext');
var navigationAsDateFormat = this._get(inst, 'navigationAsDateFormat');
var numMonths = this._getNumberOfMonths(inst);
var showCurrentAtPos = this._get(inst, 'showCurrentAtPos');
var stepMonths = this._get(inst, 'stepMonths');
var isMultiMonth = (numMonths[0] != 1 || numMonths[1] != 1);
var currentDate = this._daylightSavingAdjust((![Link] ? new
Date(9999, 9, 9) :
new Date([Link], [Link], [Link])));
var minDate = this._getMinMaxDate(inst, 'min');
var maxDate = this._getMinMaxDate(inst, 'max');
var drawMonth = [Link] - showCurrentAtPos;
var drawYear = [Link];
if (drawMonth < 0) {
drawMonth += 12;
drawYear--;
}
if (maxDate) {
var maxDraw = this._daylightSavingAdjust(new
Date([Link](),
[Link]() - (numMonths[0] * numMonths[1]) + 1,
[Link]()));
maxDraw = (minDate && maxDraw < minDate ? minDate : maxDraw);
while (this._daylightSavingAdjust(new Date(drawYear, drawMonth,
1)) > maxDraw) {
drawMonth--;
if (drawMonth < 0) {
drawMonth = 11;
drawYear--;
}
}
}
[Link] = drawMonth;
[Link] = drawYear;
var prevText = this._get(inst, 'prevText');
prevText = (!navigationAsDateFormat ? prevText :
[Link](prevText,
this._daylightSavingAdjust(new Date(drawYear, drawMonth -
stepMonths, 1)),
this._getFormatConfig(inst)));
var prev = (this._canAdjustMonth(inst, -1, drawYear, drawMonth) ?
'<a class="ui-datepicker-prev ui-corner-all" data-handler="prev"
data-event="click"' +
' title="' + prevText + '"><span class="ui-icon ui-icon-circle-
triangle-' + ( isRTL ? 'e' : 'w') + '">' + prevText + '</span></a>' :
(hideIfNoPrevNext ? '' : '<a class="ui-datepicker-prev ui-corner-
all ui-state-disabled" title="'+ prevText +'"><span class="ui-icon ui-icon-circle-
triangle-' + ( isRTL ? 'e' : 'w') + '">' + prevText + '</span></a>'));
var nextText = this._get(inst, 'nextText');
nextText = (!navigationAsDateFormat ? nextText :
[Link](nextText,
this._daylightSavingAdjust(new Date(drawYear, drawMonth +
stepMonths, 1)),
this._getFormatConfig(inst)));
var next = (this._canAdjustMonth(inst, +1, drawYear, drawMonth) ?
'<a class="ui-datepicker-next ui-corner-all" data-handler="next"
data-event="click"' +
' title="' + nextText + '"><span class="ui-icon ui-icon-circle-
triangle-' + ( isRTL ? 'w' : 'e') + '">' + nextText + '</span></a>' :
(hideIfNoPrevNext ? '' : '<a class="ui-datepicker-next ui-corner-
all ui-state-disabled" title="'+ nextText + '"><span class="ui-icon ui-icon-circle-
triangle-' + ( isRTL ? 'w' : 'e') + '">' + nextText + '</span></a>'));
var currentText = this._get(inst, 'currentText');
var gotoDate = (this._get(inst, 'gotoCurrent') && [Link] ?
currentDate : today);
currentText = (!navigationAsDateFormat ? currentText :
[Link](currentText, gotoDate,
this._getFormatConfig(inst)));
var controls = (![Link] ? '<button type="button" class="ui-
datepicker-close ui-state-default ui-priority-primary ui-corner-all" data-
handler="hide" data-event="click">' +
this._get(inst, 'closeText') + '</button>' : '');
var buttonPanel = (showButtonPanel) ? '<div class="ui-datepicker-
buttonpane ui-widget-content">' + (isRTL ? controls : '') +
(this._isInRange(inst, gotoDate) ? '<button type="button"
class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all"
data-handler="today" data-event="click"' +
'>' + currentText + '</button>' : '') + (isRTL ? '' : controls) +
'</div>' : '';
var firstDay = parseInt(this._get(inst, 'firstDay'),10);
firstDay = (isNaN(firstDay) ? 0 : firstDay);
var showWeek = this._get(inst, 'showWeek');
var dayNames = this._get(inst, 'dayNames');
var dayNamesShort = this._get(inst, 'dayNamesShort');
var dayNamesMin = this._get(inst, 'dayNamesMin');
var monthNames = this._get(inst, 'monthNames');
var monthNamesShort = this._get(inst, 'monthNamesShort');
var beforeShowDay = this._get(inst, 'beforeShowDay');
var showOtherMonths = this._get(inst, 'showOtherMonths');
var selectOtherMonths = this._get(inst, 'selectOtherMonths');
var calculateWeek = this._get(inst, 'calculateWeek') ||
this.iso8601Week;
var defaultDate = this._getDefaultDate(inst);
var html = '';
for (var row = 0; row < numMonths[0]; row++) {
var group = '';
[Link] = 4;
for (var col = 0; col < numMonths[1]; col++) {
var selectedDate = this._daylightSavingAdjust(new
Date(drawYear, drawMonth, [Link]));
var cornerClass = ' ui-corner-all';
var calender = '';
if (isMultiMonth) {
calender += '<div class="ui-datepicker-group';
if (numMonths[1] > 1)
switch (col) {
case 0: calender += ' ui-datepicker-
group-first';
cornerClass = ' ui-corner-' +
(isRTL ? 'right' : 'left'); break;
case numMonths[1]-1: calender += ' ui-
datepicker-group-last';
cornerClass = ' ui-corner-' +
(isRTL ? 'left' : 'right'); break;
default: calender += ' ui-datepicker-
group-middle'; cornerClass = ''; break;
}
calender += '">';
}
calender += '<div class="ui-datepicker-header ui-widget-
header ui-helper-clearfix' + cornerClass + '">' +
(/all|left/.test(cornerClass) && row == 0 ? (isRTL ?
next : prev) : '') +
(/all|right/.test(cornerClass) && row == 0 ? (isRTL ?
prev : next) : '') +
this._generateMonthYearHeader(inst, drawMonth,
drawYear, minDate, maxDate,
row > 0 || col > 0, monthNames, monthNamesShort) + //
draw month headers
'</div><table class="ui-datepicker-calendar"><thead>'
+
'<tr>';
var thead = (showWeek ? '<th class="ui-datepicker-week-
col">' + this._get(inst, 'weekHeader') + '</th>' : '');
for (var dow = 0; dow < 7; dow++) { // days of the week
var day = (dow + firstDay) % 7;
thead += '<th' + ((dow + firstDay + 6) % 7 >= 5 ? '
class="ui-datepicker-week-end"' : '') + '>' +
'<span title="' + dayNames[day] + '">' +
dayNamesMin[day] + '</span></th>';
}
calender += thead + '</tr></thead><tbody>';
var daysInMonth = this._getDaysInMonth(drawYear,
drawMonth);
if (drawYear == [Link] && drawMonth ==
[Link])
[Link] = [Link]([Link],
daysInMonth);
var leadDays = (this._getFirstDayOfMonth(drawYear,
drawMonth) - firstDay + 7) % 7;
var curRows = [Link]((leadDays + daysInMonth) / 7); //
calculate the number of rows to generate
var numRows = (isMultiMonth ? [Link] > curRows ?
[Link] : curRows : curRows); //If multiple months, use the higher number of
rows (see #7043)
[Link] = numRows;
var printDate = this._daylightSavingAdjust(new
Date(drawYear, drawMonth, 1 - leadDays));
for (var dRow = 0; dRow < numRows; dRow++) { // create date
picker rows
calender += '<tr>';
var tbody = (!showWeek ? '' : '<td class="ui-
datepicker-week-col">' +
this._get(inst, 'calculateWeek')(printDate) +
'</td>');
for (var dow = 0; dow < 7; dow++) { // create date
picker days
var daySettings = (beforeShowDay ?
[Link](([Link] ?
[Link][0] : null), [printDate]) : [true, '']);
var otherMonth = ([Link]() !=
drawMonth);
var unselectable = (otherMonth && !
selectOtherMonths) || !daySettings[0] ||
(minDate && printDate < minDate) ||
(maxDate && printDate > maxDate);
tbody += '<td class="' +
((dow + firstDay + 6) % 7 >= 5 ? ' ui-
datepicker-week-end' : '') + // highlight weekends
(otherMonth ? ' ui-datepicker-other-
month' : '') + // highlight days from other months
(([Link]() ==
[Link]() && drawMonth == [Link] && inst._keyEvent) || //
user pressed key
([Link]() ==
[Link]() && [Link]() == [Link]()) ?
// or defaultDate is current printedDate
and defaultDate is selectedDate
' ' + this._dayOverClass : '') + //
highlight selected day
(unselectable ? ' ' +
this._unselectableClass + ' ui-state-disabled': '') + // highlight unselectable
days
(otherMonth && !showOtherMonths ? '' : '
' + daySettings[1] + // highlight custom dates
([Link]() ==
[Link]() ? ' ' + this._currentClass : '') + // highlight selected day
([Link]() == [Link]() ?
' ui-datepicker-today' : '')) + '"' + // highlight today (if different)
((!otherMonth || showOtherMonths) &&
daySettings[2] ? ' title="' + daySettings[2] + '"' : '') + // cell title
(unselectable ? '' : ' data-
handler="selectDay" data-event="click" data-month="' + [Link]() + '"
data-year="' + [Link]() + '"') + '>' + // actions
(otherMonth && !showOtherMonths ?
' ' : // display for other months
(unselectable ? '<span class="ui-state-
default">' + [Link]() + '</span>' : '<a class="ui-state-default' +
([Link]() == [Link]() ?
' ui-state-highlight' : '') +
([Link]() ==
[Link]() ? ' ui-state-active' : '') + // highlight selected day
(otherMonth ? ' ui-priority-secondary' :
'') + // distinguish dates from other months
'" href="#">' + [Link]() +
'</a>')) + '</td>'; // display selectable date
[Link]([Link]() + 1);
printDate =
this._daylightSavingAdjust(printDate);
}
calender += tbody + '</tr>';
}
drawMonth++;
if (drawMonth > 11) {
drawMonth = 0;
drawYear++;
}
calender += '</tbody></table>' + (isMultiMonth ? '</div>' +
((numMonths[0] > 0 && col ==
numMonths[1]-1) ? '<div class="ui-datepicker-row-break"></div>' : '') : '');
group += calender;
}
html += group;
}
html += buttonPanel + ($.[Link] && parseInt($.[Link],10)
< 7 && ![Link] ?
'<iframe src="javascript:false;" class="ui-datepicker-cover"
frameborder="0"></iframe>' : '');
inst._keyEvent = false;
return html;
},
html += [Link];
[Link] = null;
}
}
html += this._get(inst, 'yearSuffix');
if (showMonthAfterYear)
html += (secondary || !(changeMonth && changeYear) ? ' ' :
'') + monthHtml;
html += '</div>'; // Close datepicker_header
return html;
},
/* Determine the current maximum date - ensure no time components are set. */
_getMinMaxDate: function(inst, minMax) {
return this._determineDate(inst, this._get(inst, minMax + 'Date'),
null);
},
/*
* Bind hover events for datepicker elements.
* Done via delegate so the binding only occurs once in the lifetime of the parent
div.
* Global instActive, set by _updateDatepicker allows the handlers to find their
way back to the active picker.
*/
function bindHover(dpDiv) {
var selector = 'button, .ui-datepicker-prev, .ui-datepicker-next, .ui-
datepicker-calendar td a';
return [Link]('mouseout', function(event) {
var elem = $( [Link] ).closest( selector );
if ( ![Link] ) {
return;
}
[Link]( "ui-state-hover ui-datepicker-prev-hover ui-
datepicker-next-hover" );
})
.bind('mouseover', function(event) {
var elem = $( [Link] ).closest( selector );
if ($.datepicker._isDisabledDatepicker( [Link] ?
[Link]()[0] : [Link][0]) ||
![Link] ) {
return;
}
[Link]('.ui-datepicker-
calendar').find('a').removeClass('ui-state-hover');
[Link]('ui-state-hover');
if ([Link]('ui-datepicker-prev')) [Link]('ui-
datepicker-prev-hover');
if ([Link]('ui-datepicker-next')) [Link]('ui-
datepicker-next-hover');
});
}
})(jQuery);
(function( $, undefined ) {
var uiDialogClasses =
'ui-dialog ' +
'ui-widget ' +
'ui-widget-content ' +
'ui-corner-all ',
sizeRelatedOptions = {
buttons: true,
height: true,
maxHeight: true,
maxWidth: true,
minHeight: true,
minWidth: true,
width: true
},
resizableRelatedOptions = {
maxHeight: true,
maxWidth: true,
minHeight: true,
minWidth: true
};
$.widget("[Link]", {
options: {
autoOpen: true,
buttons: {},
closeOnEscape: true,
closeText: 'close',
dialogClass: '',
draggable: true,
hide: null,
height: 'auto',
maxHeight: false,
maxWidth: false,
minHeight: 150,
minWidth: 150,
modal: false,
position: {
my: 'center',
at: 'center',
collision: 'fit',
// ensure that the titlebar is never outside the document
using: function(pos) {
var topOffset = $(this).css(pos).offset().top;
if (topOffset < 0) {
$(this).css('top', [Link] - topOffset);
}
}
},
resizable: true,
show: null,
stack: true,
title: '',
width: 300,
zIndex: 1000
},
_create: function() {
[Link] = [Link]('title');
// #5742 - .attr() might return a DOMElement
if ( typeof [Link] !== "string" ) {
[Link] = "";
}
[Link](event);
[Link]();
}
})
.attr({
role: 'dialog',
'aria-labelledby': titleId
})
.mousedown(function(event) {
[Link](false, event);
}),
uiDialogContent = [Link]
.show()
.removeAttr('title')
.addClass(
'ui-dialog-content ' +
'ui-widget-content')
.appendTo(uiDialog),
uiDialogTitlebarCloseText = ([Link] = $
('<span></span>'))
.addClass(
'ui-icon ' +
'ui-icon-closethick'
)
.text([Link])
.appendTo(uiDialogTitlebarClose),
uiDialogTitle = $('<span></span>')
.addClass('ui-dialog-title')
.attr('id', titleId)
.html(title)
.prependTo(uiDialogTitlebar);
[Link]("*").add(uiDialogTitlebar).disableSelection();
self._createButtons([Link]);
self._isOpen = false;
if ($.[Link]) {
[Link]();
}
},
_init: function() {
if ( [Link] ) {
[Link]();
}
},
destroy: function() {
var self = this;
if ([Link]) {
[Link]();
}
[Link]();
[Link]
.unbind('.dialog')
.removeData('dialog')
.removeClass('ui-dialog-content ui-widget-content')
.hide().appendTo('body');
[Link]();
if ([Link]) {
[Link]('title', [Link]);
}
return self;
},
widget: function() {
return [Link];
},
close: function(event) {
var self = this,
maxZ, thisZ;
if (false === self._trigger('beforeClose', event)) {
return;
}
if ([Link]) {
[Link]();
}
[Link]('[Link]-dialog');
self._isOpen = false;
if ([Link]) {
[Link]([Link], function() {
self._trigger('close', event);
});
} else {
[Link]();
self._trigger('close', event);
}
$.[Link]();
return self;
},
isOpen: function() {
return this._isOpen;
},
//Save and then restore scroll since Opera 9.5+ resets when parent z-
Index is changed.
// [Link]
saveScroll = { scrollTop: [Link](), scrollLeft:
[Link]() };
$.[Link] += 1;
[Link]('z-index', $.[Link]);
[Link](saveScroll);
self._trigger('focus', event);
return self;
},
open: function() {
if (this._isOpen) { return; }
// set focus to the first tabbable element in the content area or the
first button
// if there are no tabbable elements, set focus on the dialog itself
$([Link](':tabbable').get().concat(
[Link]('.ui-dialog-buttonpane :tabbable').get().concat(
[Link]()))).eq(0).focus();
self._isOpen = true;
self._trigger('open');
return self;
},
_createButtons: function(buttons) {
var self = this,
hasButtons = false,
uiDialogButtonPane = $('<div></div>')
.addClass(
'ui-dialog-buttonpane ' +
'ui-widget-content ' +
'ui-helper-clearfix'
),
uiButtonSet = $( "<div></div>" )
.addClass( "ui-dialog-buttonset" )
.appendTo( uiDialogButtonPane );
_makeDraggable: function() {
var self = this,
options = [Link],
doc = $(document),
heightBeforeDrag;
function filteredUi(ui) {
return {
position: [Link],
offset: [Link]
};
}
[Link]({
cancel: '.ui-dialog-content, .ui-dialog-titlebar-close',
handle: '.ui-dialog-titlebar',
containment: 'document',
start: function(event, ui) {
heightBeforeDrag = [Link] === "auto" ? "auto" : $
(this).height();
$(this).height($(this).height()).addClass("ui-dialog-
dragging");
self._trigger('dragStart', event, filteredUi(ui));
},
drag: function(event, ui) {
self._trigger('drag', event, filteredUi(ui));
},
stop: function(event, ui) {
[Link] = [[Link] - [Link](),
[Link] - [Link]()];
$(this).removeClass("ui-dialog-
dragging").height(heightBeforeDrag);
self._trigger('dragStop', event, filteredUi(ui));
$.[Link]();
}
});
},
_makeResizable: function(handles) {
handles = (handles === undefined ? [Link] : handles);
var self = this,
options = [Link],
// .ui-resizable has position: relative defined in the stylesheet
// but dialogs have to use absolute or fixed positioning
position = [Link]('position'),
resizeHandles = (typeof handles === 'string' ?
handles :
'n,e,s,w,se,sw,ne,nw'
);
function filteredUi(ui) {
return {
originalPosition: [Link],
originalSize: [Link],
position: [Link],
size: [Link]
};
}
[Link]({
cancel: '.ui-dialog-content',
containment: 'document',
alsoResize: [Link],
maxWidth: [Link],
maxHeight: [Link],
minWidth: [Link],
minHeight: self._minHeight(),
handles: resizeHandles,
start: function(event, ui) {
$(this).addClass("ui-dialog-resizing");
self._trigger('resizeStart', event, filteredUi(ui));
},
resize: function(event, ui) {
self._trigger('resize', event, filteredUi(ui));
},
stop: function(event, ui) {
$(this).removeClass("ui-dialog-resizing");
[Link] = $(this).height();
[Link] = $(this).width();
self._trigger('resizeStop', event, filteredUi(ui));
$.[Link]();
}
})
.css('position', position)
.find('.ui-resizable-se').addClass('ui-icon ui-icon-grip-diagonal-se');
},
_minHeight: function() {
var options = [Link];
_position: function(position) {
var myAt = [],
offset = [0, 0],
isVisible;
if (position) {
// deep extending converts arrays to objects in jQuery <=
1.3.2 :-(
// if (typeof position == 'string' || $.isArray(position)) {
// myAt = $.isArray(position) ? position : [Link]('
');
position = {
my: [Link](" "),
at: [Link](" "),
offset: [Link](" ")
};
}
// need to show the dialog to get the actual offset in the position
plugin
isVisible = [Link](':visible');
if (!isVisible) {
[Link]();
}
[Link]
// workaround for jQuery bug #5781
[Link]
.css({ top: 0, left: 0 })
.position($.extend({ of: window }, position));
if (!isVisible) {
[Link]();
}
},
if ( key in sizeRelatedOptions ) {
resize = true;
}
if ( key in resizableRelatedOptions ) {
resizableOptions[ key ] = value;
}
});
if ( resize ) {
this._size();
}
if ( [Link]( ":data(resizable)" ) ) {
[Link]( "option", resizableOptions );
}
},
switch (key) {
//handling of deprecated beforeclose (vs beforeClose) option
//Ticket #4669 [Link]
//TODO: remove in 1.9pre
case "beforeclose":
key = "beforeClose";
break;
case "buttons":
self._createButtons(value);
break;
case "closeText":
// ensure that we always pass a string
[Link]("" + value);
break;
case "dialogClass":
uiDialog
.removeClass([Link])
.addClass(uiDialogClasses + value);
break;
case "disabled":
if (value) {
[Link]('ui-dialog-disabled');
} else {
[Link]('ui-dialog-disabled');
}
break;
case "draggable":
var isDraggable = [Link]( ":data(draggable)" );
if ( isDraggable && !value ) {
[Link]( "destroy" );
}
$.[Link]._setOption.apply(self, arguments);
},
_size: function() {
/* If the user has resized the dialog, the .ui-dialog and .ui-dialog-
content
* divs will both have width and height set, so we need to reset them
*/
var options = [Link],
nonContentHeight,
minContentHeight,
isVisible = [Link]( ":visible" );
if ([Link](':data(resizable)')) {
[Link]('option', 'minHeight',
this._minHeight());
}
}
});
$.extend($.[Link], {
version: "1.8.24",
uuid: 0,
maxZ: 0,
getTitleId: function($el) {
var id = $[Link]('id');
if (!id) {
[Link] += 1;
id = [Link];
}
return 'ui-dialog-title-' + id;
},
overlay: function(dialog) {
this.$el = $.[Link](dialog);
}
});
$.extend($.[Link], {
instances: [],
// reuse old instances due to IE memory leak with alpha transparency (see
#5185)
oldInstances: [],
maxZ: 0,
events: $.map('focus,mousedown,mouseup,keydown,keypress,click'.split(','),
function(event) { return event + '.dialog-overlay'; }).join(' '),
create: function(dialog) {
if ([Link] === 0) {
// prevent use of anchors and inputs
// we use a setTimeout in case the overlay is created from an
// event that we're going to be cancelling (see #2804)
setTimeout(function() {
// handle $(el).dialog().dialog('close') (see #4065)
if ($.[Link]) {
$(document).bind($.[Link],
function(event) {
// stop events if the z-index of the target is
< the z-index of the overlay
// we cannot return true when we don't want to
cancel the event (#3523)
if ($([Link]).zIndex() <
$.[Link]) {
return false;
}
});
}
}, 1);
// allow closing by pressing the escape key
$(document).bind('[Link]-overlay', function(event) {
if ([Link] && !
[Link]() && [Link] &&
[Link] === $.[Link]) {
[Link](event);
[Link]();
}
});
if ($.[Link]) {
$[Link]();
}
[Link]($el);
return $el;
},
destroy: function($el) {
var indexOf = $.inArray($el, [Link]);
if (indexOf != -1){
[Link]([Link](indexOf, 1)[0]);
}
if ([Link] === 0) {
$([document, window]).unbind('.dialog-overlay');
}
$[Link]();
height: function() {
var scrollHeight,
offsetHeight;
// handle IE 6
if ($.[Link] && $.[Link] < 7) {
scrollHeight = [Link](
[Link],
[Link]
);
offsetHeight = [Link](
[Link],
[Link]
);
width: function() {
var scrollWidth,
offsetWidth;
// handle IE
if ( $.[Link] ) {
scrollWidth = [Link](
[Link],
[Link]
);
offsetWidth = [Link](
[Link],
[Link]
);
resize: function() {
/* If the dialog is draggable and the user drags it past the
* right edge of the window, the document becomes wider so we
* need to stretch the overlay. If the user then drags the
* dialog back to the left, the document will become narrower,
* so we need to shrink the overlay to the appropriate size.
* This is handled by shrinking the overlay before setting it
* to the full document size.
*/
var $overlays = $([]);
$.each($.[Link], function() {
$overlays = $[Link](this);
});
$[Link]({
width: 0,
height: 0
}).css({
width: $.[Link](),
height: $.[Link]()
});
}
});
$.extend($.[Link], {
destroy: function() {
$.[Link](this.$el);
}
});
}(jQuery));
(function( $, undefined ) {
if ( [Link] === 9 ) {
targetWidth = [Link]();
targetHeight = [Link]();
basePosition = { top: 0, left: 0 };
// TODO: use $.isWindow() in 1.9
} else if ( [Link] ) {
targetWidth = [Link]();
targetHeight = [Link]();
basePosition = { top: [Link](), left: [Link]() };
} else if ( [Link] ) {
// force left top to allow flipping
[Link] = "left top";
targetWidth = targetHeight = 0;
basePosition = { top: [Link], left: [Link] };
} else {
targetWidth = [Link]();
targetHeight = [Link]();
basePosition = [Link]();
}
[Link] += offset[ 0 ];
[Link] += offset[ 1 ];
return [Link](function() {
var elem = $( this ),
elemWidth = [Link](),
elemHeight = [Link](),
marginLeft = parseInt( $.curCSS( this, "marginLeft", true ) ) ||
0,
marginTop = parseInt( $.curCSS( this, "marginTop", true ) ) || 0,
collisionWidth = elemWidth + marginLeft +
( parseInt( $.curCSS( this, "marginRight", true ) ) || 0 ),
collisionHeight = elemHeight + marginTop +
( parseInt( $.curCSS( this, "marginBottom", true ) ) ||
0 ),
position = $.extend( {}, basePosition ),
collisionPosition;
collisionPosition = {
left: [Link] - marginLeft,
top: [Link] - marginTop
};
if ( $.[Link] ) {
[Link]();
}
[Link]( $.extend( position, { using: [Link] } ) );
});
};
$.[Link] = {
fit: {
left: function( position, data ) {
var win = $( window ),
over = [Link] + [Link] -
[Link]() - [Link]();
[Link] = over > 0 ? [Link] - over :
[Link]( [Link] - [Link], [Link] );
},
top: function( position, data ) {
var win = $( window ),
over = [Link] + [Link] -
[Link]() - [Link]();
[Link] = over > 0 ? [Link] - over :
[Link]( [Link] - [Link], [Link] );
}
},
flip: {
left: function( position, data ) {
if ( [Link][0] === center ) {
return;
}
var win = $( window ),
over = [Link] + [Link] -
[Link]() - [Link](),
myOffset = [Link][ 0 ] === "left" ?
-[Link] :
[Link][ 0 ] === "right" ?
[Link] :
0,
atOffset = [Link][ 0 ] === "left" ?
[Link] :
-[Link],
offset = -2 * [Link][ 0 ];
[Link] += [Link] < 0 ?
myOffset + atOffset + offset :
over > 0 ?
myOffset + atOffset + offset :
0;
},
top: function( position, data ) {
if ( [Link][1] === center ) {
return;
}
var win = $( window ),
over = [Link] + [Link] -
[Link]() - [Link](),
myOffset = [Link][ 1 ] === "top" ?
-[Link] :
[Link][ 1 ] === "bottom" ?
[Link] :
0,
atOffset = [Link][ 1 ] === "top" ?
[Link] :
-[Link],
offset = -2 * [Link][ 1 ];
[Link] += [Link] < 0 ?
myOffset + atOffset + offset :
over > 0 ?
myOffset + atOffset + offset :
0;
}
}
};
// offset setter from jQuery 1.4
if ( !$.[Link] ) {
$.[Link] = function( elem, options ) {
// set position first, in-case top/left are set even on static elem
if ( /static/.test( $.curCSS( elem, "position" ) ) ) {
[Link] = "relative";
}
var curElem = $( elem ),
curOffset = [Link](),
curTop = parseInt( $.curCSS( elem, "top", true ), 10 ) || 0,
curLeft = parseInt( $.curCSS( elem, "left", true ), 10) || 0,
props = {
top: ([Link] - [Link]) + curTop,
left: ([Link] - [Link]) + curLeft
};
if ( 'using' in options ) {
[Link]( elem, props );
} else {
[Link]( props );
}
};
// jQuery <1.4.3 uses curCSS, in 1.4.3 - 1.7.2 curCSS = css, 1.8+ only has css
if ( !$.curCSS ) {
$.curCSS = $.css;
}
[Link] = "";
[Link]( testElement );
}( jQuery ));
(function( $, undefined ) {
$.widget( "[Link]", {
options: {
value: 0,
max: 100
},
min: 0,
_create: function() {
[Link]
.addClass( "ui-progressbar ui-widget ui-widget-content ui-corner-
all" )
.attr({
role: "progressbar",
"aria-valuemin": [Link],
"aria-valuemax": [Link],
"aria-valuenow": this._value()
});
[Link] = this._value();
this._refreshValue();
},
destroy: function() {
[Link]
.removeClass( "ui-progressbar ui-widget ui-widget-content ui-
corner-all" )
.removeAttr( "role" )
.removeAttr( "aria-valuemin" )
.removeAttr( "aria-valuemax" )
.removeAttr( "aria-valuenow" );
[Link]();
_value: function() {
var val = [Link];
// normalize invalid value
if ( typeof val !== "number" ) {
val = 0;
}
return [Link]( [Link], [Link]( [Link], val ) );
},
_percentage: function() {
return 100 * this._value() / [Link];
},
_refreshValue: function() {
var value = [Link]();
var percentage = this._percentage();
$.extend( $.[Link], {
version: "1.8.24"
});
})( jQuery );
(function( $, undefined ) {
widgetEventPrefix: "slide",
options: {
animate: false,
distance: 0,
max: 100,
min: 0,
orientation: "horizontal",
range: false,
step: 1,
value: 0,
values: null
},
_create: function() {
var self = this,
o = [Link],
existingHandles = [Link]( ".ui-slider-
handle" ).addClass( "ui-state-default ui-corner-all" ),
handle = "<a class='ui-slider-handle ui-state-default ui-corner-
all' href='#'></a>",
handleCount = ( [Link] && [Link] ) || 1,
handles = [];
this._keySliding = false;
this._mouseSliding = false;
this._animateOff = true;
this._handleIndex = null;
this._detectOrientation();
this._mouseInit();
[Link]
.addClass( "ui-slider" +
" ui-slider-" + [Link] +
" ui-widget" +
" ui-widget-content" +
" ui-corner-all" +
( [Link] ? " ui-slider-disabled ui-disabled" : "" ) );
[Link] = $([]);
if ( [Link] ) {
if ( [Link] === true ) {
if ( ![Link] ) {
[Link] = [ this._valueMin(), this._valueMin() ];
}
if ( [Link] && [Link] !== 2 ) {
[Link] = [ [Link][0], [Link][0] ];
}
}
[Link] = $( "<div></div>" )
.appendTo( [Link] )
.addClass( "ui-slider-range" +
// note: this isn't the most fittingly semantic framework
class for this element,
// but worked best visually with a variety of themes
" ui-widget-header" +
( ( [Link] === "min" || [Link] === "max" ) ? " ui-slider-
range-" + [Link] : "" ) );
}
[Link] = [Link]( $
( [Link]( "" ) ).appendTo( [Link] ) );
[Link] = [Link]( 0 );
[Link]
.keydown(function( event ) {
var index = $( this ).data( "[Link]-slider-handle" ),
allowed,
curVal,
newVal,
step;
if ( [Link] ) {
return;
}
switch ( [Link] ) {
case $.[Link]:
case $.[Link]:
case $.[Link].PAGE_UP:
case $.[Link].PAGE_DOWN:
case $.[Link]:
case $.[Link]:
case $.[Link]:
case $.[Link]:
[Link]();
if ( !self._keySliding ) {
self._keySliding = true;
$( this ).addClass( "ui-state-active" );
allowed = self._start( event, index );
if ( allowed === false ) {
return;
}
}
break;
}
step = [Link];
if ( [Link] && [Link] ) {
curVal = newVal = [Link]( index );
} else {
curVal = newVal = [Link]();
}
switch ( [Link] ) {
case $.[Link]:
newVal = self._valueMin();
break;
case $.[Link]:
newVal = self._valueMax();
break;
case $.[Link].PAGE_UP:
newVal = self._trimAlignValue( curVal +
( (self._valueMax() - self._valueMin()) / numPages ) );
break;
case $.[Link].PAGE_DOWN:
newVal = self._trimAlignValue( curVal -
( (self._valueMax() - self._valueMin()) / numPages ) );
break;
case $.[Link]:
case $.[Link]:
if ( curVal === self._valueMax() ) {
return;
}
newVal = self._trimAlignValue( curVal + step );
break;
case $.[Link]:
case $.[Link]:
if ( curVal === self._valueMin() ) {
return;
}
newVal = self._trimAlignValue( curVal - step );
break;
}
if ( self._keySliding ) {
self._keySliding = false;
self._stop( event, index );
self._change( event, index );
$( this ).removeClass( "ui-state-active" );
}
});
this._refreshValue();
this._animateOff = false;
},
destroy: function() {
[Link]();
[Link]();
[Link]
.removeClass( "ui-slider" +
" ui-slider-horizontal" +
" ui-slider-vertical" +
" ui-slider-disabled" +
" ui-widget" +
" ui-widget-content" +
" ui-corner-all" )
.removeData( "slider" )
.unbind( ".slider" );
this._mouseDestroy();
return this;
},
if ( [Link] ) {
return false;
}
[Link] = {
width: [Link](),
height: [Link]()
};
[Link] = [Link]();
self._handleIndex = index;
closestHandle
.addClass( "ui-state-active" )
.focus();
offset = [Link]();
mouseOverHandle = !$( [Link] ).parents().andSelf().is( ".ui-
slider-handle" );
this._clickOffset = mouseOverHandle ? { left: 0, top: 0 } : {
left: [Link] - [Link] - ( [Link]() / 2 ),
top: [Link] - [Link] -
( [Link]() / 2 ) -
( parseInt( [Link]("borderTopWidth"), 10 ) ||
0 ) -
( parseInt( [Link]("borderBottomWidth"), 10 ) ||
0) +
( parseInt( [Link]("marginTop"), 10 ) || 0)
};
if (  ) {
this._slide( event, index, normValue );
}
this._animateOff = true;
return true;
},
return false;
},
this._handleIndex = null;
this._clickOffset = null;
this._animateOff = false;
return false;
},
_detectOrientation: function() {
[Link] = ( [Link] === "vertical" ) ?
"vertical" : "horizontal";
},
return this._value();
},
if ( [Link] > 1 ) {
[Link][ index ] = this._trimAlignValue( newValue );
this._refreshValue();
this._change( null, index );
return;
}
if ( [Link] ) {
if ( $.isArray( arguments[ 0 ] ) ) {
vals = [Link];
newValues = arguments[ 0 ];
for ( i = 0; i < [Link]; i += 1 ) {
vals[ i ] = this._trimAlignValue( newValues[ i ] );
this._change( null, i );
}
this._refreshValue();
} else {
if ( [Link] && [Link] ) {
return this._values( index );
} else {
return [Link]();
}
}
} else {
return this._values();
}
},
if ( $.isArray( [Link] ) ) {
valsLength = [Link];
}
switch ( key ) {
case "disabled":
if ( value ) {
[Link]( ".ui-state-focus" ).blur();
[Link]( "ui-state-hover" );
[Link]( "disabled", true );
[Link]( "ui-disabled" );
} else {
[Link]( "disabled", false );
[Link]( "ui-disabled" );
}
break;
case "orientation":
this._detectOrientation();
[Link]
.removeClass( "ui-slider-horizontal ui-slider-
vertical" )
.addClass( "ui-slider-" + [Link] );
this._refreshValue();
break;
case "value":
this._animateOff = true;
this._refreshValue();
this._change( null, 0 );
this._animateOff = false;
break;
case "values":
this._animateOff = true;
this._refreshValue();
for ( i = 0; i < valsLength; i += 1 ) {
this._change( null, i );
}
this._animateOff = false;
break;
}
},
return val;
},
if ( [Link] ) {
val = [Link][ index ];
val = this._trimAlignValue( val );
return val;
} else {
// .slice() creates a copy of the array
// this copy gets trimmed by min and max and then returned
vals = [Link]();
for ( i = 0; i < [Link]; i+= 1) {
vals[ i ] = this._trimAlignValue( vals[ i ] );
}
return vals;
}
},
// returns the step-aligned value that val is closest to, between (inclusive)
min and max
_trimAlignValue: function( val ) {
if ( val <= this._valueMin() ) {
return this._valueMin();
}
if ( val >= this._valueMax() ) {
return this._valueMax();
}
var step = ( [Link] > 0 ) ? [Link] : 1,
valModStep = (val - this._valueMin()) % step,
alignValue = val - valModStep;
_valueMin: function() {
return [Link];
},
_valueMax: function() {
return [Link];
},
_refreshValue: function() {
var oRange = [Link],
o = [Link],
self = this,
animate = ( !this._animateOff ) ? [Link] : false,
valPercent,
_set = {},
lastValPercent,
value,
valueMin,
valueMax;
});
$.extend( $.[Link], {
version: "1.8.24"
});
}(jQuery));
(function( $, undefined ) {
var tabId = 0,
listId = 0;
function getNextTabId() {
return ++tabId;
}
function getNextListId() {
return ++listId;
}
$.widget( "[Link]", {
options: {
add: null,
ajaxOptions: null,
cache: false,
cookie: null, // e.g. { expires: 7, path: '/', domain: '[Link]',
secure: true }
collapsible: false,
disable: null,
disabled: [],
enable: null,
event: "click",
fx: null, // e.g. { height: 'toggle', opacity: 'toggle', duration:
200 }
idPrefix: "ui-tabs-",
load: null,
panelTemplate: "<div></div>",
remove: null,
select: null,
show: null,
spinner: "<em>Loading…</em>",
tabTemplate: "<li><a href='#{href}'><span>#{label}</span></a></li>"
},
_create: function() {
this._tabify( true );
},
_tabId: function( a ) {
return [Link] && [Link]( /\s/g, "_" ).replace( /[^\w\u00c0-\
uFFFF-]/g, "" ) ||
[Link] + getNextTabId();
},
_cookie: function() {
var cookie = [Link] ||
( [Link] = [Link] || "ui-tabs-" +
getNextListId() );
return $.[Link]( null,
[ cookie ].concat( $.makeArray( arguments ) ) );
},
_cleanup: function() {
// restore all former loading tabs labels
[Link]( ".ui-state-processing" )
.removeClass( "ui-state-processing" )
.find( "span:data([Link])" )
.each(function() {
var el = $( this );
[Link](function( i, a ) {
var href = $( a ).attr( "href" );
// For dynamically created HTML that contains a hash as href IE <
8 expands
// such href to the full page url with hash and then
misinterprets tab as ajax.
// Same consideration applies for an added tab with a fragment
identifier
// since a[href=#fragment-identifier] does unexpectedly not
match.
// Thus normalize href attribute...
var hrefBase = [Link]( "#" )[ 0 ],
baseEl;
if ( hrefBase && ( hrefBase === [Link]().split( "#" )[
0 ] ||
( baseEl = $( "base" )[ 0 ]) && hrefBase ===
[Link] ) ) {
href = [Link];
[Link] = href;
}
// inline tab
if ( [Link]( href ) ) {
[Link] =
[Link]( [Link]( self._sanitizeSelector( href ) ) );
// remote tab
// prevent loading the page itself if href is just "#"
} else if ( href && href !== "#" ) {
// required for restore on destroy
$.data( a, "[Link]", href );
var id = self._tabId( a );
[Link] = "#" + id;
var $panel = [Link]( "#" + id );
if ( !$[Link] ) {
$panel = $( [Link] )
.attr( "id", id )
.addClass( "ui-tabs-panel ui-widget-content ui-
corner-bottom" )
.insertAfter( [Link][ i - 1 ] || [Link]
);
$[Link]( "[Link]", true );
}
[Link] = [Link]( $panel );
// invalid tab href
} else {
[Link]( i );
}
});
// Selected tab
// use "selected" option or try to retrieve:
// 1. from fragment identifier in url
// 2. from cookie
// 3. from selected class attribute on <li>
if ( [Link] === undefined ) {
if ( [Link] ) {
[Link](function( i, a ) {
if ( [Link] == [Link] ) {
[Link] = i;
return false;
}
});
}
if ( typeof [Link] !== "number" && [Link] ) {
[Link] = parseInt( self._cookie(), 10 );
}
if ( typeof [Link] !== "number" &&
[Link]( ".ui-tabs-selected" ).length ) {
[Link] = [Link]( [Link]( ".ui-
tabs-selected" ) );
}
[Link] = [Link] || ( [Link] ? 0 : -1 );
} else if ( [Link] === null ) { // usage of null is
deprecated, TODO remove in next release
[Link] = -1;
}
[Link]( [Link] );
}
// clean up to avoid memory leaks in certain versions of IE 6
// TODO: namespace this event
$( window ).bind( "unload", function() {
[Link]( [Link] ).unbind( ".tabs" );
[Link] = [Link] = [Link] = null;
});
// update selected after add/remove
} else {
[Link] = [Link]( [Link]( ".ui-tabs-selected"
) );
}
// update collapsible
// TODO: use .toggleClass()
[Link][ [Link] ? "addClass" : "removeClass" ]( "ui-tabs-
collapsible" );
// disable tabs
for ( var i = 0, li; ( li = [Link][ i ] ); i++ ) {
$( li )[ $.inArray( i, [Link] ) != -1 &&
// TODO: use .toggleClass()
!$( li ).hasClass( "ui-tabs-selected" ) ? "addClass" :
"removeClass" ]( "ui-state-disabled" );
}
// remove all handlers before, tabify may run on existing tabs after
add or option change
[Link]( [Link] ).unbind( ".tabs" );
// set up animations
var hideFx, showFx;
if ( [Link] ) {
if ( $.isArray( [Link] ) ) {
hideFx = [Link][ 0 ];
showFx = [Link][ 1 ];
} else {
hideFx = showFx = [Link];
}
}
// Show a tab...
var showTab = showFx
? function( clicked, $show ) {
$( clicked ).closest( "li" ).addClass( "ui-tabs-selected
ui-state-active" );
$[Link]().removeClass( "ui-tabs-hide" ) // avoid flicker
that way
.animate( showFx, [Link] || "normal",
function() {
resetStyle( $show, showFx );
self._trigger( "show", null, self._ui( clicked,
$show[ 0 ] ) );
});
}
: function( clicked, $show ) {
$( clicked ).closest( "li" ).addClass( "ui-tabs-selected
ui-state-active" );
$[Link]( "ui-tabs-hide" );
self._trigger( "show", null, self._ui( clicked,
$show[ 0 ] ) );
};
[Link]();
if ( [Link] ) {
self._cookie( [Link], [Link] );
}
[Link]();
return false;
} else if ( !$[Link] ) {
if ( [Link] ) {
self._cookie( [Link], [Link] );
}
[Link]();
return false;
}
}
if ( [Link] ) {
self._cookie( [Link], [Link] );
}
return index;
},
destroy: function() {
var o = [Link];
[Link]();
[Link]
.unbind( ".tabs" )
.removeClass( "ui-tabs ui-widget ui-widget-content ui-corner-all
ui-tabs-collapsible" )
.removeData( "tabs" );
[Link](function() {
var href = $.data( this, "[Link]" );
if ( href ) {
[Link] = href;
}
var $this = $( this ).unbind( ".tabs" );
$.each( [ "href", "load", "cache" ], function( i, prefix ) {
$[Link]( prefix + ".tabs" );
});
});
if ( [Link] ) {
this._cookie( null, [Link] );
}
return this;
},
this._tabify();
if ( [Link] == 1 ) {
[Link] = 0;
$[Link]( "ui-tabs-selected ui-state-active" );
$[Link]( "ui-tabs-hide" );
[Link]( "tabs", function() {
self._trigger( "show", null, self._ui( [Link][ 0 ],
[Link][ 0 ] ) );
});
[Link]( 0 );
}
[Link] = $.map(
$.grep( [Link], function(n, i) {
return n != index;
}),
function( n, i ) {
return n >= index ? --n : n;
});
this._tabify();
[Link]( index );
[Link]();
return this;
},
[Link]();
if ( [Link] ) {
var span = $( "span", a );
[Link]( "[Link]", [Link]() ).html( [Link] );
}
if ( [Link] ) {
$.data( a, "[Link]", true );
}
return this;
},
abort: function() {
// stop possibly running animations
[Link]( [] );
[Link]( false, true );
length: function() {
return [Link];
}
});
$.extend( $.[Link], {
version: "1.8.24"
});
/*
* Tabs Extensions
*/
/*
* Rotate
*/
$.extend( $.[Link], {
rotation: null,
rotate: function( ms, continuing ) {
var self = this,
o = [Link];
if ( e ) {
[Link]();
}
});
// start rotation
if ( ms ) {
[Link]( "tabsshow", rotate );
[Link]( [Link] + ".tabs", stop );
rotate();
// stop rotation
} else {
clearTimeout( [Link] );
[Link]( "tabsshow", rotate );
[Link]( [Link] + ".tabs", stop );
delete this._rotate;
delete this._unrotate;
}
return this;
}
});
})( jQuery );