diff options
355 files changed, 4226 insertions, 2504 deletions
diff --git a/.gitignore b/.gitignore index e39040f5b..e5d3578f1 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ docs *.diff *.patch .DS_Store +.settings diff --git a/AUTHORS.txt b/AUTHORS.txt index b2168655e..ecb4eb460 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -17,6 +17,7 @@ Bohdan Ganicky Scott González Marc Grabanski (m@marcgrabanski.com) Klaus Hartl (stilbuero.de) +Hans Hillen (TPG, funded through AEGIS: http://www.aegis-project.eu/) Scott Jehl Cody Lindley Eduardo Lundgren (eduardolundgren@gmail.com) @@ -8,6 +8,18 @@ If you want to use jQuery UI, go to [jqueryui.com](http://jqueryui.com) to get s If you are interested in helping developing jQuery UI, you are in the right place. To discuss development with team members and the community, visit the [Developing jQuery UI Forum](http://forum.jquery.com/developing-jquery-ui). +For contributors +--- +If you want to help and provide a patch for a bugfix or new feature, please take +a few minutes and look at [our Getting Involved guide](http://wiki.jqueryui.com/w/page/35263114/Getting-Involved), +in particular check out the [Coding standards](http://wiki.jqueryui.com/w/page/12137737/Coding-standards) +and [Commit Message Style Guide](http://wiki.jqueryui.com/w/page/25941597/Commit-Message-Style-Guide). + +In general, fork the project, create a branch for a specific change and send a +pull request for that branch. Don't mix unrelated changes. You can use the commit +message as the description for the pull request. + + For committers --- When looking at pull requests, first check for [proper commit messages](http://wiki.jqueryui.com/w/page/12137724/Bug-Fixing-Guide). diff --git a/demos/accordion/collapsible.html b/demos/accordion/collapsible.html index f77fdc05c..2969904b4 100644 --- a/demos/accordion/collapsible.html +++ b/demos/accordion/collapsible.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Collapse content</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> diff --git a/demos/accordion/custom-icons.html b/demos/accordion/custom-icons.html index 4f78b47d8..5aa548807 100644 --- a/demos/accordion/custom-icons.html +++ b/demos/accordion/custom-icons.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Customize icons</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> diff --git a/demos/accordion/default.html b/demos/accordion/default.html index e24a58633..241770bf3 100644 --- a/demos/accordion/default.html +++ b/demos/accordion/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> diff --git a/demos/accordion/fillspace.html b/demos/accordion/fillspace.html index 945ea3d1b..73a13cca3 100644 --- a/demos/accordion/fillspace.html +++ b/demos/accordion/fillspace.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Fill space</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/accordion/hoverintent.html b/demos/accordion/hoverintent.html index 570be752d..172e16525 100644 --- a/demos/accordion/hoverintent.html +++ b/demos/accordion/hoverintent.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Open on hoverintent</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> diff --git a/demos/accordion/mouseover.html b/demos/accordion/mouseover.html index d2cc7dbc0..228ce28cb 100644 --- a/demos/accordion/mouseover.html +++ b/demos/accordion/mouseover.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Open on mouseover</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> diff --git a/demos/accordion/no-auto-height.html b/demos/accordion/no-auto-height.html index ffda31965..7ab0d3c25 100644 --- a/demos/accordion/no-auto-height.html +++ b/demos/accordion/no-auto-height.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - No auto height</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> diff --git a/demos/accordion/sortable.html b/demos/accordion/sortable.html index 1bfce6fe1..ddc7123eb 100644 --- a/demos/accordion/sortable.html +++ b/demos/accordion/sortable.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Sortable</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/addClass/default.html b/demos/addClass/default.html index 73502d6fb..af117fb52 100644 --- a/demos/addClass/default.html +++ b/demos/addClass/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - addClass demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <link rel="stylesheet" href="../demos.css"> <style> diff --git a/demos/animate/default.html b/demos/animate/default.html index 284f0fe4f..148c36e5b 100644 --- a/demos/animate/default.html +++ b/demos/animate/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - Animate demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <link rel="stylesheet" href="../demos.css"> <style> diff --git a/demos/autocomplete/categories.html b/demos/autocomplete/categories.html index d2a1bc5bd..f2ee25a2b 100644 --- a/demos/autocomplete/categories.html +++ b/demos/autocomplete/categories.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Categories</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/combobox.html b/demos/autocomplete/combobox.html index b228c1cbb..42082fc08 100644 --- a/demos/autocomplete/combobox.html +++ b/demos/autocomplete/combobox.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Combobox</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/autocomplete/custom-data.html b/demos/autocomplete/custom-data.html index a5782cab9..b29c50995 100644 --- a/demos/autocomplete/custom-data.html +++ b/demos/autocomplete/custom-data.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Custom data and display</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/default.html b/demos/autocomplete/default.html index bbd0889cf..a10eaa74e 100644 --- a/demos/autocomplete/default.html +++ b/demos/autocomplete/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/folding.html b/demos/autocomplete/folding.html index 8ebf0d0a6..e7bd8299c 100644 --- a/demos/autocomplete/folding.html +++ b/demos/autocomplete/folding.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Accent folding</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/maxheight.html b/demos/autocomplete/maxheight.html index f87f03171..d0ae2f61c 100644 --- a/demos/autocomplete/maxheight.html +++ b/demos/autocomplete/maxheight.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Scrollable results</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/multiple-remote.html b/demos/autocomplete/multiple-remote.html index 16472a36c..8a04eb67a 100644 --- a/demos/autocomplete/multiple-remote.html +++ b/demos/autocomplete/multiple-remote.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Multiple, remote</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/multiple.html b/demos/autocomplete/multiple.html index f5f249c41..4c5a20e86 100644 --- a/demos/autocomplete/multiple.html +++ b/demos/autocomplete/multiple.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Multiple values</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/remote-jsonp.html b/demos/autocomplete/remote-jsonp.html index bfcbc0607..57e9de4d4 100644 --- a/demos/autocomplete/remote-jsonp.html +++ b/demos/autocomplete/remote-jsonp.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Remote JSONP datasource</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/remote-with-cache.html b/demos/autocomplete/remote-with-cache.html index 3d7a818ed..3b28e2977 100644 --- a/demos/autocomplete/remote-with-cache.html +++ b/demos/autocomplete/remote-with-cache.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Remote with caching</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/remote.html b/demos/autocomplete/remote.html index 3229c5cd8..c0c58e53d 100644 --- a/demos/autocomplete/remote.html +++ b/demos/autocomplete/remote.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - Remote datasource</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/autocomplete/xml.html b/demos/autocomplete/xml.html index 18178391d..f94d6ca26 100644 --- a/demos/autocomplete/xml.html +++ b/demos/autocomplete/xml.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Autocomplete - XML data parsed once</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/button/checkbox.html b/demos/button/checkbox.html index 0caf958c3..cecb63085 100644 --- a/demos/button/checkbox.html +++ b/demos/button/checkbox.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Button - Checkboxes</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/button/default.html b/demos/button/default.html index 969ec6838..04088f20a 100644 --- a/demos/button/default.html +++ b/demos/button/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Button - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/button/icons.html b/demos/button/icons.html index 1badb3f5d..62c4dac4a 100644 --- a/demos/button/icons.html +++ b/demos/button/icons.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Button - Icons</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/button/radio.html b/demos/button/radio.html index 5f725ca8d..d4a1197c2 100644 --- a/demos/button/radio.html +++ b/demos/button/radio.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Button - Radios</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/button/splitbutton.html b/demos/button/splitbutton.html index 215adb6b6..ef9157b35 100644 --- a/demos/button/splitbutton.html +++ b/demos/button/splitbutton.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Button - Split button</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/button/toolbar.html b/demos/button/toolbar.html index d68b2d9ca..b042082cc 100644 --- a/demos/button/toolbar.html +++ b/demos/button/toolbar.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Button - Toolbar</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.button.js"></script> diff --git a/demos/datepicker/alt-field.html b/demos/datepicker/alt-field.html index c60b21af7..b10e09c93 100644 --- a/demos/datepicker/alt-field.html +++ b/demos/datepicker/alt-field.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Populate alternate field</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/animation.html b/demos/datepicker/animation.html index 9814b98f8..07847d4cd 100644 --- a/demos/datepicker/animation.html +++ b/demos/datepicker/animation.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Animations</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.effects.core.js"></script> diff --git a/demos/datepicker/buttonbar.html b/demos/datepicker/buttonbar.html index 3b3be3bb3..0f65023ab 100644 --- a/demos/datepicker/buttonbar.html +++ b/demos/datepicker/buttonbar.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Display button bar</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/date-formats.html b/demos/datepicker/date-formats.html index e1ac6737b..c6e2c1553 100644 --- a/demos/datepicker/date-formats.html +++ b/demos/datepicker/date-formats.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Format date</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/date-range.html b/demos/datepicker/date-range.html index bf9b9a3e5..1de2fb5e4 100644 --- a/demos/datepicker/date-range.html +++ b/demos/datepicker/date-range.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Select a Date Range</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/default.html b/demos/datepicker/default.html index d50ac0de7..6c72ea3c0 100644 --- a/demos/datepicker/default.html +++ b/demos/datepicker/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/dropdown-month-year.html b/demos/datepicker/dropdown-month-year.html index 8392a1593..2f6285dc5 100644 --- a/demos/datepicker/dropdown-month-year.html +++ b/demos/datepicker/dropdown-month-year.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Display month & year menus</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/icon-trigger.html b/demos/datepicker/icon-trigger.html index 5f4edc7f3..27b612bbb 100644 --- a/demos/datepicker/icon-trigger.html +++ b/demos/datepicker/icon-trigger.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Icon trigger</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/inline.html b/demos/datepicker/inline.html index 19c4b0420..67c27e673 100644 --- a/demos/datepicker/inline.html +++ b/demos/datepicker/inline.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Display inline</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/localization.html b/demos/datepicker/localization.html index 91036111f..8b592762d 100644 --- a/demos/datepicker/localization.html +++ b/demos/datepicker/localization.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Localize calendar</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/min-max.html b/demos/datepicker/min-max.html index e27339e10..ba82cbcf9 100644 --- a/demos/datepicker/min-max.html +++ b/demos/datepicker/min-max.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Restrict date range</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/multiple-calendars.html b/demos/datepicker/multiple-calendars.html index 0c762f729..75b89c05c 100644 --- a/demos/datepicker/multiple-calendars.html +++ b/demos/datepicker/multiple-calendars.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Display multiple months</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/other-months.html b/demos/datepicker/other-months.html index 78a04f2c3..689e114a0 100644 --- a/demos/datepicker/other-months.html +++ b/demos/datepicker/other-months.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Dates in other months</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/datepicker/show-week.html b/demos/datepicker/show-week.html index 1cdb349bd..829431d7d 100644 --- a/demos/datepicker/show-week.html +++ b/demos/datepicker/show-week.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Datepicker - Show week of the year</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.datepicker.js"></script> diff --git a/demos/dialog/animated.html b/demos/dialog/animated.html index 200db3fe0..8ee836408 100644 --- a/demos/dialog/animated.html +++ b/demos/dialog/animated.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Dialog - Animation</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.bgiframe-2.1.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/dialog/default.html b/demos/dialog/default.html index 083f7aa54..02a5170f6 100644 --- a/demos/dialog/default.html +++ b/demos/dialog/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Dialog - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.bgiframe-2.1.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/dialog/modal-confirmation.html b/demos/dialog/modal-confirmation.html index e316a97bf..33265aa5e 100644 --- a/demos/dialog/modal-confirmation.html +++ b/demos/dialog/modal-confirmation.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Dialog - Modal confirmation</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.bgiframe-2.1.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/dialog/modal-form.html b/demos/dialog/modal-form.html index 5793b32ee..211e6a4e1 100644 --- a/demos/dialog/modal-form.html +++ b/demos/dialog/modal-form.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Dialog - Modal form</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.bgiframe-2.1.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/dialog/modal-message.html b/demos/dialog/modal-message.html index 90a88c33e..d47df568c 100644 --- a/demos/dialog/modal-message.html +++ b/demos/dialog/modal-message.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Dialog - Modal message</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.bgiframe-2.1.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/dialog/modal.html b/demos/dialog/modal.html index ce56c30ed..39fefa959 100644 --- a/demos/dialog/modal.html +++ b/demos/dialog/modal.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Dialog - Basic modal</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.bgiframe-2.1.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/draggable/constrain-movement.html b/demos/draggable/constrain-movement.html index 9610fc48d..c8f421182 100644 --- a/demos/draggable/constrain-movement.html +++ b/demos/draggable/constrain-movement.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Constrain movement</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/cursor-style.html b/demos/draggable/cursor-style.html index 6ef5426ed..beca90b84 100644 --- a/demos/draggable/cursor-style.html +++ b/demos/draggable/cursor-style.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Cursor style</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/default.html b/demos/draggable/default.html index d8085b0b8..f488c85f9 100644 --- a/demos/draggable/default.html +++ b/demos/draggable/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/delay-start.html b/demos/draggable/delay-start.html index 45e3edae2..0c5533d0e 100644 --- a/demos/draggable/delay-start.html +++ b/demos/draggable/delay-start.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Delay start</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/events.html b/demos/draggable/events.html index ed067d120..fa0f67680 100644 --- a/demos/draggable/events.html +++ b/demos/draggable/events.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Events</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/handle.html b/demos/draggable/handle.html index dc6d7b9e6..29d9b9635 100644 --- a/demos/draggable/handle.html +++ b/demos/draggable/handle.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Handles</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/revert.html b/demos/draggable/revert.html index 11f3abdfa..dca082746 100644 --- a/demos/draggable/revert.html +++ b/demos/draggable/revert.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Revert position</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/scroll.html b/demos/draggable/scroll.html index a650ed5d9..6279865bd 100644 --- a/demos/draggable/scroll.html +++ b/demos/draggable/scroll.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Auto-scroll</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/snap-to.html b/demos/draggable/snap-to.html index 14e254e47..0d0eab054 100644 --- a/demos/draggable/snap-to.html +++ b/demos/draggable/snap-to.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Snap to element or grid</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/sortable.html b/demos/draggable/sortable.html index 4bc32986d..f4a134821 100644 --- a/demos/draggable/sortable.html +++ b/demos/draggable/sortable.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable + Sortable</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/draggable/visual-feedback.html b/demos/draggable/visual-feedback.html index 5d0ff2668..8a4ecc200 100644 --- a/demos/draggable/visual-feedback.html +++ b/demos/draggable/visual-feedback.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Draggable - Visual feedback</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/droppable/accepted-elements.html b/demos/droppable/accepted-elements.html index a2e3b3321..f578b65a9 100644 --- a/demos/droppable/accepted-elements.html +++ b/demos/droppable/accepted-elements.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Accept</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/droppable/default.html b/demos/droppable/default.html index 4de66d70a..72aed890e 100644 --- a/demos/droppable/default.html +++ b/demos/droppable/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/droppable/photo-manager.html b/demos/droppable/photo-manager.html index 2b16eb7b2..52d9dfa8c 100644 --- a/demos/droppable/photo-manager.html +++ b/demos/droppable/photo-manager.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Simple photo manager</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.position.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/droppable/propagation.html b/demos/droppable/propagation.html index 3275dd2a6..66e6067d4 100644 --- a/demos/droppable/propagation.html +++ b/demos/droppable/propagation.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Prevent propagation</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/droppable/revert.html b/demos/droppable/revert.html index 24da889b1..423ed532f 100644 --- a/demos/droppable/revert.html +++ b/demos/droppable/revert.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Revert draggable position</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/droppable/shopping-cart.html b/demos/droppable/shopping-cart.html index 4fb9a87ba..039ebc2f9 100644 --- a/demos/droppable/shopping-cart.html +++ b/demos/droppable/shopping-cart.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Shopping Cart Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/droppable/visual-feedback.html b/demos/droppable/visual-feedback.html index ff2ddc6ca..821c99b61 100644 --- a/demos/droppable/visual-feedback.html +++ b/demos/droppable/visual-feedback.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Droppable - Visual feedback</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/effect/default.html b/demos/effect/default.html index 6be20f38d..b3d102eb2 100644 --- a/demos/effect/default.html +++ b/demos/effect/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - Effect demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <script src="../../ui/jquery.effects.blind.js"></script> <script src="../../ui/jquery.effects.bounce.js"></script> diff --git a/demos/effect/easing.html b/demos/effect/easing.html index 0b6ba0885..31d707d8e 100644 --- a/demos/effect/easing.html +++ b/demos/effect/easing.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - Easing demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <link rel="stylesheet" href="../demos.css"> <style> diff --git a/demos/hide/default.html b/demos/hide/default.html index 1409024cb..064ba9242 100644 --- a/demos/hide/default.html +++ b/demos/hide/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - Hide Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <script src="../../ui/jquery.effects.blind.js"></script> <script src="../../ui/jquery.effects.bounce.js"></script> diff --git a/demos/index.html b/demos/index.html index 53a2557a2..a14696c7c 100644 --- a/demos/index.html +++ b/demos/index.html @@ -5,7 +5,7 @@ <title>jQuery UI Demos</title> <link rel="stylesheet" href="../themes/base/jquery.ui.all.css"> <link rel="stylesheet" href="demos.css"> - <script src="../jquery-1.5.1.js"></script> + <script src="../jquery-1.6.2.js"></script> <script src="../external/jquery.bgiframe-2.1.2.js"></script> <script src="../external/jquery.global.js"></script> <script src="../external/jquery.global.de-DE.js"></script> diff --git a/demos/menu/contextmenu.html b/demos/menu/contextmenu.html index 7513bca28..c4cba49e5 100644 --- a/demos/menu/contextmenu.html +++ b/demos/menu/contextmenu.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Menu - Contextmenu demo</title> <link href="../../themes/base/jquery.ui.all.css" rel="stylesheet" /> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.position.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> @@ -46,14 +46,14 @@ <li><a href="#Utrecht">Utrecht</a></li> <li><a href="#Zurich">Zurich</a></li> </ul> - + <div id="log"></div> </div><!-- End demo --> <div class="demo-description"> -<p>TODO update - A simple contextmenu: Click the button, or tab to it and hit space to open the menu. Use the mouse or cursor keys to select an item, click it or hit enter to select it.</p> +<p>A simple contextmenu: Click the button, or tab to it and hit space to open the menu. Use the mouse or cursor keys to select an item, click it or hit enter to select it.</p> <p>The keyboard handling is part of the menu. Using the input option to menu is configured to add the key event handlers to the button, as that button gets focused when clicked.</p> diff --git a/demos/menu/default.html b/demos/menu/default.html index 40386112f..4ee61fc9e 100644 --- a/demos/menu/default.html +++ b/demos/menu/default.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Menu - Default demo</title> <link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" /> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.menu.js"></script> diff --git a/demos/menu/index.html b/demos/menu/index.html index 3088f9d7d..9983dbfd0 100644 --- a/demos/menu/index.html +++ b/demos/menu/index.html @@ -11,6 +11,7 @@ <ul> <li class="demo-config-on"><a href="default.html">Default functionality</a></li> <li><a href="contextmenu.html">Contextmenu</a></li> + <li><a href="topalignmenu.html">Top-aligned sub menus</a></li> </ul> </div> </body> diff --git a/demos/menu/topalignmenu.html b/demos/menu/topalignmenu.html new file mode 100644 index 000000000..0339e343a --- /dev/null +++ b/demos/menu/topalignmenu.html @@ -0,0 +1,80 @@ +<!doctype html> +<html> +<head> + <title>Menu Demo: Top-aligned Menu</title> + <link rel="stylesheet" href="../demos.css" type="text/css" /> + <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> + <script type="text/javascript" src="../../jquery-1.6.2.js"></script> + <script type="text/javascript" src="../../ui/jquery.ui.core.js"></script> + <script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script> + <script type="text/javascript" src="../../ui/jquery.ui.position.js"></script> + <script type="text/javascript" src="../../ui/jquery.ui.menu.js"></script> + <script type="text/javascript"> + $(function() { + $("#topMenu").menu({ + position: { of: "ul:has(a.ui-state-focus):last" } + }); + }); + </script> + <style> + .ui-menu { width: 200px; margin-bottom: 2em; } + </style> +</head> +<body> + +<ul id="topMenu"> + <li><a href="#">Aberdeen</a></li> + <li><a href="#">Ada</a></li> + <li><a href="#">Adamsville</a></li> + <li><a href="#">Addyston</a></li> + <li> + <a href="#">Delphi</a> + <ul> + <li><a href="#">Ada</a></li> + <li><a href="#">Saarland</a></li> + <li><a href="#">Salzburg</a></li> + </ul> + </li> + <li><a href="#">Saarland</a></li> + <li> + <a href="#">Salzburg</a> + <ul> + <li> + <a href="#">Delphi</a> + <ul> + <li><a href="#">Ada</a></li> + <li><a href="#">Saarland</a></li> + <li><a href="#">Salzburg</a></li> + </ul> + </li> + <li> + <a href="#">Adamsville</a> + <ul> + <li><a href="#">Aberdeen</a></li> + <li><a href="#">Ada</a></li> + <li><a href="#">Adamsville</a></li> + <li><a href="#">Addyston</a></li> + <li> + <a href="#">Delphi</a> + <ul> + <li><a href="#">Ada</a></li> + <li><a href="#">Saarland</a></li> + <li><a href="#">Salzburg</a></li> + </ul> + </li> + <li><a href="#">Saarland</a></li> + </ul> + </li> + <li><a href="#">Perch</a> + <ul> + <li><a href="#">Addyston</a></li> + <li><a href="#">Delphi</a></li> + <li><a href="#">Perch</a></li> + </ul> + </li> + </ul> + </li> +</ul> + +</body> +</html> diff --git a/demos/menubar/default.html b/demos/menubar/default.html index 57a3209ce..34742bb52 100644 --- a/demos/menubar/default.html +++ b/demos/menubar/default.html @@ -4,7 +4,7 @@ <title>jQuery UI Menubar - Default demo</title> <link rel="stylesheet" href="../demos.css" type="text/css" /> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" /> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> @@ -13,24 +13,27 @@ <script src="../../ui/jquery.ui.menubar.js"></script> <script> $(function() { + function select(event, ui) { + $("<div/>").text("Selected: " + ui.item.text()).appendTo("#log"); + if (ui.item.text() == 'Quit') { + $(this).menubar('destroy'); + } + } $("#bar1").menubar({ position: { within: $("#demo-frame").add(window).first() }, - select: function(event, ui) { - $("<div/>").text("Selected: " + ui.item.text()).appendTo("#log"); - } + select: select }); $(".menubar-icons").menubar({ + autoExpand: true, menuIcon: true, buttons: true, position: { within: $("#demo-frame").add(window).first() }, - select: function(event, ui) { - $("<div/>").text("Selected: " + ui.item.text()).appendTo("#log"); - } + select: select }); }); </script> diff --git a/demos/popup/default.html b/demos/popup/default.html index 7b63d9e1d..97fc01fb2 100644 --- a/demos/popup/default.html +++ b/demos/popup/default.html @@ -4,7 +4,7 @@ <title>jQuery UI Popup - Default demo</title> <link rel="stylesheet" href="../demos.css" /> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" title="ui-theme" /> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/popup/popup-menu-table.html b/demos/popup/popup-menu-table.html index a06a38434..b3c00a442 100644 --- a/demos/popup/popup-menu-table.html +++ b/demos/popup/popup-menu-table.html @@ -4,7 +4,7 @@ <title>jQuery UI Popup - Menu as Popup in table demo</title> <link rel="stylesheet" href="../demos.css" /> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" title="ui-theme" /> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/popup/popup-menu.html b/demos/popup/popup-menu.html index 7152d85bc..824b78651 100644 --- a/demos/popup/popup-menu.html +++ b/demos/popup/popup-menu.html @@ -4,7 +4,7 @@ <title>jQuery UI Popup - Popup Menu</title> <link rel="stylesheet" href="../demos.css" /> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" title="ui-theme" /> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/position/cycler.html b/demos/position/cycler.html index 521b8d565..c2d886b61 100644 --- a/demos/position/cycler.html +++ b/demos/position/cycler.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Position - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/position/default.html b/demos/position/default.html index 87fc8e38a..6a753e2f1 100644 --- a/demos/position/default.html +++ b/demos/position/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Position - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> @@ -12,7 +12,7 @@ <script src="../../ui/jquery.ui.position.js"></script> <link rel="stylesheet" href="../demos.css"> <style> - div#parent { + #parent { width: 60%; margin: 10px auto; padding: 5px; @@ -20,7 +20,7 @@ background-color: #fbca93; text-align: center; } - div.positionable { + .positionable { width: 75px; height: 75px; position: absolute; @@ -30,6 +30,18 @@ background-color: #bcd5e6; text-align: center; } + .ui-flipped-top { + border-top: 3px solid #000000; + } + .ui-flipped-bottom { + border-bottom: 3px solid #000000; + } + .ui-flipped-left { + border-left: 3px solid #000000; + } + .ui-flipped-right { + border-right: 3px solid #000000; + } select, input { margin-left: 15px; } @@ -101,7 +113,7 @@ <option value="left">left</option> <option value="center">center</option> <option value="right">right</option> - </select> + </select> <select id="my_vertical"> <option value="top">top</option> <option value="middle">center</option> diff --git a/demos/progressbar/animated.html b/demos/progressbar/animated.html index 73f547726..dbd0eb922 100644 --- a/demos/progressbar/animated.html +++ b/demos/progressbar/animated.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Progressbar - Animated</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.progressbar.js"></script> diff --git a/demos/progressbar/default.html b/demos/progressbar/default.html index 5c6ca43db..92a1fbf98 100644 --- a/demos/progressbar/default.html +++ b/demos/progressbar/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Progressbar - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.progressbar.js"></script> diff --git a/demos/progressbar/resize.html b/demos/progressbar/resize.html index adc1fbbfb..e45b5d888 100644 --- a/demos/progressbar/resize.html +++ b/demos/progressbar/resize.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Progressbar - Resizable</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/removeClass/default.html b/demos/removeClass/default.html index 3bd52e640..02884c3fc 100644 --- a/demos/removeClass/default.html +++ b/demos/removeClass/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - removeClass Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <link rel="stylesheet" href="../demos.css"> <style> diff --git a/demos/resizable/animate.html b/demos/resizable/animate.html index c288d62bc..f3d5a38c6 100644 --- a/demos/resizable/animate.html +++ b/demos/resizable/animate.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Animate</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/aspect-ratio.html b/demos/resizable/aspect-ratio.html index 421f2e4aa..92114656b 100644 --- a/demos/resizable/aspect-ratio.html +++ b/demos/resizable/aspect-ratio.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Preserve aspect ratio</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/constrain-area.html b/demos/resizable/constrain-area.html index 33539f940..533a257a6 100644 --- a/demos/resizable/constrain-area.html +++ b/demos/resizable/constrain-area.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Constrain resize area</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/default.html b/demos/resizable/default.html index ded33329f..1eddec917 100644 --- a/demos/resizable/default.html +++ b/demos/resizable/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/delay-start.html b/demos/resizable/delay-start.html index 6fc2cc2d6..b5919e8c1 100644 --- a/demos/resizable/delay-start.html +++ b/demos/resizable/delay-start.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Delay start</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/helper.html b/demos/resizable/helper.html index a36385617..bd116cd25 100644 --- a/demos/resizable/helper.html +++ b/demos/resizable/helper.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Helper</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/max-min.html b/demos/resizable/max-min.html index 81be5dd5d..da2e82ca4 100644 --- a/demos/resizable/max-min.html +++ b/demos/resizable/max-min.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Maximum / minimum size</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/snap-to-grid.html b/demos/resizable/snap-to-grid.html index 568c1c743..cb074d7a2 100644 --- a/demos/resizable/snap-to-grid.html +++ b/demos/resizable/snap-to-grid.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Snap to grid</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/synchronous-resize.html b/demos/resizable/synchronous-resize.html index 74e54da47..e39fbc5d9 100644 --- a/demos/resizable/synchronous-resize.html +++ b/demos/resizable/synchronous-resize.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Synchronous resize</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/textarea.html b/demos/resizable/textarea.html index 2d00e0ded..8df4dca58 100644 --- a/demos/resizable/textarea.html +++ b/demos/resizable/textarea.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Textarea</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/resizable/visual-feedback.html b/demos/resizable/visual-feedback.html index fc61a6bcb..f88ee1e1d 100644 --- a/demos/resizable/visual-feedback.html +++ b/demos/resizable/visual-feedback.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Resizable - Visual feedback</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/selectable/default.html b/demos/selectable/default.html index 983a04b3f..ff42dcd2d 100644 --- a/demos/selectable/default.html +++ b/demos/selectable/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Selectable - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/selectable/display-grid.html b/demos/selectable/display-grid.html index b045eb99c..3d6f1d1a6 100644 --- a/demos/selectable/display-grid.html +++ b/demos/selectable/display-grid.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Selectable - Display as grid</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/selectable/serialize.html b/demos/selectable/serialize.html index 18e35dae2..8d3bdf945 100644 --- a/demos/selectable/serialize.html +++ b/demos/selectable/serialize.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Selectable - Serialize</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/show/default.html b/demos/show/default.html index 49ca85675..5c5654324 100644 --- a/demos/show/default.html +++ b/demos/show/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - Show Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <script src="../../ui/jquery.effects.blind.js"></script> <script src="../../ui/jquery.effects.bounce.js"></script> diff --git a/demos/slider/colorpicker.html b/demos/slider/colorpicker.html index 8192e08a7..a00aaa230 100644 --- a/demos/slider/colorpicker.html +++ b/demos/slider/colorpicker.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Colorpicker</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/default.html b/demos/slider/default.html index fdcd4cff9..4018acdce 100644 --- a/demos/slider/default.html +++ b/demos/slider/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8" > <title>jQuery UI Slider - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/hotelrooms.html b/demos/slider/hotelrooms.html index 2ba4b9970..d540a14e6 100644 --- a/demos/slider/hotelrooms.html +++ b/demos/slider/hotelrooms.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Range with fixed minimum</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/multiple-vertical.html b/demos/slider/multiple-vertical.html index 372ad2d93..0105edb4a 100644 --- a/demos/slider/multiple-vertical.html +++ b/demos/slider/multiple-vertical.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Multiple sliders</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/range-vertical.html b/demos/slider/range-vertical.html index 2a1a8b4e9..d4d11ff6b 100644 --- a/demos/slider/range-vertical.html +++ b/demos/slider/range-vertical.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Vertical range slider</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/range.html b/demos/slider/range.html index 3fd156dc3..43e0e59c2 100644 --- a/demos/slider/range.html +++ b/demos/slider/range.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Range slider</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/rangemax.html b/demos/slider/rangemax.html index 899efb28a..ac1f210e1 100644 --- a/demos/slider/rangemax.html +++ b/demos/slider/rangemax.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Range with fixed maximum</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/rangemin.html b/demos/slider/rangemin.html index 3e077d909..8cd1f78ec 100644 --- a/demos/slider/rangemin.html +++ b/demos/slider/rangemin.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Range with fixed minimum</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/side-scroll.html b/demos/slider/side-scroll.html index 666d480a0..143564a22 100644 --- a/demos/slider/side-scroll.html +++ b/demos/slider/side-scroll.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Slider scrollbar</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/slider-vertical.html b/demos/slider/slider-vertical.html index 479e778ff..1d9ec77d2 100644 --- a/demos/slider/slider-vertical.html +++ b/demos/slider/slider-vertical.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Vertical slider</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/steps.html b/demos/slider/steps.html index c49e26fb3..9db7a691b 100644 --- a/demos/slider/steps.html +++ b/demos/slider/steps.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Snap to increments</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/slider/tabs.html b/demos/slider/tabs.html index 440ac587d..67d537651 100644 --- a/demos/slider/tabs.html +++ b/demos/slider/tabs.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Slider - Snap to increments</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/connect-lists-through-tabs.html b/demos/sortable/connect-lists-through-tabs.html index d466da80c..4489ab04f 100644 --- a/demos/sortable/connect-lists-through-tabs.html +++ b/demos/sortable/connect-lists-through-tabs.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Connect lists with Tabs</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/connect-lists.html b/demos/sortable/connect-lists.html index d0b2c5ce1..e3674da46 100644 --- a/demos/sortable/connect-lists.html +++ b/demos/sortable/connect-lists.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Connect lists</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/default.html b/demos/sortable/default.html index d0ef0df69..6b09aeb77 100644 --- a/demos/sortable/default.html +++ b/demos/sortable/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/delay-start.html b/demos/sortable/delay-start.html index 48a9c1f63..ac4acb515 100644 --- a/demos/sortable/delay-start.html +++ b/demos/sortable/delay-start.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Delay start</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/display-grid.html b/demos/sortable/display-grid.html index c32e309f3..3eecb6f0f 100644 --- a/demos/sortable/display-grid.html +++ b/demos/sortable/display-grid.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Display as grid</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/empty-lists.html b/demos/sortable/empty-lists.html index d1c968096..b202716ff 100644 --- a/demos/sortable/empty-lists.html +++ b/demos/sortable/empty-lists.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Handle empty lists</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/items.html b/demos/sortable/items.html index 334cdeb34..596b0cd2d 100644 --- a/demos/sortable/items.html +++ b/demos/sortable/items.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Include / exclude items</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/placeholder.html b/demos/sortable/placeholder.html index 90198f3d1..88fcd521a 100644 --- a/demos/sortable/placeholder.html +++ b/demos/sortable/placeholder.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Drop placeholder</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/sortable/portlets.html b/demos/sortable/portlets.html index 1e5e956d8..bdb2c3a5a 100644 --- a/demos/sortable/portlets.html +++ b/demos/sortable/portlets.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Sortable - Portlets</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/spinner/currency.html b/demos/spinner/currency.html index 1e9b37d08..cb5528dda 100644 --- a/demos/spinner/currency.html +++ b/demos/spinner/currency.html @@ -4,7 +4,7 @@ <meta charset="utf-8">
<title>jQuery UI Spinner - Default functionality</title>
<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
- <script type="text/javascript" src="../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../external/jquery.global.js"></script>
<script type="text/javascript" src="../../external/jquery.global.de-DE.js"></script>
diff --git a/demos/spinner/decimal.html b/demos/spinner/decimal.html index cdc659298..bcbc24751 100644 --- a/demos/spinner/decimal.html +++ b/demos/spinner/decimal.html @@ -4,7 +4,7 @@ <meta charset="utf-8">
<title>jQuery UI Spinner - decimal</title>
<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
- <script type="text/javascript" src="../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../external/jquery.global.js"></script>
<script type="text/javascript" src="../../external/jquery.global.de-DE.js"></script>
diff --git a/demos/spinner/default.html b/demos/spinner/default.html index 2589c1029..4035ee41c 100644 --- a/demos/spinner/default.html +++ b/demos/spinner/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8">
<title>jQuery UI Spinner - Default functionality</title>
<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
- <script type="text/javascript" src="../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../ui/jquery.ui.core.js"></script>
<script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script>
diff --git a/demos/spinner/latlong.html b/demos/spinner/latlong.html index 0763961cc..3c549f180 100644 --- a/demos/spinner/latlong.html +++ b/demos/spinner/latlong.html @@ -5,7 +5,7 @@ <title>jQuery UI Spinner - Map</title>
<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
- <script type="text/javascript" src="../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../ui/jquery.ui.core.js"></script>
<script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script>
diff --git a/demos/spinner/overflow.html b/demos/spinner/overflow.html index d8b4100f9..23ae1a888 100644 --- a/demos/spinner/overflow.html +++ b/demos/spinner/overflow.html @@ -4,7 +4,7 @@ <meta charset="utf-8">
<title>jQuery UI Spinner - Default functionality</title>
<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
- <script type="text/javascript" src="../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../ui/jquery.ui.core.js"></script>
<script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script>
diff --git a/demos/spinner/time.html b/demos/spinner/time.html index 567ada524..5858a5071 100644 --- a/demos/spinner/time.html +++ b/demos/spinner/time.html @@ -4,7 +4,7 @@ <meta charset="utf-8">
<title>jQuery UI Spinner - decimal</title>
<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
- <script type="text/javascript" src="../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../external/jquery.global.js"></script>
<script type="text/javascript" src="../../external/jquery.global.de-DE.js"></script>
diff --git a/demos/switchClass/default.html b/demos/switchClass/default.html index c0bcd6b31..8e7723cb5 100644 --- a/demos/switchClass/default.html +++ b/demos/switchClass/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - switchClass Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <link rel="stylesheet" href="../demos.css"> <style> diff --git a/demos/tabs/ajax.html b/demos/tabs/ajax.html index 407914589..b5b89fd91 100644 --- a/demos/tabs/ajax.html +++ b/demos/tabs/ajax.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Content via Ajax</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.tabs.js"></script> diff --git a/demos/tabs/bottom.html b/demos/tabs/bottom.html index 68ccac902..b677c629c 100644 --- a/demos/tabs/bottom.html +++ b/demos/tabs/bottom.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Tabs at bottom</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.tabs.js"></script> diff --git a/demos/tabs/collapsible.html b/demos/tabs/collapsible.html index 1fba71041..3dcbc95a9 100644 --- a/demos/tabs/collapsible.html +++ b/demos/tabs/collapsible.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Collapse content</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.tabs.js"></script> diff --git a/demos/tabs/cookie.html b/demos/tabs/cookie.html index 35972436d..86e857ee5 100644 --- a/demos/tabs/cookie.html +++ b/demos/tabs/cookie.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../external/jquery.cookie.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/tabs/default.html b/demos/tabs/default.html index a892509ce..8dc18b29b 100644 --- a/demos/tabs/default.html +++ b/demos/tabs/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.tabs.js"></script> diff --git a/demos/tabs/manipulation.html b/demos/tabs/manipulation.html index 4b79ac714..c6720038b 100644 --- a/demos/tabs/manipulation.html +++ b/demos/tabs/manipulation.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Simple manipulation</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.position.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> diff --git a/demos/tabs/mouseover.html b/demos/tabs/mouseover.html index b19b2af09..b43c71b3e 100644 --- a/demos/tabs/mouseover.html +++ b/demos/tabs/mouseover.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Open on mouseover</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.tabs.js"></script> diff --git a/demos/tabs/sortable.html b/demos/tabs/sortable.html index c3e882791..2739184ab 100644 --- a/demos/tabs/sortable.html +++ b/demos/tabs/sortable.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Sortable</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.mouse.js"></script> diff --git a/demos/tabs/vertical.html b/demos/tabs/vertical.html index 690f03420..52a75e2a0 100644 --- a/demos/tabs/vertical.html +++ b/demos/tabs/vertical.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tabs - Vertical Tabs functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.tabs.js"></script> diff --git a/demos/toggle/default.html b/demos/toggle/default.html index 475109e11..2081d809d 100644 --- a/demos/toggle/default.html +++ b/demos/toggle/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - Toggle Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <script src="../../ui/jquery.effects.blind.js"></script> <script src="../../ui/jquery.effects.bounce.js"></script> diff --git a/demos/toggleClass/default.html b/demos/toggleClass/default.html index ed3eb5179..c83e405e7 100644 --- a/demos/toggleClass/default.html +++ b/demos/toggleClass/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects - toggleClass Demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.effects.core.js"></script> <link rel="stylesheet" href="../demos.css"> <style> diff --git a/demos/tooltip/custom-animation.html b/demos/tooltip/custom-animation.html index c7d1aa5b8..38ad9d058 100644 --- a/demos/tooltip/custom-animation.html +++ b/demos/tooltip/custom-animation.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tooltip - Custom animation demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/tooltip/custom-content.html b/demos/tooltip/custom-content.html index e84a7104b..646910b48 100644 --- a/demos/tooltip/custom-content.html +++ b/demos/tooltip/custom-content.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tooltip - Custom content</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/tooltip/default.html b/demos/tooltip/default.html index cfb61f2eb..c60081fe4 100644 --- a/demos/tooltip/default.html +++ b/demos/tooltip/default.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tooltip - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/tooltip/forms.html b/demos/tooltip/forms.html index 0f91736b2..5e88e7620 100644 --- a/demos/tooltip/forms.html +++ b/demos/tooltip/forms.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tooltip - Default demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/tooltip/tracking.html b/demos/tooltip/tracking.html index 4cddb4437..914940086 100644 --- a/demos/tooltip/tracking.html +++ b/demos/tooltip/tracking.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tooltip - Track the mouse</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/tooltip/video-player.html b/demos/tooltip/video-player.html index 1d8458abb..6ff4d2d51 100644 --- a/demos/tooltip/video-player.html +++ b/demos/tooltip/video-player.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Tooltip - Video Player demo</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> diff --git a/demos/widget/default.html b/demos/widget/default.html index c2b520983..4dad912c2 100644 --- a/demos/widget/default.html +++ b/demos/widget/default.html @@ -4,17 +4,25 @@ <meta charset="utf-8"> <title>jQuery UI Widget - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.5.1.js"></script> + <script src="../../jquery-1.6.2.js"></script> <script src="../../ui/jquery.ui.core.js"></script> - <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.position.js"></script> + <script src="../../ui/jquery.ui.widget.js"></script> + <script src="../../ui/jquery.ui.button.js"></script> <link rel="stylesheet" href="../demos.css"> <style> .custom-colorize { - font-size: 25px; + font-size: 20px; + position: relative; width: 75px; height: 75px; } + .custom-colorize-changer { + font-size: 10px; + position: absolute; + right: 0; + bottom: 0; + } </style> <script> $(function() { @@ -40,8 +48,15 @@ // prevent double click to select text .disableSelection(); - // bind click events to random method - this._bind({ + this.changer = $( "<button>", { + text: "change", + className: "custom-colorize-changer" + }) + .appendTo( this.element ) + .button(); + + // bind click events on the changer button to the random method + this._bind( this.changer, { // _bind won't call random when widget is disabled click: "random" }); @@ -78,6 +93,9 @@ // events bound via _bind are removed automatically // revert other modifications here _destroy: function() { + // remove generated elements + this.changer.remove(); + this.element .removeClass( "custom-colorize" ) .enableSelection() diff --git a/jquery-1.5.1.js b/jquery-1.6.2.js index 78fcfa469..f3201aacb 100644 --- a/jquery-1.5.1.js +++ b/jquery-1.6.2.js @@ -1,5 +1,5 @@ /*! - * jQuery JavaScript Library v1.5.1 + * jQuery JavaScript Library v1.6.2 * http://jquery.com/ * * Copyright 2011, John Resig @@ -11,12 +11,14 @@ * Copyright 2011, The Dojo Foundation * Released under the MIT, BSD, and GPL Licenses. * - * Date: Wed Feb 23 13:55:29 2011 -0500 + * Date: Thu Jun 30 14:16:56 2011 -0400 */ (function( window, undefined ) { // Use the correct document accordingly with window argument (sandbox) -var document = window.document; +var document = window.document, + navigator = window.navigator, + location = window.location; var jQuery = (function() { // Define a local copy of jQuery @@ -36,7 +38,7 @@ var jQuery = function( selector, context ) { // A simple way to check for HTML strings or ID strings // (both of which we optimize for) - quickExpr = /^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]+)$)/, + quickExpr = /^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/, // Check if a string has a non-whitespace character in it rnotwhite = /\S/, @@ -63,21 +65,23 @@ var jQuery = function( selector, context ) { rmsie = /(msie) ([\w.]+)/, rmozilla = /(mozilla)(?:.*? rv:([\w.]+))?/, + // Matches dashed string for camelizing + rdashAlpha = /-([a-z])/ig, + + // Used by jQuery.camelCase as callback to replace() + fcamelCase = function( all, letter ) { + return letter.toUpperCase(); + }, + // Keep a UserAgent string for use with jQuery.browser userAgent = navigator.userAgent, // For matching the engine and version of the browser browserMatch, - // Has the ready events already been bound? - readyBound = false, - // The deferred used on DOM ready readyList, - // Promise methods - promiseMethods = "then done fail isResolved isRejected promise".split( " " ), - // The ready event handler DOMContentLoaded, @@ -113,7 +117,7 @@ jQuery.fn = jQuery.prototype = { if ( selector === "body" && !context && document.body ) { this.context = document; this[0] = document.body; - this.selector = "body"; + this.selector = selector; this.length = 1; return this; } @@ -121,7 +125,13 @@ jQuery.fn = jQuery.prototype = { // Handle HTML strings if ( typeof selector === "string" ) { // Are we dealing with HTML string or an ID? - match = quickExpr.exec( selector ); + if ( selector.charAt(0) === "<" && selector.charAt( selector.length - 1 ) === ">" && selector.length >= 3 ) { + // Assume that strings that start and end with <> are HTML and skip the regex check + match = [ null, selector, null ]; + + } else { + match = quickExpr.exec( selector ); + } // Verify a match, and that no context was specified for #id if ( match && (match[1] || !context) ) { @@ -202,7 +212,7 @@ jQuery.fn = jQuery.prototype = { selector: "", // The current version of jQuery being used - jquery: "1.5.1", + jquery: "1.6.2", // The default length of a jQuery object is 0 length: 0, @@ -378,9 +388,11 @@ jQuery.extend = jQuery.fn.extend = function() { jQuery.extend({ noConflict: function( deep ) { - window.$ = _$; + if ( window.$ === jQuery ) { + window.$ = _$; + } - if ( deep ) { + if ( deep && window.jQuery === jQuery ) { window.jQuery = _jQuery; } @@ -394,15 +406,19 @@ jQuery.extend({ // the ready event fires. See #6781 readyWait: 1, - // Handle when the DOM is ready - ready: function( wait ) { - // A third-party is pushing the ready event forwards - if ( wait === true ) { - jQuery.readyWait--; + // Hold (or release) the ready event + holdReady: function( hold ) { + if ( hold ) { + jQuery.readyWait++; + } else { + jQuery.ready( true ); } + }, - // Make sure that the DOM is not already loaded - if ( !jQuery.readyWait || (wait !== true && !jQuery.isReady) ) { + // Handle when the DOM is ready + ready: function( wait ) { + // Either a released hold or an DOMready/load event and not yet ready + if ( (wait === true && !--jQuery.readyWait) || (wait !== true && !jQuery.isReady) ) { // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). if ( !document.body ) { return setTimeout( jQuery.ready, 1 ); @@ -427,11 +443,11 @@ jQuery.extend({ }, bindReady: function() { - if ( readyBound ) { + if ( readyList ) { return; } - readyBound = true; + readyList = jQuery._Deferred(); // Catch cases where $(document).ready() is called after the // browser event has already occurred. @@ -452,7 +468,7 @@ jQuery.extend({ } else if ( document.attachEvent ) { // ensure firing before onload, // maybe late but safe also for iframes - document.attachEvent("onreadystatechange", DOMContentLoaded); + document.attachEvent( "onreadystatechange", DOMContentLoaded ); // A fallback to window.onload, that will always work window.attachEvent( "onload", jQuery.ready ); @@ -540,20 +556,21 @@ jQuery.extend({ // Make sure leading/trailing whitespace is removed (IE can't handle it) data = jQuery.trim( data ); + // Attempt to parse using the native JSON parser first + if ( window.JSON && window.JSON.parse ) { + return window.JSON.parse( data ); + } + // Make sure the incoming data is actual JSON // Logic borrowed from http://json.org/json2.js - if ( rvalidchars.test(data.replace(rvalidescape, "@") - .replace(rvalidtokens, "]") - .replace(rvalidbraces, "")) ) { + if ( rvalidchars.test( data.replace( rvalidescape, "@" ) + .replace( rvalidtokens, "]" ) + .replace( rvalidbraces, "")) ) { - // Try to use the native JSON parser first - return window.JSON && window.JSON.parse ? - window.JSON.parse( data ) : - (new Function("return " + data))(); + return (new Function( "return " + data ))(); - } else { - jQuery.error( "Invalid JSON: " + data ); } + jQuery.error( "Invalid JSON: " + data ); }, // Cross-browser xml parsing @@ -580,27 +597,26 @@ jQuery.extend({ noop: function() {}, - // Evalulates a script in a global context + // Evaluates a script in a global context + // Workarounds based on findings by Jim Driscoll + // http://weblogs.java.net/blog/driscoll/archive/2009/09/08/eval-javascript-global-context globalEval: function( data ) { - if ( data && rnotwhite.test(data) ) { - // Inspired by code by Andrea Giammarchi - // http://webreflection.blogspot.com/2007/08/global-scope-evaluation-and-dom.html - var head = document.head || document.getElementsByTagName( "head" )[0] || document.documentElement, - script = document.createElement( "script" ); - - if ( jQuery.support.scriptEval() ) { - script.appendChild( document.createTextNode( data ) ); - } else { - script.text = data; - } - - // Use insertBefore instead of appendChild to circumvent an IE6 bug. - // This arises when a base node is used (#2709). - head.insertBefore( script, head.firstChild ); - head.removeChild( script ); + if ( data && rnotwhite.test( data ) ) { + // We use execScript on Internet Explorer + // We use an anonymous function so that context is window + // rather than jQuery in Firefox + ( window.execScript || function( data ) { + window[ "eval" ].call( window, data ); + } )( data ); } }, + // Converts a dashed string to camelCased string; + // Used by both the css and data modules + camelCase: function( string ) { + return string.replace( rdashAlpha, fcamelCase ); + }, + nodeName: function( elem, name ) { return elem.nodeName && elem.nodeName.toUpperCase() === name.toUpperCase(); }, @@ -609,7 +625,7 @@ jQuery.extend({ each: function( object, callback, args ) { var name, i = 0, length = object.length, - isObj = length === undefined || jQuery.isFunction(object); + isObj = length === undefined || jQuery.isFunction( object ); if ( args ) { if ( isObj ) { @@ -635,8 +651,11 @@ jQuery.extend({ } } } else { - for ( var value = object[0]; - i < length && callback.call( value, i, value ) !== false; value = object[++i] ) {} + for ( ; i < length; ) { + if ( callback.call( object[ i ], i, object[ i++ ] ) === false ) { + break; + } + } } } @@ -667,7 +686,7 @@ jQuery.extend({ // The extra typeof function check is to prevent crashes // in Safari 2 (See: #3039) // Tweaked logic slightly to handle Blackberry 4.7 RegExp issues #6930 - var type = jQuery.type(array); + var type = jQuery.type( array ); if ( array.length == null || type === "string" || type === "function" || type === "regexp" || jQuery.isWindow( array ) ) { push.call( ret, array ); @@ -680,8 +699,9 @@ jQuery.extend({ }, inArray: function( elem, array ) { - if ( array.indexOf ) { - return array.indexOf( elem ); + + if ( indexOf ) { + return indexOf.call( array, elem ); } for ( var i = 0, length = array.length; i < length; i++ ) { @@ -731,15 +751,30 @@ jQuery.extend({ // arg is for internal usage only map: function( elems, callback, arg ) { - var ret = [], value; + var value, key, ret = [], + i = 0, + length = elems.length, + // jquery objects are treated as arrays + isArray = elems instanceof jQuery || length !== undefined && typeof length === "number" && ( ( length > 0 && elems[ 0 ] && elems[ length -1 ] ) || length === 0 || jQuery.isArray( elems ) ) ; // Go through the array, translating each of the items to their - // new value (or values). - for ( var i = 0, length = elems.length; i < length; i++ ) { - value = callback( elems[ i ], i, arg ); + if ( isArray ) { + for ( ; i < length; i++ ) { + value = callback( elems[ i ], i, arg ); + + if ( value != null ) { + ret[ ret.length ] = value; + } + } + + // Go through every key on the object, + } else { + for ( key in elems ) { + value = callback( elems[ key ], key, arg ); - if ( value != null ) { - ret[ ret.length ] = value; + if ( value != null ) { + ret[ ret.length ] = value; + } } } @@ -750,36 +785,35 @@ jQuery.extend({ // A global GUID counter for objects guid: 1, - proxy: function( fn, proxy, thisObject ) { - if ( arguments.length === 2 ) { - if ( typeof proxy === "string" ) { - thisObject = fn; - fn = thisObject[ proxy ]; - proxy = undefined; + // Bind a function to a context, optionally partially applying any + // arguments. + proxy: function( fn, context ) { + if ( typeof context === "string" ) { + var tmp = fn[ context ]; + context = fn; + fn = tmp; + } - } else if ( proxy && !jQuery.isFunction( proxy ) ) { - thisObject = proxy; - proxy = undefined; - } + // Quick check to determine if target is callable, in the spec + // this throws a TypeError, but we will just return undefined. + if ( !jQuery.isFunction( fn ) ) { + return undefined; } - if ( !proxy && fn ) { + // Simulated bind + var args = slice.call( arguments, 2 ), proxy = function() { - return fn.apply( thisObject || this, arguments ); + return fn.apply( context, args.concat( slice.call( arguments ) ) ); }; - } // Set the guid of unique handler to the same of original handler, so it can be removed - if ( fn ) { - proxy.guid = fn.guid = fn.guid || proxy.guid || jQuery.guid++; - } + proxy.guid = fn.guid = fn.guid || proxy.guid || jQuery.guid++; - // So proxy can be declared as an argument return proxy; }, // Mutifunctional method to get and set values to a collection - // The value/s can be optionally by executed if its a function + // The value/s can optionally be executed if it's a function access: function( elems, key, value, exec, fn, pass ) { var length = elems.length; @@ -811,6 +845,116 @@ jQuery.extend({ return (new Date()).getTime(); }, + // Use of jQuery.browser is frowned upon. + // More details: http://docs.jquery.com/Utilities/jQuery.browser + uaMatch: function( ua ) { + ua = ua.toLowerCase(); + + var match = rwebkit.exec( ua ) || + ropera.exec( ua ) || + rmsie.exec( ua ) || + ua.indexOf("compatible") < 0 && rmozilla.exec( ua ) || + []; + + return { browser: match[1] || "", version: match[2] || "0" }; + }, + + sub: function() { + function jQuerySub( selector, context ) { + return new jQuerySub.fn.init( selector, context ); + } + jQuery.extend( true, jQuerySub, this ); + jQuerySub.superclass = this; + jQuerySub.fn = jQuerySub.prototype = this(); + jQuerySub.fn.constructor = jQuerySub; + jQuerySub.sub = this.sub; + jQuerySub.fn.init = function init( selector, context ) { + if ( context && context instanceof jQuery && !(context instanceof jQuerySub) ) { + context = jQuerySub( context ); + } + + return jQuery.fn.init.call( this, selector, context, rootjQuerySub ); + }; + jQuerySub.fn.init.prototype = jQuerySub.fn; + var rootjQuerySub = jQuerySub(document); + return jQuerySub; + }, + + browser: {} +}); + +// Populate the class2type map +jQuery.each("Boolean Number String Function Array Date RegExp Object".split(" "), function(i, name) { + class2type[ "[object " + name + "]" ] = name.toLowerCase(); +}); + +browserMatch = jQuery.uaMatch( userAgent ); +if ( browserMatch.browser ) { + jQuery.browser[ browserMatch.browser ] = true; + jQuery.browser.version = browserMatch.version; +} + +// Deprecated, use jQuery.browser.webkit instead +if ( jQuery.browser.webkit ) { + jQuery.browser.safari = true; +} + +// IE doesn't match non-breaking spaces with \s +if ( rnotwhite.test( "\xA0" ) ) { + trimLeft = /^[\s\xA0]+/; + trimRight = /[\s\xA0]+$/; +} + +// All jQuery objects should point back to these +rootjQuery = jQuery(document); + +// Cleanup functions for the document ready method +if ( document.addEventListener ) { + DOMContentLoaded = function() { + document.removeEventListener( "DOMContentLoaded", DOMContentLoaded, false ); + jQuery.ready(); + }; + +} else if ( document.attachEvent ) { + DOMContentLoaded = function() { + // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). + if ( document.readyState === "complete" ) { + document.detachEvent( "onreadystatechange", DOMContentLoaded ); + jQuery.ready(); + } + }; +} + +// The DOM ready check for Internet Explorer +function doScrollCheck() { + if ( jQuery.isReady ) { + return; + } + + try { + // If IE is used, use the trick by Diego Perini + // http://javascript.nwbox.com/IEContentLoaded/ + document.documentElement.doScroll("left"); + } catch(e) { + setTimeout( doScrollCheck, 1 ); + return; + } + + // and execute any waiting functions + jQuery.ready(); +} + +return jQuery; + +})(); + + +var // Promise methods + promiseMethods = "done fail isResolved isRejected promise then always pipe".split( " " ), + // Static reference to slice + sliceDeferred = [].slice; + +jQuery.extend({ // Create a simple deferred (one callbacks list) _Deferred: function() { var // callbacks list @@ -856,18 +1000,14 @@ jQuery.extend({ // resolve with given context and args resolveWith: function( context, args ) { if ( !cancelled && !fired && !firing ) { + // make sure args are available (#8421) + args = args || []; firing = 1; try { while( callbacks[ 0 ] ) { callbacks.shift().apply( context, args ); } } - // We have to add a catch block for - // IE prior to 8 or else the finally - // block will never get executed - catch (e) { - throw e; - } finally { fired = [ context, args ]; firing = 0; @@ -878,7 +1018,7 @@ jQuery.extend({ // resolve with this as context and given arguments resolve: function() { - deferred.resolveWith( jQuery.isFunction( this.promise ) ? this.promise() : this, arguments ); + deferred.resolveWith( this, arguments ); return this; }, @@ -909,10 +1049,37 @@ jQuery.extend({ deferred.done( doneCallbacks ).fail( failCallbacks ); return this; }, + always: function() { + return deferred.done.apply( deferred, arguments ).fail.apply( this, arguments ); + }, fail: failDeferred.done, rejectWith: failDeferred.resolveWith, reject: failDeferred.resolve, isRejected: failDeferred.isResolved, + pipe: function( fnDone, fnFail ) { + return jQuery.Deferred(function( newDefer ) { + jQuery.each( { + done: [ fnDone, "resolve" ], + fail: [ fnFail, "reject" ] + }, function( handler, data ) { + var fn = data[ 0 ], + action = data[ 1 ], + returned; + if ( jQuery.isFunction( fn ) ) { + deferred[ handler ](function() { + returned = fn.apply( this, arguments ); + if ( returned && jQuery.isFunction( returned.promise ) ) { + returned.promise().then( newDefer.resolve, newDefer.reject ); + } else { + newDefer[ action ]( returned ); + } + }); + } else { + deferred[ handler ]( newDefer[ action ] ); + } + }); + }).promise(); + }, // Get a promise for this deferred // If obj is provided, the promise aspect is added to the object promise: function( obj ) { @@ -928,7 +1095,7 @@ jQuery.extend({ } return obj; } - } ); + }); // Make sure only one callback list will be used deferred.done( failDeferred.cancel ).fail( deferred.cancel ); // Unexpose cancel @@ -941,194 +1108,103 @@ jQuery.extend({ }, // Deferred helper - when: function( object ) { - var lastIndex = arguments.length, - deferred = lastIndex <= 1 && object && jQuery.isFunction( object.promise ) ? - object : - jQuery.Deferred(), - promise = deferred.promise(); - - if ( lastIndex > 1 ) { - var array = slice.call( arguments, 0 ), - count = lastIndex, - iCallback = function( index ) { - return function( value ) { - array[ index ] = arguments.length > 1 ? slice.call( arguments, 0 ) : value; - if ( !( --count ) ) { - deferred.resolveWith( promise, array ); - } - }; - }; - while( ( lastIndex-- ) ) { - object = array[ lastIndex ]; - if ( object && jQuery.isFunction( object.promise ) ) { - object.promise().then( iCallback(lastIndex), deferred.reject ); + when: function( firstParam ) { + var args = arguments, + i = 0, + length = args.length, + count = length, + deferred = length <= 1 && firstParam && jQuery.isFunction( firstParam.promise ) ? + firstParam : + jQuery.Deferred(); + function resolveFunc( i ) { + return function( value ) { + args[ i ] = arguments.length > 1 ? sliceDeferred.call( arguments, 0 ) : value; + if ( !( --count ) ) { + // Strange bug in FF4: + // Values changed onto the arguments object sometimes end up as undefined values + // outside the $.when method. Cloning the object into a fresh array solves the issue + deferred.resolveWith( deferred, sliceDeferred.call( args, 0 ) ); + } + }; + } + if ( length > 1 ) { + for( ; i < length; i++ ) { + if ( args[ i ] && jQuery.isFunction( args[ i ].promise ) ) { + args[ i ].promise().then( resolveFunc(i), deferred.reject ); } else { --count; } } if ( !count ) { - deferred.resolveWith( promise, array ); - } - } else if ( deferred !== object ) { - deferred.resolve( object ); - } - return promise; - }, - - // Use of jQuery.browser is frowned upon. - // More details: http://docs.jquery.com/Utilities/jQuery.browser - uaMatch: function( ua ) { - ua = ua.toLowerCase(); - - var match = rwebkit.exec( ua ) || - ropera.exec( ua ) || - rmsie.exec( ua ) || - ua.indexOf("compatible") < 0 && rmozilla.exec( ua ) || - []; - - return { browser: match[1] || "", version: match[2] || "0" }; - }, - - sub: function() { - function jQuerySubclass( selector, context ) { - return new jQuerySubclass.fn.init( selector, context ); - } - jQuery.extend( true, jQuerySubclass, this ); - jQuerySubclass.superclass = this; - jQuerySubclass.fn = jQuerySubclass.prototype = this(); - jQuerySubclass.fn.constructor = jQuerySubclass; - jQuerySubclass.subclass = this.subclass; - jQuerySubclass.fn.init = function init( selector, context ) { - if ( context && context instanceof jQuery && !(context instanceof jQuerySubclass) ) { - context = jQuerySubclass(context); + deferred.resolveWith( deferred, args ); } - - return jQuery.fn.init.call( this, selector, context, rootjQuerySubclass ); - }; - jQuerySubclass.fn.init.prototype = jQuerySubclass.fn; - var rootjQuerySubclass = jQuerySubclass(document); - return jQuerySubclass; - }, - - browser: {} -}); - -// Create readyList deferred -readyList = jQuery._Deferred(); - -// Populate the class2type map -jQuery.each("Boolean Number String Function Array Date RegExp Object".split(" "), function(i, name) { - class2type[ "[object " + name + "]" ] = name.toLowerCase(); -}); - -browserMatch = jQuery.uaMatch( userAgent ); -if ( browserMatch.browser ) { - jQuery.browser[ browserMatch.browser ] = true; - jQuery.browser.version = browserMatch.version; -} - -// Deprecated, use jQuery.browser.webkit instead -if ( jQuery.browser.webkit ) { - jQuery.browser.safari = true; -} - -if ( indexOf ) { - jQuery.inArray = function( elem, array ) { - return indexOf.call( array, elem ); - }; -} - -// IE doesn't match non-breaking spaces with \s -if ( rnotwhite.test( "\xA0" ) ) { - trimLeft = /^[\s\xA0]+/; - trimRight = /[\s\xA0]+$/; -} - -// All jQuery objects should point back to these -rootjQuery = jQuery(document); - -// Cleanup functions for the document ready method -if ( document.addEventListener ) { - DOMContentLoaded = function() { - document.removeEventListener( "DOMContentLoaded", DOMContentLoaded, false ); - jQuery.ready(); - }; - -} else if ( document.attachEvent ) { - DOMContentLoaded = function() { - // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443). - if ( document.readyState === "complete" ) { - document.detachEvent( "onreadystatechange", DOMContentLoaded ); - jQuery.ready(); + } else if ( deferred !== firstParam ) { + deferred.resolveWith( deferred, length ? [ firstParam ] : [] ); } - }; -} - -// The DOM ready check for Internet Explorer -function doScrollCheck() { - if ( jQuery.isReady ) { - return; + return deferred.promise(); } +}); - try { - // If IE is used, use the trick by Diego Perini - // http://javascript.nwbox.com/IEContentLoaded/ - document.documentElement.doScroll("left"); - } catch(e) { - setTimeout( doScrollCheck, 1 ); - return; - } - - // and execute any waiting functions - jQuery.ready(); -} - -// Expose jQuery to the global object -return jQuery; - -})(); - - -(function() { - jQuery.support = {}; - var div = document.createElement("div"); +jQuery.support = (function() { + + var div = document.createElement( "div" ), + documentElement = document.documentElement, + all, + a, + select, + opt, + input, + marginDiv, + support, + fragment, + body, + testElementParent, + testElement, + testElementStyle, + tds, + events, + eventName, + i, + isSupported; - div.style.display = "none"; - div.innerHTML = " <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>"; + // Preliminary tests + div.setAttribute("className", "t"); + div.innerHTML = " <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>"; - var all = div.getElementsByTagName("*"), - a = div.getElementsByTagName("a")[0], - select = document.createElement("select"), - opt = select.appendChild( document.createElement("option") ), - input = div.getElementsByTagName("input")[0]; + all = div.getElementsByTagName( "*" ); + a = div.getElementsByTagName( "a" )[ 0 ]; // Can't get basic test support if ( !all || !all.length || !a ) { - return; + return {}; } - jQuery.support = { + // First batch of supports tests + select = document.createElement( "select" ); + opt = select.appendChild( document.createElement("option") ); + input = div.getElementsByTagName( "input" )[ 0 ]; + + support = { // IE strips leading whitespace when .innerHTML is used - leadingWhitespace: div.firstChild.nodeType === 3, + leadingWhitespace: ( div.firstChild.nodeType === 3 ), // Make sure that tbody elements aren't automatically inserted // IE will insert them into empty tables - tbody: !div.getElementsByTagName("tbody").length, + tbody: !div.getElementsByTagName( "tbody" ).length, // Make sure that link elements get serialized correctly by innerHTML // This requires a wrapper element in IE - htmlSerialize: !!div.getElementsByTagName("link").length, + htmlSerialize: !!div.getElementsByTagName( "link" ).length, // Get the style information from getAttribute - // (IE uses .cssText insted) - style: /red/.test( a.getAttribute("style") ), + // (IE uses .cssText instead) + style: /top/.test( a.getAttribute("style") ), // Make sure that URLs aren't manipulated // (IE normalizes it by default) - hrefNormalized: a.getAttribute("href") === "/a", + hrefNormalized: ( a.getAttribute( "href" ) === "/a" ), // Make sure that element opacity exists // (IE uses filter instead) @@ -1142,180 +1218,193 @@ return jQuery; // Make sure that if no value is specified for a checkbox // that it defaults to "on". // (WebKit defaults to "" instead) - checkOn: input.value === "on", + checkOn: ( input.value === "on" ), // Make sure that a selected-by-default option has a working selected property. // (WebKit defaults to false instead of true, IE too, if it's in an optgroup) optSelected: opt.selected, + // Test setAttribute on camelCase class. If it works, we need attrFixes when doing get/setAttribute (ie6/7) + getSetAttribute: div.className !== "t", + // Will be defined later + submitBubbles: true, + changeBubbles: true, + focusinBubbles: false, deleteExpando: true, - optDisabled: false, - checkClone: false, noCloneEvent: true, - noCloneChecked: true, - boxModel: null, inlineBlockNeedsLayout: false, shrinkWrapBlocks: false, - reliableHiddenOffsets: true + reliableMarginRight: true }; + // Make sure checked status is properly cloned input.checked = true; - jQuery.support.noCloneChecked = input.cloneNode( true ).checked; + support.noCloneChecked = input.cloneNode( true ).checked; // Make sure that the options inside disabled selects aren't marked as disabled - // (WebKit marks them as diabled) + // (WebKit marks them as disabled) select.disabled = true; - jQuery.support.optDisabled = !opt.disabled; - - var _scriptEval = null; - jQuery.support.scriptEval = function() { - if ( _scriptEval === null ) { - var root = document.documentElement, - script = document.createElement("script"), - id = "script" + jQuery.now(); - - try { - script.appendChild( document.createTextNode( "window." + id + "=1;" ) ); - } catch(e) {} - - root.insertBefore( script, root.firstChild ); - - // Make sure that the execution of code works by injecting a script - // tag with appendChild/createTextNode - // (IE doesn't support this, fails, and uses .text instead) - if ( window[ id ] ) { - _scriptEval = true; - delete window[ id ]; - } else { - _scriptEval = false; - } - - root.removeChild( script ); - // release memory in IE - root = script = id = null; - } - - return _scriptEval; - }; + support.optDisabled = !opt.disabled; // Test to see if it's possible to delete an expando from an element // Fails in Internet Explorer try { delete div.test; - - } catch(e) { - jQuery.support.deleteExpando = false; + } catch( e ) { + support.deleteExpando = false; } if ( !div.addEventListener && div.attachEvent && div.fireEvent ) { - div.attachEvent("onclick", function click() { + div.attachEvent( "onclick", function() { // Cloning a node shouldn't copy over any // bound event handlers (IE does this) - jQuery.support.noCloneEvent = false; - div.detachEvent("onclick", click); + support.noCloneEvent = false; }); - div.cloneNode(true).fireEvent("onclick"); + div.cloneNode( true ).fireEvent( "onclick" ); } - div = document.createElement("div"); - div.innerHTML = "<input type='radio' name='radiotest' checked='checked'/>"; + // Check if a radio maintains it's value + // after being appended to the DOM + input = document.createElement("input"); + input.value = "t"; + input.setAttribute("type", "radio"); + support.radioValue = input.value === "t"; - var fragment = document.createDocumentFragment(); + input.setAttribute("checked", "checked"); + div.appendChild( input ); + fragment = document.createDocumentFragment(); fragment.appendChild( div.firstChild ); // WebKit doesn't clone checked state correctly in fragments - jQuery.support.checkClone = fragment.cloneNode(true).cloneNode(true).lastChild.checked; + support.checkClone = fragment.cloneNode( true ).cloneNode( true ).lastChild.checked; + + div.innerHTML = ""; // Figure out if the W3C box model works as expected - // document.body must exist before we can do this - jQuery(function() { - var div = document.createElement("div"), - body = document.getElementsByTagName("body")[0]; + div.style.width = div.style.paddingLeft = "1px"; + + body = document.getElementsByTagName( "body" )[ 0 ]; + // We use our own, invisible, body unless the body is already present + // in which case we use a div (#9239) + testElement = document.createElement( body ? "div" : "body" ); + testElementStyle = { + visibility: "hidden", + width: 0, + height: 0, + border: 0, + margin: 0 + }; + if ( body ) { + jQuery.extend( testElementStyle, { + position: "absolute", + left: -1000, + top: -1000 + }); + } + for ( i in testElementStyle ) { + testElement.style[ i ] = testElementStyle[ i ]; + } + testElement.appendChild( div ); + testElementParent = body || documentElement; + testElementParent.insertBefore( testElement, testElementParent.firstChild ); + + // Check if a disconnected checkbox will retain its checked + // value of true after appended to the DOM (IE6/7) + support.appendChecked = input.checked; + + support.boxModel = div.offsetWidth === 2; + + if ( "zoom" in div.style ) { + // Check if natively block-level elements act like inline-block + // elements when setting their display to 'inline' and giving + // them layout + // (IE < 8 does this) + div.style.display = "inline"; + div.style.zoom = 1; + support.inlineBlockNeedsLayout = ( div.offsetWidth === 2 ); + + // Check if elements with layout shrink-wrap their children + // (IE 6 does this) + div.style.display = ""; + div.innerHTML = "<div style='width:4px;'></div>"; + support.shrinkWrapBlocks = ( div.offsetWidth !== 2 ); + } - // Frameset documents with no body should not run this code - if ( !body ) { - return; - } + div.innerHTML = "<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>"; + tds = div.getElementsByTagName( "td" ); + + // Check if table cells still have offsetWidth/Height when they are set + // to display:none and there are still other visible table cells in a + // table row; if so, offsetWidth/Height are not reliable for use when + // determining if an element has been hidden directly using + // display:none (it is still safe to use offsets if a parent element is + // hidden; don safety goggles and see bug #4512 for more information). + // (only IE 8 fails this test) + isSupported = ( tds[ 0 ].offsetHeight === 0 ); + + tds[ 0 ].style.display = ""; + tds[ 1 ].style.display = "none"; + + // Check if empty table cells still have offsetWidth/Height + // (IE < 8 fail this test) + support.reliableHiddenOffsets = isSupported && ( tds[ 0 ].offsetHeight === 0 ); + div.innerHTML = ""; + + // Check if div with explicit width and no margin-right incorrectly + // gets computed margin-right based on width of container. For more + // info see bug #3333 + // Fails in WebKit before Feb 2011 nightlies + // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right + if ( document.defaultView && document.defaultView.getComputedStyle ) { + marginDiv = document.createElement( "div" ); + marginDiv.style.width = "0"; + marginDiv.style.marginRight = "0"; + div.appendChild( marginDiv ); + support.reliableMarginRight = + ( parseInt( ( document.defaultView.getComputedStyle( marginDiv, null ) || { marginRight: 0 } ).marginRight, 10 ) || 0 ) === 0; + } - div.style.width = div.style.paddingLeft = "1px"; - body.appendChild( div ); - jQuery.boxModel = jQuery.support.boxModel = div.offsetWidth === 2; - - if ( "zoom" in div.style ) { - // Check if natively block-level elements act like inline-block - // elements when setting their display to 'inline' and giving - // them layout - // (IE < 8 does this) - div.style.display = "inline"; - div.style.zoom = 1; - jQuery.support.inlineBlockNeedsLayout = div.offsetWidth === 2; - - // Check if elements with layout shrink-wrap their children - // (IE 6 does this) - div.style.display = ""; - div.innerHTML = "<div style='width:4px;'></div>"; - jQuery.support.shrinkWrapBlocks = div.offsetWidth !== 2; - } - - div.innerHTML = "<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>"; - var tds = div.getElementsByTagName("td"); - - // Check if table cells still have offsetWidth/Height when they are set - // to display:none and there are still other visible table cells in a - // table row; if so, offsetWidth/Height are not reliable for use when - // determining if an element has been hidden directly using - // display:none (it is still safe to use offsets if a parent element is - // hidden; don safety goggles and see bug #4512 for more information). - // (only IE 8 fails this test) - jQuery.support.reliableHiddenOffsets = tds[0].offsetHeight === 0; - - tds[0].style.display = ""; - tds[1].style.display = "none"; - - // Check if empty table cells still have offsetWidth/Height - // (IE < 8 fail this test) - jQuery.support.reliableHiddenOffsets = jQuery.support.reliableHiddenOffsets && tds[0].offsetHeight === 0; - div.innerHTML = ""; - - body.removeChild( div ).style.display = "none"; - div = tds = null; - }); + // Remove the body element we added + testElement.innerHTML = ""; + testElementParent.removeChild( testElement ); // Technique from Juriy Zaytsev // http://thinkweb2.com/projects/prototype/detecting-event-support-without-browser-sniffing/ - var eventSupported = function( eventName ) { - var el = document.createElement("div"); - eventName = "on" + eventName; - - // We only care about the case where non-standard event systems - // are used, namely in IE. Short-circuiting here helps us to - // avoid an eval call (in setAttribute) which can cause CSP - // to go haywire. See: https://developer.mozilla.org/en/Security/CSP - if ( !el.attachEvent ) { - return true; + // We only care about the case where non-standard event systems + // are used, namely in IE. Short-circuiting here helps us to + // avoid an eval call (in setAttribute) which can cause CSP + // to go haywire. See: https://developer.mozilla.org/en/Security/CSP + if ( div.attachEvent ) { + for( i in { + submit: 1, + change: 1, + focusin: 1 + } ) { + eventName = "on" + i; + isSupported = ( eventName in div ); + if ( !isSupported ) { + div.setAttribute( eventName, "return;" ); + isSupported = ( typeof div[ eventName ] === "function" ); + } + support[ i + "Bubbles" ] = isSupported; } + } - var isSupported = (eventName in el); - if ( !isSupported ) { - el.setAttribute(eventName, "return;"); - isSupported = typeof el[eventName] === "function"; - } - el = null; + // Null connected elements to avoid leaks in IE + testElement = fragment = select = opt = body = marginDiv = div = input = null; - return isSupported; - }; + return support; +})(); - jQuery.support.submitBubbles = eventSupported("submit"); - jQuery.support.changeBubbles = eventSupported("change"); +// Keep track of boxModel +jQuery.boxModel = jQuery.support.boxModel; - // release memory in IE - div = all = a = null; -})(); -var rbrace = /^(?:\{.*\}|\[.*\])$/; +var rbrace = /^(?:\{.*\}|\[.*\])$/, + rmultiDash = /([a-z])([A-Z])/g; jQuery.extend({ cache: {}, @@ -1412,7 +1501,7 @@ jQuery.extend({ } if ( data !== undefined ) { - thisCache[ name ] = data; + thisCache[ jQuery.camelCase( name ) ] = data; } // TODO: This is a hack for 1.5 ONLY. It will be removed in 1.6. Users should @@ -1422,7 +1511,10 @@ jQuery.extend({ return thisCache[ internalKey ] && thisCache[ internalKey ].events; } - return getByName ? thisCache[ name ] : thisCache; + return getByName ? + // Check for both converted-to-camel and non-converted data property names + thisCache[ jQuery.camelCase( name ) ] || thisCache[ name ] : + thisCache; }, removeData: function( elem, name, pvt /* Internal Use Only */ ) { @@ -1538,12 +1630,13 @@ jQuery.fn.extend({ data = jQuery.data( this[0] ); if ( this[0].nodeType === 1 ) { - var attr = this[0].attributes, name; + var attr = this[0].attributes, name; for ( var i = 0, l = attr.length; i < l; i++ ) { name = attr[i].name; if ( name.indexOf( "data-" ) === 0 ) { - name = name.substr( 5 ); + name = jQuery.camelCase( name.substring(5) ); + dataAttr( this[0], name, data[ name ] ); } } @@ -1597,7 +1690,9 @@ function dataAttr( elem, key, data ) { // If nothing was found internally, try to fetch any // data from the HTML5 data-* attribute if ( data === undefined && elem.nodeType === 1 ) { - data = elem.getAttribute( "data-" + key ); + var name = "data-" + key.replace( rmultiDash, "$1-$2" ).toLowerCase(); + + data = elem.getAttribute( name ); if ( typeof data === "string" ) { try { @@ -1636,35 +1731,76 @@ function isEmptyDataObject( obj ) { -jQuery.extend({ - queue: function( elem, type, data ) { - if ( !elem ) { - return; - } +function handleQueueMarkDefer( elem, type, src ) { + var deferDataKey = type + "defer", + queueDataKey = type + "queue", + markDataKey = type + "mark", + defer = jQuery.data( elem, deferDataKey, undefined, true ); + if ( defer && + ( src === "queue" || !jQuery.data( elem, queueDataKey, undefined, true ) ) && + ( src === "mark" || !jQuery.data( elem, markDataKey, undefined, true ) ) ) { + // Give room for hard-coded callbacks to fire first + // and eventually mark/queue something else on the element + setTimeout( function() { + if ( !jQuery.data( elem, queueDataKey, undefined, true ) && + !jQuery.data( elem, markDataKey, undefined, true ) ) { + jQuery.removeData( elem, deferDataKey, true ); + defer.resolve(); + } + }, 0 ); + } +} - type = (type || "fx") + "queue"; - var q = jQuery._data( elem, type ); +jQuery.extend({ - // Speed up dequeue by getting out quickly if this is just a lookup - if ( !data ) { - return q || []; + _mark: function( elem, type ) { + if ( elem ) { + type = (type || "fx") + "mark"; + jQuery.data( elem, type, (jQuery.data(elem,type,undefined,true) || 0) + 1, true ); } + }, - if ( !q || jQuery.isArray(data) ) { - q = jQuery._data( elem, type, jQuery.makeArray(data) ); - - } else { - q.push( data ); + _unmark: function( force, elem, type ) { + if ( force !== true ) { + type = elem; + elem = force; + force = false; + } + if ( elem ) { + type = type || "fx"; + var key = type + "mark", + count = force ? 0 : ( (jQuery.data( elem, key, undefined, true) || 1 ) - 1 ); + if ( count ) { + jQuery.data( elem, key, count, true ); + } else { + jQuery.removeData( elem, key, true ); + handleQueueMarkDefer( elem, type, "mark" ); + } } + }, - return q; + queue: function( elem, type, data ) { + if ( elem ) { + type = (type || "fx") + "queue"; + var q = jQuery.data( elem, type, undefined, true ); + // Speed up dequeue by getting out quickly if this is just a lookup + if ( data ) { + if ( !q || jQuery.isArray(data) ) { + q = jQuery.data( elem, type, jQuery.makeArray(data), true ); + } else { + q.push( data ); + } + } + return q || []; + } }, dequeue: function( elem, type ) { type = type || "fx"; var queue = jQuery.queue( elem, type ), - fn = queue.shift(); + fn = queue.shift(), + defer; // If the fx queue is dequeued, always remove the progress sentinel if ( fn === "inprogress" ) { @@ -1685,6 +1821,7 @@ jQuery.extend({ if ( !queue.length ) { jQuery.removeData( elem, type + "queue", true ); + handleQueueMarkDefer( elem, type, "queue" ); } } }); @@ -1699,7 +1836,7 @@ jQuery.fn.extend({ if ( data === undefined ) { return jQuery.queue( this[0], type ); } - return this.each(function( i ) { + return this.each(function() { var queue = jQuery.queue( this, type, data ); if ( type === "fx" && queue[0] !== "inprogress" ) { @@ -1712,7 +1849,6 @@ jQuery.fn.extend({ jQuery.dequeue( this, type ); }); }, - // Based off of the plugin by Clint Helfers, with permission. // http://blindsignals.com/index.php/2009/07/jquery-delay/ delay: function( time, type ) { @@ -1726,9 +1862,41 @@ jQuery.fn.extend({ }, time ); }); }, - clearQueue: function( type ) { return this.queue( type || "fx", [] ); + }, + // Get a promise resolved when queues of a certain type + // are emptied (fx is the type by default) + promise: function( type, object ) { + if ( typeof type !== "string" ) { + object = type; + type = undefined; + } + type = type || "fx"; + var defer = jQuery.Deferred(), + elements = this, + i = elements.length, + count = 1, + deferDataKey = type + "defer", + queueDataKey = type + "queue", + markDataKey = type + "mark", + tmp; + function resolve() { + if ( !( --count ) ) { + defer.resolveWith( elements, [ elements ] ); + } + } + while( i-- ) { + if (( tmp = jQuery.data( elements[ i ], deferDataKey, undefined, true ) || + ( jQuery.data( elements[ i ], queueDataKey, undefined, true ) || + jQuery.data( elements[ i ], markDataKey, undefined, true ) ) && + jQuery.data( elements[ i ], deferDataKey, jQuery._Deferred(), true ) )) { + count++; + tmp.done( resolve ); + } + } + resolve(); + return defer.promise(); } }); @@ -1736,66 +1904,67 @@ jQuery.fn.extend({ var rclass = /[\n\t\r]/g, - rspaces = /\s+/, + rspace = /\s+/, rreturn = /\r/g, - rspecialurl = /^(?:href|src|style)$/, rtype = /^(?:button|input)$/i, rfocusable = /^(?:button|input|object|select|textarea)$/i, rclickable = /^a(?:rea)?$/i, - rradiocheck = /^(?:radio|checkbox)$/i; - -jQuery.props = { - "for": "htmlFor", - "class": "className", - readonly: "readOnly", - maxlength: "maxLength", - cellspacing: "cellSpacing", - rowspan: "rowSpan", - colspan: "colSpan", - tabindex: "tabIndex", - usemap: "useMap", - frameborder: "frameBorder" -}; + rboolean = /^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i, + rinvalidChar = /\:|^on/, + formHook, boolHook; jQuery.fn.extend({ attr: function( name, value ) { return jQuery.access( this, name, value, true, jQuery.attr ); }, - removeAttr: function( name, fn ) { - return this.each(function(){ - jQuery.attr( this, name, "" ); - if ( this.nodeType === 1 ) { - this.removeAttribute( name ); - } + removeAttr: function( name ) { + return this.each(function() { + jQuery.removeAttr( this, name ); + }); + }, + + prop: function( name, value ) { + return jQuery.access( this, name, value, true, jQuery.prop ); + }, + + removeProp: function( name ) { + name = jQuery.propFix[ name ] || name; + return this.each(function() { + // try/catch handles cases where IE balks (such as removing a property on window) + try { + this[ name ] = undefined; + delete this[ name ]; + } catch( e ) {} }); }, addClass: function( value ) { - if ( jQuery.isFunction(value) ) { - return this.each(function(i) { - var self = jQuery(this); - self.addClass( value.call(this, i, self.attr("class")) ); + var classNames, i, l, elem, + setClass, c, cl; + + if ( jQuery.isFunction( value ) ) { + return this.each(function( j ) { + jQuery( this ).addClass( value.call(this, j, this.className) ); }); } if ( value && typeof value === "string" ) { - var classNames = (value || "").split( rspaces ); + classNames = value.split( rspace ); - for ( var i = 0, l = this.length; i < l; i++ ) { - var elem = this[i]; + for ( i = 0, l = this.length; i < l; i++ ) { + elem = this[ i ]; if ( elem.nodeType === 1 ) { - if ( !elem.className ) { + if ( !elem.className && classNames.length === 1 ) { elem.className = value; } else { - var className = " " + elem.className + " ", - setClass = elem.className; + setClass = " " + elem.className + " "; - for ( var c = 0, cl = classNames.length; c < cl; c++ ) { - if ( className.indexOf( " " + classNames[c] + " " ) < 0 ) { - setClass += " " + classNames[c]; + for ( c = 0, cl = classNames.length; c < cl; c++ ) { + if ( !~setClass.indexOf( " " + classNames[ c ] + " " ) ) { + setClass += classNames[ c ] + " "; } } elem.className = jQuery.trim( setClass ); @@ -1808,24 +1977,25 @@ jQuery.fn.extend({ }, removeClass: function( value ) { - if ( jQuery.isFunction(value) ) { - return this.each(function(i) { - var self = jQuery(this); - self.removeClass( value.call(this, i, self.attr("class")) ); + var classNames, i, l, elem, className, c, cl; + + if ( jQuery.isFunction( value ) ) { + return this.each(function( j ) { + jQuery( this ).removeClass( value.call(this, j, this.className) ); }); } if ( (value && typeof value === "string") || value === undefined ) { - var classNames = (value || "").split( rspaces ); + classNames = (value || "").split( rspace ); - for ( var i = 0, l = this.length; i < l; i++ ) { - var elem = this[i]; + for ( i = 0, l = this.length; i < l; i++ ) { + elem = this[ i ]; if ( elem.nodeType === 1 && elem.className ) { if ( value ) { - var className = (" " + elem.className + " ").replace(rclass, " "); - for ( var c = 0, cl = classNames.length; c < cl; c++ ) { - className = className.replace(" " + classNames[c] + " ", " "); + className = (" " + elem.className + " ").replace( rclass, " " ); + for ( c = 0, cl = classNames.length; c < cl; c++ ) { + className = className.replace(" " + classNames[ c ] + " ", " "); } elem.className = jQuery.trim( className ); @@ -1844,9 +2014,8 @@ jQuery.fn.extend({ isBool = typeof stateVal === "boolean"; if ( jQuery.isFunction( value ) ) { - return this.each(function(i) { - var self = jQuery(this); - self.toggleClass( value.call(this, i, self.attr("class"), stateVal), stateVal ); + return this.each(function( i ) { + jQuery( this ).toggleClass( value.call(this, i, this.className, stateVal), stateVal ); }); } @@ -1857,7 +2026,7 @@ jQuery.fn.extend({ i = 0, self = jQuery( this ), state = stateVal, - classNames = value.split( rspaces ); + classNames = value.split( rspace ); while ( (className = classNames[ i++ ]) ) { // check each className given, space seperated list @@ -1889,82 +2058,42 @@ jQuery.fn.extend({ }, val: function( value ) { + var hooks, ret, + elem = this[0]; + if ( !arguments.length ) { - var elem = this[0]; - if ( elem ) { - if ( jQuery.nodeName( elem, "option" ) ) { - // attributes.value is undefined in Blackberry 4.7 but - // uses .value. See #6932 - var val = elem.attributes.value; - return !val || val.specified ? elem.value : elem.text; - } - - // We need to handle select boxes special - if ( jQuery.nodeName( elem, "select" ) ) { - var index = elem.selectedIndex, - values = [], - options = elem.options, - one = elem.type === "select-one"; - - // Nothing was selected - if ( index < 0 ) { - return null; - } - - // Loop through all the selected options - for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) { - var option = options[ i ]; - - // Don't return options that are disabled or in a disabled optgroup - if ( option.selected && (jQuery.support.optDisabled ? !option.disabled : option.getAttribute("disabled") === null) && - (!option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" )) ) { - - // Get the specific value for the option - value = jQuery(option).val(); + hooks = jQuery.valHooks[ elem.nodeName.toLowerCase() ] || jQuery.valHooks[ elem.type ]; - // We don't need an array for one selects - if ( one ) { - return value; - } - - // Multi-Selects return an array - values.push( value ); - } - } - - // Fixes Bug #2551 -- select.val() broken in IE after form.reset() - if ( one && !values.length && options.length ) { - return jQuery( options[ index ] ).val(); - } - - return values; + if ( hooks && "get" in hooks && (ret = hooks.get( elem, "value" )) !== undefined ) { + return ret; } - // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified - if ( rradiocheck.test( elem.type ) && !jQuery.support.checkOn ) { - return elem.getAttribute("value") === null ? "on" : elem.value; - } - - // Everything else, we just grab the value - return (elem.value || "").replace(rreturn, ""); + ret = elem.value; + return typeof ret === "string" ? + // handle most common string cases + ret.replace(rreturn, "") : + // handle cases where value is null/undef or number + ret == null ? "" : ret; } return undefined; } - var isFunction = jQuery.isFunction(value); + var isFunction = jQuery.isFunction( value ); - return this.each(function(i) { - var self = jQuery(this), val = value; + return this.each(function( i ) { + var self = jQuery(this), val; if ( this.nodeType !== 1 ) { return; } if ( isFunction ) { - val = value.call(this, i, self.val()); + val = value.call( this, i, self.val() ); + } else { + val = value; } // Treat null/undefined as ""; convert numbers to string @@ -1972,34 +2101,89 @@ jQuery.fn.extend({ val = ""; } else if ( typeof val === "number" ) { val += ""; - } else if ( jQuery.isArray(val) ) { - val = jQuery.map(val, function (value) { + } else if ( jQuery.isArray( val ) ) { + val = jQuery.map(val, function ( value ) { return value == null ? "" : value + ""; }); } - if ( jQuery.isArray(val) && rradiocheck.test( this.type ) ) { - this.checked = jQuery.inArray( self.val(), val ) >= 0; + hooks = jQuery.valHooks[ this.nodeName.toLowerCase() ] || jQuery.valHooks[ this.type ]; + + // If set returns undefined, fall back to normal setting + if ( !hooks || !("set" in hooks) || hooks.set( this, val, "value" ) === undefined ) { + this.value = val; + } + }); + } +}); + +jQuery.extend({ + valHooks: { + option: { + get: function( elem ) { + // attributes.value is undefined in Blackberry 4.7 but + // uses .value. See #6932 + var val = elem.attributes.value; + return !val || val.specified ? elem.value : elem.text; + } + }, + select: { + get: function( elem ) { + var value, + index = elem.selectedIndex, + values = [], + options = elem.options, + one = elem.type === "select-one"; + + // Nothing was selected + if ( index < 0 ) { + return null; + } - } else if ( jQuery.nodeName( this, "select" ) ) { - var values = jQuery.makeArray(val); + // Loop through all the selected options + for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) { + var option = options[ i ]; - jQuery( "option", this ).each(function() { + // Don't return options that are disabled or in a disabled optgroup + if ( option.selected && (jQuery.support.optDisabled ? !option.disabled : option.getAttribute("disabled") === null) && + (!option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" )) ) { + + // Get the specific value for the option + value = jQuery( option ).val(); + + // We don't need an array for one selects + if ( one ) { + return value; + } + + // Multi-Selects return an array + values.push( value ); + } + } + + // Fixes Bug #2551 -- select.val() broken in IE after form.reset() + if ( one && !values.length && options.length ) { + return jQuery( options[ index ] ).val(); + } + + return values; + }, + + set: function( elem, value ) { + var values = jQuery.makeArray( value ); + + jQuery(elem).find("option").each(function() { this.selected = jQuery.inArray( jQuery(this).val(), values ) >= 0; }); if ( !values.length ) { - this.selectedIndex = -1; + elem.selectedIndex = -1; } - - } else { - this.value = val; + return values; } - }); - } -}); + } + }, -jQuery.extend({ attrFn: { val: true, css: true, @@ -2010,115 +2194,340 @@ jQuery.extend({ height: true, offset: true }, - + + attrFix: { + // Always normalize to ensure hook usage + tabindex: "tabIndex" + }, + attr: function( elem, name, value, pass ) { + var nType = elem.nodeType; + // don't get/set attributes on text, comment and attribute nodes - if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || elem.nodeType === 2 ) { + if ( !elem || nType === 3 || nType === 8 || nType === 2 ) { return undefined; } if ( pass && name in jQuery.attrFn ) { - return jQuery(elem)[name](value); + return jQuery( elem )[ name ]( value ); } - var notxml = elem.nodeType !== 1 || !jQuery.isXMLDoc( elem ), - // Whether we are setting (or getting) - set = value !== undefined; + // Fallback to prop when attributes are not supported + if ( !("getAttribute" in elem) ) { + return jQuery.prop( elem, name, value ); + } - // Try to normalize/fix the name - name = notxml && jQuery.props[ name ] || name; + var ret, hooks, + notxml = nType !== 1 || !jQuery.isXMLDoc( elem ); - // Only do all the following if this is a node (faster for style) - if ( elem.nodeType === 1 ) { - // These attributes require special treatment - var special = rspecialurl.test( name ); - - // Safari mis-reports the default selected property of an option - // Accessing the parent's selectedIndex property fixes it - if ( name === "selected" && !jQuery.support.optSelected ) { - var parent = elem.parentNode; - if ( parent ) { - parent.selectedIndex; - - // Make sure that it also works with optgroups, see #5701 - if ( parent.parentNode ) { - parent.parentNode.selectedIndex; - } + // Normalize the name if needed + if ( notxml ) { + name = jQuery.attrFix[ name ] || name; + + hooks = jQuery.attrHooks[ name ]; + + if ( !hooks ) { + // Use boolHook for boolean attributes + if ( rboolean.test( name ) ) { + + hooks = boolHook; + + // Use formHook for forms and if the name contains certain characters + } else if ( formHook && name !== "className" && + (jQuery.nodeName( elem, "form" ) || rinvalidChar.test( name )) ) { + + hooks = formHook; } } + } - // If applicable, access the attribute via the DOM 0 way - // 'in' checks fail in Blackberry 4.7 #6931 - if ( (name in elem || elem[ name ] !== undefined) && notxml && !special ) { - if ( set ) { - // We can't allow the type property to be changed (since it causes problems in IE) - if ( name === "type" && rtype.test( elem.nodeName ) && elem.parentNode ) { - jQuery.error( "type property can't be changed" ); - } + if ( value !== undefined ) { - if ( value === null ) { - if ( elem.nodeType === 1 ) { - elem.removeAttribute( name ); - } + if ( value === null ) { + jQuery.removeAttr( elem, name ); + return undefined; - } else { - elem[ name ] = value; - } - } + } else if ( hooks && "set" in hooks && notxml && (ret = hooks.set( elem, value, name )) !== undefined ) { + return ret; - // browsers index elements by id/name on forms, give priority to attributes. - if ( jQuery.nodeName( elem, "form" ) && elem.getAttributeNode(name) ) { - return elem.getAttributeNode( name ).nodeValue; - } + } else { + elem.setAttribute( name, "" + value ); + return value; + } + + } else if ( hooks && "get" in hooks && notxml && (ret = hooks.get( elem, name )) !== null ) { + return ret; + + } else { + + ret = elem.getAttribute( name ); + // Non-existent attributes return null, we normalize to undefined + return ret === null ? + undefined : + ret; + } + }, + + removeAttr: function( elem, name ) { + var propName; + if ( elem.nodeType === 1 ) { + name = jQuery.attrFix[ name ] || name; + + if ( jQuery.support.getSetAttribute ) { + // Use removeAttribute in browsers that support it + elem.removeAttribute( name ); + } else { + jQuery.attr( elem, name, "" ); + elem.removeAttributeNode( elem.getAttributeNode( name ) ); + } + + // Set corresponding property to false for boolean attributes + if ( rboolean.test( name ) && (propName = jQuery.propFix[ name ] || name) in elem ) { + elem[ propName ] = false; + } + } + }, + + attrHooks: { + type: { + set: function( elem, value ) { + // We can't allow the type property to be changed (since it causes problems in IE) + if ( rtype.test( elem.nodeName ) && elem.parentNode ) { + jQuery.error( "type property can't be changed" ); + } else if ( !jQuery.support.radioValue && value === "radio" && jQuery.nodeName(elem, "input") ) { + // Setting the type on a radio button after the value resets the value in IE6-9 + // Reset value to it's default in case type is set after value + // This is for element creation + var val = elem.value; + elem.setAttribute( "type", value ); + if ( val ) { + elem.value = val; + } + return value; + } + } + }, + tabIndex: { + get: function( elem ) { // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/ - if ( name === "tabIndex" ) { - var attributeNode = elem.getAttributeNode( "tabIndex" ); + var attributeNode = elem.getAttributeNode("tabIndex"); - return attributeNode && attributeNode.specified ? - attributeNode.value : - rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ? - 0 : - undefined; + return attributeNode && attributeNode.specified ? + parseInt( attributeNode.value, 10 ) : + rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ? + 0 : + undefined; + } + }, + // Use the value property for back compat + // Use the formHook for button elements in IE6/7 (#1954) + value: { + get: function( elem, name ) { + if ( formHook && jQuery.nodeName( elem, "button" ) ) { + return formHook.get( elem, name ); + } + return name in elem ? + elem.value : + null; + }, + set: function( elem, value, name ) { + if ( formHook && jQuery.nodeName( elem, "button" ) ) { + return formHook.set( elem, value, name ); } + // Does not return so that setAttribute is also used + elem.value = value; + } + } + }, + + propFix: { + tabindex: "tabIndex", + readonly: "readOnly", + "for": "htmlFor", + "class": "className", + maxlength: "maxLength", + cellspacing: "cellSpacing", + cellpadding: "cellPadding", + rowspan: "rowSpan", + colspan: "colSpan", + usemap: "useMap", + frameborder: "frameBorder", + contenteditable: "contentEditable" + }, + + prop: function( elem, name, value ) { + var nType = elem.nodeType; + + // don't get/set properties on text, comment and attribute nodes + if ( !elem || nType === 3 || nType === 8 || nType === 2 ) { + return undefined; + } + + var ret, hooks, + notxml = nType !== 1 || !jQuery.isXMLDoc( elem ); + + if ( notxml ) { + // Fix name and attach hooks + name = jQuery.propFix[ name ] || name; + hooks = jQuery.propHooks[ name ]; + } + + if ( value !== undefined ) { + if ( hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) { + return ret; + + } else { + return (elem[ name ] = value); + } + + } else { + if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== undefined ) { + return ret; + } else { return elem[ name ]; } + } + }, + + propHooks: {} +}); - if ( !jQuery.support.style && notxml && name === "style" ) { - if ( set ) { - elem.style.cssText = "" + value; - } +// Hook for boolean attributes +boolHook = { + get: function( elem, name ) { + // Align boolean attributes with corresponding properties + return jQuery.prop( elem, name ) ? + name.toLowerCase() : + undefined; + }, + set: function( elem, value, name ) { + var propName; + if ( value === false ) { + // Remove boolean attributes when set to false + jQuery.removeAttr( elem, name ); + } else { + // value is true since we know at this point it's type boolean and not false + // Set boolean attributes to the same name and set the DOM property + propName = jQuery.propFix[ name ] || name; + if ( propName in elem ) { + // Only set the IDL specifically if it already exists on the element + elem[ propName ] = true; + } - return elem.style.cssText; + elem.setAttribute( name, name.toLowerCase() ); + } + return name; + } +}; + +// IE6/7 do not support getting/setting some attributes with get/setAttribute +if ( !jQuery.support.getSetAttribute ) { + + // propFix is more comprehensive and contains all fixes + jQuery.attrFix = jQuery.propFix; + + // Use this for any attribute on a form in IE6/7 + formHook = jQuery.attrHooks.name = jQuery.attrHooks.title = jQuery.valHooks.button = { + get: function( elem, name ) { + var ret; + ret = elem.getAttributeNode( name ); + // Return undefined if nodeValue is empty string + return ret && ret.nodeValue !== "" ? + ret.nodeValue : + undefined; + }, + set: function( elem, value, name ) { + // Check form objects in IE (multiple bugs related) + // Only use nodeValue if the attribute node exists on the form + var ret = elem.getAttributeNode( name ); + if ( ret ) { + ret.nodeValue = value; + return value; } + } + }; - if ( set ) { - // convert the value to a string (all browsers do this but IE) see #1070 - elem.setAttribute( name, "" + value ); + // Set width and height to auto instead of 0 on empty string( Bug #8150 ) + // This is for removals + jQuery.each([ "width", "height" ], function( i, name ) { + jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], { + set: function( elem, value ) { + if ( value === "" ) { + elem.setAttribute( name, "auto" ); + return value; + } } + }); + }); +} - // Ensure that missing attributes return undefined - // Blackberry 4.7 returns "" from getAttribute #6938 - if ( !elem.attributes[ name ] && (elem.hasAttribute && !elem.hasAttribute( name )) ) { - return undefined; + +// Some attributes require a special call on IE +if ( !jQuery.support.hrefNormalized ) { + jQuery.each([ "href", "src", "width", "height" ], function( i, name ) { + jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], { + get: function( elem ) { + var ret = elem.getAttribute( name, 2 ); + return ret === null ? undefined : ret; } + }); + }); +} - var attr = !jQuery.support.hrefNormalized && notxml && special ? - // Some attributes require a special call on IE - elem.getAttribute( name, 2 ) : - elem.getAttribute( name ); +if ( !jQuery.support.style ) { + jQuery.attrHooks.style = { + get: function( elem ) { + // Return undefined in the case of empty string + // Normalize to lowercase since IE uppercases css property names + return elem.style.cssText.toLowerCase() || undefined; + }, + set: function( elem, value ) { + return (elem.style.cssText = "" + value); + } + }; +} - // Non-existent attributes return null, we normalize to undefined - return attr === null ? undefined : attr; +// Safari mis-reports the default selected property of an option +// Accessing the parent's selectedIndex property fixes it +if ( !jQuery.support.optSelected ) { + jQuery.propHooks.selected = jQuery.extend( jQuery.propHooks.selected, { + get: function( elem ) { + var parent = elem.parentNode; + + if ( parent ) { + parent.selectedIndex; + + // Make sure that it also works with optgroups, see #5701 + if ( parent.parentNode ) { + parent.parentNode.selectedIndex; + } + } } - // Handle everything which isn't a DOM element node - if ( set ) { - elem[ name ] = value; + }); +} + +// Radios and checkboxes getter/setter +if ( !jQuery.support.checkOn ) { + jQuery.each([ "radio", "checkbox" ], function() { + jQuery.valHooks[ this ] = { + get: function( elem ) { + // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified + return elem.getAttribute("value") === null ? "on" : elem.value; + } + }; + }); +} +jQuery.each([ "radio", "checkbox" ], function() { + jQuery.valHooks[ this ] = jQuery.extend( jQuery.valHooks[ this ], { + set: function( elem, value ) { + if ( jQuery.isArray( value ) ) { + return (elem.checked = jQuery.inArray( jQuery(elem).val(), value ) >= 0); + } } - return elem[ name ]; - } + }); }); @@ -2127,7 +2536,7 @@ jQuery.extend({ var rnamespaces = /\.(.*)$/, rformElems = /^(?:textarea|input|select)$/i, rperiod = /\./g, - rspace = / /g, + rspaces = / /g, rescape = /[^\w\s.|`]/g, fcleanup = function( nm ) { return nm.replace(rescape, "\\$&"); @@ -2147,17 +2556,6 @@ jQuery.event = { return; } - // TODO :: Use a try/catch until it's safe to pull this out (likely 1.6) - // Minor release fix for bug #8018 - try { - // For whatever reason, IE has trouble passing the window object - // around, causing it to be cloned in the process - if ( jQuery.isWindow( elem ) && ( elem !== window && !elem.frameElement ) ) { - elem = window; - } - } - catch ( e ) {} - if ( handler === false ) { handler = returnFalse; } else if ( !handler ) { @@ -2194,10 +2592,10 @@ jQuery.event = { } if ( !eventHandle ) { - elemData.handle = eventHandle = function() { - // Handle the second event of a trigger and when - // an event is called after a page has unloaded - return typeof jQuery !== "undefined" && !jQuery.event.triggered ? + elemData.handle = eventHandle = function( e ) { + // Discard the second event of a jQuery.event.trigger() and + // when an event is called after a page has unloaded + return typeof jQuery !== "undefined" && (!e || jQuery.event.triggered !== e.type) ? jQuery.event.handle.apply( eventHandle.elem, arguments ) : undefined; }; @@ -2267,7 +2665,7 @@ jQuery.event = { // Add the function to the element's handler list handlers.push( handleObj ); - // Keep track of which events have been used, for global triggering + // Keep track of which events have been used, for event optimization jQuery.event.global[ type ] = true; } @@ -2400,182 +2798,185 @@ jQuery.event = { } } }, + + // Events that are safe to short-circuit if no handlers are attached. + // Native DOM events should not be added, they may have inline handlers. + customEvent: { + "getData": true, + "setData": true, + "changeData": true + }, - // bubbling is internal - trigger: function( event, data, elem /*, bubbling */ ) { + trigger: function( event, data, elem, onlyHandlers ) { // Event object or event type var type = event.type || event, - bubbling = arguments[3]; + namespaces = [], + exclusive; - if ( !bubbling ) { - event = typeof event === "object" ? - // jQuery.Event object - event[ jQuery.expando ] ? event : - // Object literal - jQuery.extend( jQuery.Event(type), event ) : - // Just the event type (string) - jQuery.Event(type); + if ( type.indexOf("!") >= 0 ) { + // Exclusive events trigger only for the exact event (no namespaces) + type = type.slice(0, -1); + exclusive = true; + } - if ( type.indexOf("!") >= 0 ) { - event.type = type = type.slice(0, -1); - event.exclusive = true; - } + if ( type.indexOf(".") >= 0 ) { + // Namespaced trigger; create a regexp to match event type in handle() + namespaces = type.split("."); + type = namespaces.shift(); + namespaces.sort(); + } - // Handle a global trigger - if ( !elem ) { - // Don't bubble custom events when global (to avoid too much overhead) - event.stopPropagation(); - - // Only trigger if we've ever bound an event for it - if ( jQuery.event.global[ type ] ) { - // XXX This code smells terrible. event.js should not be directly - // inspecting the data cache - jQuery.each( jQuery.cache, function() { - // internalKey variable is just used to make it easier to find - // and potentially change this stuff later; currently it just - // points to jQuery.expando - var internalKey = jQuery.expando, - internalCache = this[ internalKey ]; - if ( internalCache && internalCache.events && internalCache.events[ type ] ) { - jQuery.event.trigger( event, data, internalCache.handle.elem ); - } - }); - } - } + if ( (!elem || jQuery.event.customEvent[ type ]) && !jQuery.event.global[ type ] ) { + // No jQuery handlers for this event type, and it can't have inline handlers + return; + } - // Handle triggering a single element + // Caller can pass in an Event, Object, or just an event type string + event = typeof event === "object" ? + // jQuery.Event object + event[ jQuery.expando ] ? event : + // Object literal + new jQuery.Event( type, event ) : + // Just the event type (string) + new jQuery.Event( type ); - // don't do events on text and comment nodes - if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) { - return undefined; - } + event.type = type; + event.exclusive = exclusive; + event.namespace = namespaces.join("."); + event.namespace_re = new RegExp("(^|\\.)" + namespaces.join("\\.(?:.*\\.)?") + "(\\.|$)"); + + // triggerHandler() and global events don't bubble or run the default action + if ( onlyHandlers || !elem ) { + event.preventDefault(); + event.stopPropagation(); + } - // Clean up in case it is reused - event.result = undefined; - event.target = elem; + // Handle a global trigger + if ( !elem ) { + // TODO: Stop taunting the data cache; remove global events and always attach to document + jQuery.each( jQuery.cache, function() { + // internalKey variable is just used to make it easier to find + // and potentially change this stuff later; currently it just + // points to jQuery.expando + var internalKey = jQuery.expando, + internalCache = this[ internalKey ]; + if ( internalCache && internalCache.events && internalCache.events[ type ] ) { + jQuery.event.trigger( event, data, internalCache.handle.elem ); + } + }); + return; + } - // Clone the incoming data, if any - data = jQuery.makeArray( data ); - data.unshift( event ); + // Don't do events on text and comment nodes + if ( elem.nodeType === 3 || elem.nodeType === 8 ) { + return; } - event.currentTarget = elem; + // Clean up the event in case it is being reused + event.result = undefined; + event.target = elem; - // Trigger the event, it is assumed that "handle" is a function - var handle = jQuery._data( elem, "handle" ); + // Clone any incoming data and prepend the event, creating the handler arg list + data = data != null ? jQuery.makeArray( data ) : []; + data.unshift( event ); - if ( handle ) { - handle.apply( elem, data ); - } + var cur = elem, + // IE doesn't like method names with a colon (#3533, #8272) + ontype = type.indexOf(":") < 0 ? "on" + type : ""; - var parent = elem.parentNode || elem.ownerDocument; + // Fire event on the current element, then bubble up the DOM tree + do { + var handle = jQuery._data( cur, "handle" ); - // Trigger an inline bound script - try { - if ( !(elem && elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()]) ) { - if ( elem[ "on" + type ] && elem[ "on" + type ].apply( elem, data ) === false ) { - event.result = false; - event.preventDefault(); - } + event.currentTarget = cur; + if ( handle ) { + handle.apply( cur, data ); } - // prevent IE from throwing an error for some elements with some event types, see #3533 - } catch (inlineError) {} + // Trigger an inline bound script + if ( ontype && jQuery.acceptData( cur ) && cur[ ontype ] && cur[ ontype ].apply( cur, data ) === false ) { + event.result = false; + event.preventDefault(); + } - if ( !event.isPropagationStopped() && parent ) { - jQuery.event.trigger( event, data, parent, true ); + // Bubble up to document, then to window + cur = cur.parentNode || cur.ownerDocument || cur === event.target.ownerDocument && window; + } while ( cur && !event.isPropagationStopped() ); - } else if ( !event.isDefaultPrevented() ) { + // If nobody prevented the default action, do it now + if ( !event.isDefaultPrevented() ) { var old, - target = event.target, - targetType = type.replace( rnamespaces, "" ), - isClick = jQuery.nodeName( target, "a" ) && targetType === "click", - special = jQuery.event.special[ targetType ] || {}; + special = jQuery.event.special[ type ] || {}; - if ( (!special._default || special._default.call( elem, event ) === false) && - !isClick && !(target && target.nodeName && jQuery.noData[target.nodeName.toLowerCase()]) ) { + if ( (!special._default || special._default.call( elem.ownerDocument, event ) === false) && + !(type === "click" && jQuery.nodeName( elem, "a" )) && jQuery.acceptData( elem ) ) { + // Call a native DOM method on the target with the same name name as the event. + // Can't use an .isFunction)() check here because IE6/7 fails that test. + // IE<9 dies on focus to hidden element (#1486), may want to revisit a try/catch. try { - if ( target[ targetType ] ) { - // Make sure that we don't accidentally re-trigger the onFOO events - old = target[ "on" + targetType ]; + if ( ontype && elem[ type ] ) { + // Don't re-trigger an onFOO event when we call its FOO() method + old = elem[ ontype ]; if ( old ) { - target[ "on" + targetType ] = null; + elem[ ontype ] = null; } - jQuery.event.triggered = true; - target[ targetType ](); + jQuery.event.triggered = type; + elem[ type ](); } - - // prevent IE from throwing an error for some elements with some event types, see #3533 - } catch (triggerError) {} + } catch ( ieError ) {} if ( old ) { - target[ "on" + targetType ] = old; + elem[ ontype ] = old; } - jQuery.event.triggered = false; + jQuery.event.triggered = undefined; } } + + return event.result; }, handle: function( event ) { - var all, handlers, namespaces, namespace_re, events, - namespace_sort = [], - args = jQuery.makeArray( arguments ); - - event = args[0] = jQuery.event.fix( event || window.event ); + event = jQuery.event.fix( event || window.event ); + // Snapshot the handlers list since a called handler may add/remove events. + var handlers = ((jQuery._data( this, "events" ) || {})[ event.type ] || []).slice(0), + run_all = !event.exclusive && !event.namespace, + args = Array.prototype.slice.call( arguments, 0 ); + + // Use the fix-ed Event rather than the (read-only) native event + args[0] = event; event.currentTarget = this; - // Namespaced event handlers - all = event.type.indexOf(".") < 0 && !event.exclusive; - - if ( !all ) { - namespaces = event.type.split("."); - event.type = namespaces.shift(); - namespace_sort = namespaces.slice(0).sort(); - namespace_re = new RegExp("(^|\\.)" + namespace_sort.join("\\.(?:.*\\.)?") + "(\\.|$)"); - } - - event.namespace = event.namespace || namespace_sort.join("."); - - events = jQuery._data(this, "events"); - - handlers = (events || {})[ event.type ]; - - if ( events && handlers ) { - // Clone the handlers to prevent manipulation - handlers = handlers.slice(0); - - for ( var j = 0, l = handlers.length; j < l; j++ ) { - var handleObj = handlers[ j ]; - - // Filter the functions by class - if ( all || namespace_re.test( handleObj.namespace ) ) { - // Pass in a reference to the handler function itself - // So that we can later remove it - event.handler = handleObj.handler; - event.data = handleObj.data; - event.handleObj = handleObj; - - var ret = handleObj.handler.apply( this, args ); - - if ( ret !== undefined ) { - event.result = ret; - if ( ret === false ) { - event.preventDefault(); - event.stopPropagation(); - } + for ( var j = 0, l = handlers.length; j < l; j++ ) { + var handleObj = handlers[ j ]; + + // Triggered event must 1) be non-exclusive and have no namespace, or + // 2) have namespace(s) a subset or equal to those in the bound event. + if ( run_all || event.namespace_re.test( handleObj.namespace ) ) { + // Pass in a reference to the handler function itself + // So that we can later remove it + event.handler = handleObj.handler; + event.data = handleObj.data; + event.handleObj = handleObj; + + var ret = handleObj.handler.apply( this, args ); + + if ( ret !== undefined ) { + event.result = ret; + if ( ret === false ) { + event.preventDefault(); + event.stopPropagation(); } + } - if ( event.isImmediatePropagationStopped() ) { - break; - } + if ( event.isImmediatePropagationStopped() ) { + break; } } } - return event.result; }, @@ -2614,8 +3015,9 @@ jQuery.event = { // Calculate pageX/Y if missing and clientX/Y available if ( event.pageX == null && event.clientX != null ) { - var doc = document.documentElement, - body = document.body; + var eventDocument = event.target.ownerDocument || document, + doc = eventDocument.documentElement, + body = eventDocument.body; event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0); event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0); @@ -2694,10 +3096,10 @@ jQuery.removeEvent = document.removeEventListener ? } }; -jQuery.Event = function( src ) { +jQuery.Event = function( src, props ) { // Allow instantiation without the 'new' keyword if ( !this.preventDefault ) { - return new jQuery.Event( src ); + return new jQuery.Event( src, props ); } // Event object @@ -2715,6 +3117,11 @@ jQuery.Event = function( src ) { this.type = src; } + // Put explicitly provided properties onto the event object + if ( props ) { + jQuery.extend( this, props ); + } + // timeStamp is buggy for some events on Firefox(#3843) // So we won't rely on the native value this.timeStamp = jQuery.now(); @@ -2776,33 +3183,27 @@ jQuery.Event.prototype = { // Checks if an event happened on an element within another element // Used in jQuery.event.special.mouseenter and mouseleave handlers var withinElement = function( event ) { + // Check if mouse(over|out) are still within the same parent element - var parent = event.relatedTarget; + var related = event.relatedTarget, + inside = false, + eventType = event.type; - // Firefox sometimes assigns relatedTarget a XUL element - // which we cannot access the parentNode property of - try { + event.type = event.data; - // Chrome does something similar, the parentNode property - // can be accessed but is null. - if ( parent !== document && !parent.parentNode ) { - return; - } - // Traverse up the tree - while ( parent && parent !== this ) { - parent = parent.parentNode; + if ( related !== this ) { + + if ( related ) { + inside = jQuery.contains( this, related ); } - if ( parent !== this ) { - // set the correct event type - event.type = event.data; + if ( !inside ) { - // handle event if we actually just moused on to a non sub-element jQuery.event.handle.apply( this, arguments ); - } - // assuming we've left the element since we most likely mousedover a xul element - } catch(e) { } + event.type = eventType; + } + } }, // In case of event delegation, we only need to rename the event.type, @@ -2832,7 +3233,7 @@ if ( !jQuery.support.submitBubbles ) { jQuery.event.special.submit = { setup: function( data, namespaces ) { - if ( this.nodeName && this.nodeName.toLowerCase() !== "form" ) { + if ( !jQuery.nodeName( this, "form" ) ) { jQuery.event.add(this, "click.specialSubmit", function( e ) { var elem = e.target, type = elem.type; @@ -2881,7 +3282,7 @@ if ( !jQuery.support.changeBubbles ) { }).join("-") : ""; - } else if ( elem.nodeName.toLowerCase() === "select" ) { + } else if ( jQuery.nodeName( elem, "select" ) ) { val = elem.selectedIndex; } @@ -2921,9 +3322,9 @@ if ( !jQuery.support.changeBubbles ) { beforedeactivate: testChange, click: function( e ) { - var elem = e.target, type = elem.type; + var elem = e.target, type = jQuery.nodeName( elem, "input" ) ? elem.type : ""; - if ( type === "radio" || type === "checkbox" || elem.nodeName.toLowerCase() === "select" ) { + if ( type === "radio" || type === "checkbox" || jQuery.nodeName( elem, "select" ) ) { testChange.call( this, e ); } }, @@ -2931,9 +3332,9 @@ if ( !jQuery.support.changeBubbles ) { // Change has to be called before submit // Keydown will be called before keypress, which is used in submit-event delegation keydown: function( e ) { - var elem = e.target, type = elem.type; + var elem = e.target, type = jQuery.nodeName( elem, "input" ) ? elem.type : ""; - if ( (e.keyCode === 13 && elem.nodeName.toLowerCase() !== "textarea") || + if ( (e.keyCode === 13 && !jQuery.nodeName( elem, "textarea" ) ) || (e.keyCode === 32 && (type === "checkbox" || type === "radio")) || type === "select-multiple" ) { testChange.call( this, e ); @@ -2990,27 +3391,43 @@ function trigger( type, elem, args ) { } // Create "bubbling" focus and blur events -if ( document.addEventListener ) { +if ( !jQuery.support.focusinBubbles ) { jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) { + + // Attach a single capturing handler while someone wants focusin/focusout + var attaches = 0; + jQuery.event.special[ fix ] = { setup: function() { - this.addEventListener( orig, handler, true ); + if ( attaches++ === 0 ) { + document.addEventListener( orig, handler, true ); + } }, teardown: function() { - this.removeEventListener( orig, handler, true ); + if ( --attaches === 0 ) { + document.removeEventListener( orig, handler, true ); + } } }; - function handler( e ) { - e = jQuery.event.fix( e ); + function handler( donor ) { + // Donor event is always a native one; fix it and switch its type. + // Let focusin/out handler cancel the donor focus/blur event. + var e = jQuery.event.fix( donor ); e.type = fix; - return jQuery.event.handle.call( this, e ); + e.originalEvent = {}; + jQuery.event.trigger( e, null, e.target ); + if ( e.isDefaultPrevented() ) { + donor.preventDefault(); + } } }); } jQuery.each(["bind", "one"], function( i, name ) { jQuery.fn[ name ] = function( type, data, fn ) { + var handler; + // Handle object literals if ( typeof type === "object" ) { for ( var key in type ) { @@ -3019,15 +3436,20 @@ jQuery.each(["bind", "one"], function( i, name ) { return this; } - if ( jQuery.isFunction( data ) || data === false ) { + if ( arguments.length === 2 || data === false ) { fn = data; data = undefined; } - var handler = name === "one" ? jQuery.proxy( fn, function( event ) { - jQuery( this ).unbind( event, handler ); - return fn.apply( this, arguments ); - }) : fn; + if ( name === "one" ) { + handler = function( event ) { + jQuery( this ).unbind( event, handler ); + return fn.apply( this, arguments ); + }; + handler.guid = fn.guid || jQuery.guid++; + } else { + handler = fn; + } if ( type === "unload" && name !== "one" ) { this.one( type, data, fn ); @@ -3065,7 +3487,7 @@ jQuery.fn.extend({ undelegate: function( selector, types, fn ) { if ( arguments.length === 0 ) { - return this.unbind( "live" ); + return this.unbind( "live" ); } else { return this.die( types, null, fn, selector ); @@ -3080,35 +3502,34 @@ jQuery.fn.extend({ triggerHandler: function( type, data ) { if ( this[0] ) { - var event = jQuery.Event( type ); - event.preventDefault(); - event.stopPropagation(); - jQuery.event.trigger( event, data, this[0] ); - return event.result; + return jQuery.event.trigger( type, data, this[0], true ); } }, toggle: function( fn ) { // Save reference to arguments for access in closure var args = arguments, - i = 1; + guid = fn.guid || jQuery.guid++, + i = 0, + toggler = function( event ) { + // Figure out which function to execute + var lastToggle = ( jQuery.data( this, "lastToggle" + fn.guid ) || 0 ) % i; + jQuery.data( this, "lastToggle" + fn.guid, lastToggle + 1 ); + + // Make sure that clicks stop + event.preventDefault(); + + // and execute the function + return args[ lastToggle ].apply( this, arguments ) || false; + }; // link all the functions, so any of them can unbind this click handler + toggler.guid = guid; while ( i < args.length ) { - jQuery.proxy( fn, args[ i++ ] ); + args[ i++ ].guid = guid; } - return this.click( jQuery.proxy( fn, function( event ) { - // Figure out which function to execute - var lastToggle = ( jQuery._data( this, "lastToggle" + fn.guid ) || 0 ) % i; - jQuery._data( this, "lastToggle" + fn.guid, lastToggle + 1 ); - - // Make sure that clicks stop - event.preventDefault(); - - // and execute the function - return args[ lastToggle ].apply( this, arguments ) || false; - })); + return this.click( toggler ); }, hover: function( fnOver, fnOut ) { @@ -3137,8 +3558,16 @@ jQuery.each(["live", "die"], function( i, name ) { return this; } - if ( jQuery.isFunction( data ) ) { - fn = data; + if ( name === "die" && !types && + origSelector && origSelector.charAt(0) === "." ) { + + context.unbind( origSelector ); + + return this; + } + + if ( data === false || jQuery.isFunction( data ) ) { + fn = data || returnFalse; data = undefined; } @@ -3160,7 +3589,7 @@ jQuery.each(["live", "die"], function( i, name ) { preType = type; - if ( type === "focus" || type === "blur" ) { + if ( liveMap[ type ] ) { types.push( liveMap[ type ] + namespaces ); type = type + namespaces; @@ -3231,6 +3660,11 @@ function liveHandler( event ) { if ( handleObj.preType === "mouseenter" || handleObj.preType === "mouseleave" ) { event.type = handleObj.preType; related = jQuery( event.relatedTarget ).closest( handleObj.selector )[0]; + + // Make sure not to accidentally match a child element with the same selector + if ( related && jQuery.contains( elem, related ) ) { + related = elem; + } } if ( !related || related !== elem ) { @@ -3269,7 +3703,7 @@ function liveHandler( event ) { } function liveConvert( type, selector ) { - return (type && type !== "*" ? type + "." : "") + selector.replace(rperiod, "`").replace(rspace, "&"); + return (type && type !== "*" ? type + "." : "") + selector.replace(rperiod, "`").replace(rspaces, "&"); } jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " + @@ -3294,6 +3728,7 @@ jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblcl }); + /*! * Sizzle CSS Selector Engine * Copyright 2011, The Dojo Foundation @@ -3918,43 +4353,53 @@ var Expr = Sizzle.selectors = { }, text: function( elem ) { + var attr = elem.getAttribute( "type" ), type = elem.type; // IE6 and 7 will map elem.type to 'text' for new HTML5 types (search, etc) // use getAttribute instead to test this case - return "text" === elem.getAttribute( 'type' ); + return elem.nodeName.toLowerCase() === "input" && "text" === type && ( attr === type || attr === null ); }, + radio: function( elem ) { - return "radio" === elem.type; + return elem.nodeName.toLowerCase() === "input" && "radio" === elem.type; }, checkbox: function( elem ) { - return "checkbox" === elem.type; + return elem.nodeName.toLowerCase() === "input" && "checkbox" === elem.type; }, file: function( elem ) { - return "file" === elem.type; + return elem.nodeName.toLowerCase() === "input" && "file" === elem.type; }, + password: function( elem ) { - return "password" === elem.type; + return elem.nodeName.toLowerCase() === "input" && "password" === elem.type; }, submit: function( elem ) { - return "submit" === elem.type; + var name = elem.nodeName.toLowerCase(); + return (name === "input" || name === "button") && "submit" === elem.type; }, image: function( elem ) { - return "image" === elem.type; + return elem.nodeName.toLowerCase() === "input" && "image" === elem.type; }, reset: function( elem ) { - return "reset" === elem.type; + var name = elem.nodeName.toLowerCase(); + return (name === "input" || name === "button") && "reset" === elem.type; }, button: function( elem ) { - return "button" === elem.type || elem.nodeName.toLowerCase() === "button"; + var name = elem.nodeName.toLowerCase(); + return name === "input" && "button" === elem.type || name === "button"; }, input: function( elem ) { return (/input|select|textarea|button/i).test( elem.nodeName ); + }, + + focus: function( elem ) { + return elem === elem.ownerDocument.activeElement; } }, setFilters: { @@ -4207,6 +4652,16 @@ if ( document.documentElement.compareDocumentPosition ) { } else { sortOrder = function( a, b ) { + // The nodes are identical, we can exit early + if ( a === b ) { + hasDuplicate = true; + return 0; + + // Fallback to using sourceIndex (in IE) if it's available on both nodes + } else if ( a.sourceIndex && b.sourceIndex ) { + return a.sourceIndex - b.sourceIndex; + } + var al, bl, ap = [], bp = [], @@ -4214,13 +4669,8 @@ if ( document.documentElement.compareDocumentPosition ) { bup = b.parentNode, cur = aup; - // The nodes are identical, we can exit early - if ( a === b ) { - hasDuplicate = true; - return 0; - // If the nodes are siblings (or identical) we can do a quick check - } else if ( aup === bup ) { + if ( aup === bup ) { return siblingCheck( a, b ); // If no parents were found then the nodes are disconnected @@ -4496,19 +4946,23 @@ if ( document.querySelectorAll ) { (function(){ var html = document.documentElement, - matches = html.matchesSelector || html.mozMatchesSelector || html.webkitMatchesSelector || html.msMatchesSelector, - pseudoWorks = false; + matches = html.matchesSelector || html.mozMatchesSelector || html.webkitMatchesSelector || html.msMatchesSelector; - try { - // This should fail with an exception - // Gecko does not error, returns false instead - matches.call( document.documentElement, "[test!='']:sizzle" ); + if ( matches ) { + // Check to see if it's possible to do matchesSelector + // on a disconnected node (IE 9 fails this) + var disconnectedMatch = !matches.call( document.createElement( "div" ), "div" ), + pseudoWorks = false; + + try { + // This should fail with an exception + // Gecko does not error, returns false instead + matches.call( document.documentElement, "[test!='']:sizzle" ); - } catch( pseudoError ) { - pseudoWorks = true; - } + } catch( pseudoError ) { + pseudoWorks = true; + } - if ( matches ) { Sizzle.matchesSelector = function( node, expr ) { // Make sure that attribute selectors are quoted expr = expr.replace(/\=\s*([^'"\]]*)\s*\]/g, "='$1']"); @@ -4516,7 +4970,15 @@ if ( document.querySelectorAll ) { if ( !Sizzle.isXML( node ) ) { try { if ( pseudoWorks || !Expr.match.PSEUDO.test( expr ) && !/!=/.test( expr ) ) { - return matches.call( node, expr ); + var ret = matches.call( node, expr ); + + // IE 9's matchesSelector returns false on disconnected nodes + if ( ret || !disconnectedMatch || + // As well, disconnected nodes are said to be in a document + // fragment in IE 9, so check for that + node.document && node.document.nodeType !== 11 ) { + return ret; + } } } catch(e) {} } @@ -4705,17 +5167,30 @@ var runtil = /Until$/, jQuery.fn.extend({ find: function( selector ) { + var self = this, + i, l; + + if ( typeof selector !== "string" ) { + return jQuery( selector ).filter(function() { + for ( i = 0, l = self.length; i < l; i++ ) { + if ( jQuery.contains( self[ i ], this ) ) { + return true; + } + } + }); + } + var ret = this.pushStack( "", "find", selector ), - length = 0; + length, n, r; - for ( var i = 0, l = this.length; i < l; i++ ) { + for ( i = 0, l = this.length; i < l; i++ ) { length = ret.length; jQuery.find( selector, this[i], ret ); if ( i > 0 ) { // Make sure that the results are unique - for ( var n = length; n < ret.length; n++ ) { - for ( var r = 0; r < length; r++ ) { + for ( n = length; n < ret.length; n++ ) { + for ( r = 0; r < length; r++ ) { if ( ret[r] === ret[n] ) { ret.splice(n--, 1); break; @@ -4748,12 +5223,15 @@ jQuery.fn.extend({ }, is: function( selector ) { - return !!selector && jQuery.filter( selector, this ).length > 0; + return !!selector && ( typeof selector === "string" ? + jQuery.filter( selector, this ).length > 0 : + this.filter( selector ).length > 0 ); }, closest: function( selectors, context ) { var ret = [], i, l, cur = this[0]; - + + // Array if ( jQuery.isArray( selectors ) ) { var match, selector, matches = {}, @@ -4763,8 +5241,8 @@ jQuery.fn.extend({ for ( i = 0, l = selectors.length; i < l; i++ ) { selector = selectors[i]; - if ( !matches[selector] ) { - matches[selector] = jQuery.expr.match.POS.test( selector ) ? + if ( !matches[ selector ] ) { + matches[ selector ] = POS.test( selector ) ? jQuery( selector, context || this.context ) : selector; } @@ -4772,9 +5250,9 @@ jQuery.fn.extend({ while ( cur && cur.ownerDocument && cur !== context ) { for ( selector in matches ) { - match = matches[selector]; + match = matches[ selector ]; - if ( match.jquery ? match.index(cur) > -1 : jQuery(cur).is(match) ) { + if ( match.jquery ? match.index( cur ) > -1 : jQuery( cur ).is( match ) ) { ret.push({ selector: selector, elem: cur, level: level }); } } @@ -4787,8 +5265,10 @@ jQuery.fn.extend({ return ret; } - var pos = POS.test( selectors ) ? - jQuery( selectors, context || this.context ) : null; + // String + var pos = POS.test( selectors ) || typeof selectors !== "string" ? + jQuery( selectors, context || this.context ) : + 0; for ( i = 0, l = this.length; i < l; i++ ) { cur = this[i]; @@ -4800,14 +5280,14 @@ jQuery.fn.extend({ } else { cur = cur.parentNode; - if ( !cur || !cur.ownerDocument || cur === context ) { + if ( !cur || !cur.ownerDocument || cur === context || cur.nodeType === 11 ) { break; } } } } - ret = ret.length > 1 ? jQuery.unique(ret) : ret; + ret = ret.length > 1 ? jQuery.unique( ret ) : ret; return this.pushStack( ret, "closest", selectors ); }, @@ -4830,7 +5310,7 @@ jQuery.fn.extend({ add: function( selector, context ) { var set = typeof selector === "string" ? jQuery( selector, context ) : - jQuery.makeArray( selector ), + jQuery.makeArray( selector && selector.nodeType ? [ selector ] : selector ), all = jQuery.merge( this.get(), set ); return this.pushStack( isDisconnected( set[0] ) || isDisconnected( all[0] ) ? @@ -4968,6 +5448,11 @@ jQuery.extend({ // Implement the identical functionality for filter and not function winnow( elements, qualifier, keep ) { + + // Can't pass null or undefined to indexOf in Firefox 4 + // Set to 0 to skip string check + qualifier = qualifier || 0; + if ( jQuery.isFunction( qualifier ) ) { return jQuery.grep(elements, function( elem, i ) { var retVal = !!qualifier.call( elem, i, elem ); @@ -5008,6 +5493,8 @@ var rinlinejQuery = / jQuery\d+="(?:\d+|null)"/g, rnocache = /<(?:script|object|embed|option|style)/i, // checked="checked" or checked rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i, + rscriptType = /\/(java|ecma)script/i, + rcleanScript = /^\s*<!(?:\[CDATA\[|\-\-)/, wrapMap = { option: [ 1, "<select multiple='multiple'>", "</select>" ], legend: [ 1, "<fieldset>", "</fieldset>" ], @@ -5068,7 +5555,7 @@ jQuery.fn.extend({ } return elem; - }).append(this); + }).append( this ); } return this; @@ -5260,7 +5747,9 @@ jQuery.fn.extend({ } }); } else { - return this.pushStack( jQuery(jQuery.isFunction(value) ? value() : value), "replaceWith", value ); + return this.length ? + this.pushStack( jQuery(jQuery.isFunction(value) ? value() : value), "replaceWith", value ) : + this; } }, @@ -5374,21 +5863,27 @@ function cloneCopyEvent( src, dest ) { } } -function cloneFixAttributes(src, dest) { +function cloneFixAttributes( src, dest ) { + var nodeName; + // We do not need to do anything for non-Elements if ( dest.nodeType !== 1 ) { return; } - var nodeName = dest.nodeName.toLowerCase(); - // clearAttributes removes the attributes, which we don't want, // but also removes the attachEvent events, which we *do* want - dest.clearAttributes(); + if ( dest.clearAttributes ) { + dest.clearAttributes(); + } // mergeAttributes, in contrast, only merges back on the // original attributes, not the events - dest.mergeAttributes(src); + if ( dest.mergeAttributes ) { + dest.mergeAttributes( src ); + } + + nodeName = dest.nodeName.toLowerCase(); // IE6-8 fail to clone children inside object elements that use // the proprietary classid attribute value (rather than the type @@ -5427,8 +5922,21 @@ function cloneFixAttributes(src, dest) { } jQuery.buildFragment = function( args, nodes, scripts ) { - var fragment, cacheable, cacheresults, - doc = (nodes && nodes[0] ? nodes[0].ownerDocument || nodes[0] : document); + var fragment, cacheable, cacheresults, doc; + + // nodes may contain either an explicit document object, + // a jQuery collection or context object. + // If nodes[0] contains a valid object to assign to doc + if ( nodes && nodes[0] ) { + doc = nodes[0].ownerDocument || nodes[0]; + } + + // Ensure that an attr object doesn't incorrectly stand in as a document object + // Chrome and Firefox seem to allow this to occur and will throw exception + // Fixes #8950 + if ( !doc.createDocumentFragment ) { + doc = document; + } // Only cache "small" (1/2 KB) HTML strings that are associated with the main document // Cloning options loses the selected state, so don't cache them @@ -5438,11 +5946,10 @@ jQuery.buildFragment = function( args, nodes, scripts ) { args[0].charAt(0) === "<" && !rnocache.test( args[0] ) && (jQuery.support.checkClone || !rchecked.test( args[0] )) ) { cacheable = true; + cacheresults = jQuery.fragments[ args[0] ]; - if ( cacheresults ) { - if ( cacheresults !== 1 ) { - fragment = cacheresults; - } + if ( cacheresults && cacheresults !== 1 ) { + fragment = cacheresults; } } @@ -5491,7 +5998,7 @@ jQuery.each({ function getAll( elem ) { if ( "getElementsByTagName" in elem ) { return elem.getElementsByTagName( "*" ); - + } else if ( "querySelectorAll" in elem ) { return elem.querySelectorAll( "*" ); @@ -5500,6 +6007,21 @@ function getAll( elem ) { } } +// Used in clean, fixes the defaultChecked property +function fixDefaultChecked( elem ) { + if ( elem.type === "checkbox" || elem.type === "radio" ) { + elem.defaultChecked = elem.checked; + } +} +// Finds all inputs and passes them to fixDefaultChecked +function findInputs( elem ) { + if ( jQuery.nodeName( elem, "input" ) ) { + fixDefaultChecked( elem ); + } else if ( "getElementsByTagName" in elem ) { + jQuery.grep( elem.getElementsByTagName("input"), fixDefaultChecked ); + } +} + jQuery.extend({ clone: function( elem, dataAndEvents, deepDataAndEvents ) { var clone = elem.cloneNode(true), @@ -5544,10 +6066,15 @@ jQuery.extend({ } } + srcElements = destElements = null; + // Return the cloned set return clone; -}, + }, + clean: function( elems, context, fragment, scripts ) { + var checkScriptType; + context = context || document; // !context.createElement fails in IE with an error but returns typeof 'object' @@ -5555,7 +6082,7 @@ jQuery.extend({ context = context.ownerDocument || context[0] && context[0].ownerDocument || document; } - var ret = []; + var ret = [], j; for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) { if ( typeof elem === "number" ) { @@ -5567,54 +6094,67 @@ jQuery.extend({ } // Convert html string into DOM nodes - if ( typeof elem === "string" && !rhtml.test( elem ) ) { - elem = context.createTextNode( elem ); - - } else if ( typeof elem === "string" ) { - // Fix "XHTML"-style tags in all browsers - elem = elem.replace(rxhtmlTag, "<$1></$2>"); + if ( typeof elem === "string" ) { + if ( !rhtml.test( elem ) ) { + elem = context.createTextNode( elem ); + } else { + // Fix "XHTML"-style tags in all browsers + elem = elem.replace(rxhtmlTag, "<$1></$2>"); - // Trim whitespace, otherwise indexOf won't work as expected - var tag = (rtagName.exec( elem ) || ["", ""])[1].toLowerCase(), - wrap = wrapMap[ tag ] || wrapMap._default, - depth = wrap[0], - div = context.createElement("div"); + // Trim whitespace, otherwise indexOf won't work as expected + var tag = (rtagName.exec( elem ) || ["", ""])[1].toLowerCase(), + wrap = wrapMap[ tag ] || wrapMap._default, + depth = wrap[0], + div = context.createElement("div"); - // Go to html and back, then peel off extra wrappers - div.innerHTML = wrap[1] + elem + wrap[2]; + // Go to html and back, then peel off extra wrappers + div.innerHTML = wrap[1] + elem + wrap[2]; - // Move to the right depth - while ( depth-- ) { - div = div.lastChild; - } + // Move to the right depth + while ( depth-- ) { + div = div.lastChild; + } - // Remove IE's autoinserted <tbody> from table fragments - if ( !jQuery.support.tbody ) { + // Remove IE's autoinserted <tbody> from table fragments + if ( !jQuery.support.tbody ) { - // String was a <table>, *may* have spurious <tbody> - var hasBody = rtbody.test(elem), - tbody = tag === "table" && !hasBody ? - div.firstChild && div.firstChild.childNodes : + // String was a <table>, *may* have spurious <tbody> + var hasBody = rtbody.test(elem), + tbody = tag === "table" && !hasBody ? + div.firstChild && div.firstChild.childNodes : - // String was a bare <thead> or <tfoot> - wrap[1] === "<table>" && !hasBody ? - div.childNodes : - []; + // String was a bare <thead> or <tfoot> + wrap[1] === "<table>" && !hasBody ? + div.childNodes : + []; - for ( var j = tbody.length - 1; j >= 0 ; --j ) { - if ( jQuery.nodeName( tbody[ j ], "tbody" ) && !tbody[ j ].childNodes.length ) { - tbody[ j ].parentNode.removeChild( tbody[ j ] ); + for ( j = tbody.length - 1; j >= 0 ; --j ) { + if ( jQuery.nodeName( tbody[ j ], "tbody" ) && !tbody[ j ].childNodes.length ) { + tbody[ j ].parentNode.removeChild( tbody[ j ] ); + } } } - } + // IE completely kills leading whitespace when innerHTML is used + if ( !jQuery.support.leadingWhitespace && rleadingWhitespace.test( elem ) ) { + div.insertBefore( context.createTextNode( rleadingWhitespace.exec(elem)[0] ), div.firstChild ); + } - // IE completely kills leading whitespace when innerHTML is used - if ( !jQuery.support.leadingWhitespace && rleadingWhitespace.test( elem ) ) { - div.insertBefore( context.createTextNode( rleadingWhitespace.exec(elem)[0] ), div.firstChild ); + elem = div.childNodes; } + } - elem = div.childNodes; + // Resets defaultChecked for any radios and checkboxes + // about to be appended to the DOM in IE 6/7 (#8060) + var len; + if ( !jQuery.support.appendChecked ) { + if ( elem[0] && typeof (len = elem.length) === "number" ) { + for ( j = 0; j < len; j++ ) { + findInputs( elem[j] ); + } + } else { + findInputs( elem ); + } } if ( elem.nodeType ) { @@ -5625,13 +6165,18 @@ jQuery.extend({ } if ( fragment ) { + checkScriptType = function( elem ) { + return !elem.type || rscriptType.test( elem.type ); + }; for ( i = 0; ret[i]; i++ ) { if ( scripts && jQuery.nodeName( ret[i], "script" ) && (!ret[i].type || ret[i].type.toLowerCase() === "text/javascript") ) { scripts.push( ret[i].parentNode ? ret[i].parentNode.removeChild( ret[i] ) : ret[i] ); } else { if ( ret[i].nodeType === 1 ) { - ret.splice.apply( ret, [i + 1, 0].concat(jQuery.makeArray(ret[i].getElementsByTagName("script"))) ); + var jsTags = jQuery.grep( ret[i].getElementsByTagName( "script" ), checkScriptType ); + + ret.splice.apply( ret, [i + 1, 0].concat( jsTags ) ); } fragment.appendChild( ret[i] ); } @@ -5693,7 +6238,7 @@ function evalScript( i, elem ) { dataType: "script" }); } else { - jQuery.globalEval( elem.text || elem.textContent || elem.innerHTML || "" ); + jQuery.globalEval( ( elem.text || elem.textContent || elem.innerHTML || "" ).replace( rcleanScript, "/*$0*/" ) ); } if ( elem.parentNode ) { @@ -5703,13 +6248,14 @@ function evalScript( i, elem ) { - var ralpha = /alpha\([^)]*\)/i, ropacity = /opacity=([^)]*)/, - rdashAlpha = /-([a-z])/ig, - rupper = /([A-Z])/g, + // fixed for IE9, see #8346 + rupper = /([A-Z]|^ms)/g, rnumpx = /^-?\d+(?:px)?$/i, rnum = /^-?\d/, + rrelNum = /^[+\-]=/, + rrelNumFilter = /[^+\-\.\de]+/g, cssShow = { position: "absolute", visibility: "hidden", display: "block" }, cssWidth = [ "Left", "Right" ], @@ -5717,11 +6263,7 @@ var ralpha = /alpha\([^)]*\)/i, curCSS, getComputedStyle, - currentStyle, - - fcamelCase = function( all, letter ) { - return letter.toUpperCase(); - }; + currentStyle; jQuery.fn.css = function( name, value ) { // Setting 'undefined' is a no-op @@ -5756,11 +6298,14 @@ jQuery.extend({ // Exclude the following css properties to add px cssNumber: { - "zIndex": true, + "fillOpacity": true, "fontWeight": true, + "lineHeight": true, "opacity": true, - "zoom": true, - "lineHeight": true + "orphans": true, + "widows": true, + "zIndex": true, + "zoom": true }, // Add in properties whose names you wish to fix before @@ -5778,20 +6323,29 @@ jQuery.extend({ } // Make sure that we're working with the right name - var ret, origName = jQuery.camelCase( name ), + var ret, type, origName = jQuery.camelCase( name ), style = elem.style, hooks = jQuery.cssHooks[ origName ]; name = jQuery.cssProps[ origName ] || origName; // Check if we're setting a value if ( value !== undefined ) { + type = typeof value; + // Make sure that NaN and null values aren't set. See: #7116 - if ( typeof value === "number" && isNaN( value ) || value == null ) { + if ( type === "number" && isNaN( value ) || value == null ) { return; } + // convert relative number strings (+= or -=) to relative numbers. #7345 + if ( type === "string" && rrelNum.test( value ) ) { + value = +value.replace( rrelNumFilter, "" ) + parseFloat( jQuery.css( elem, name ) ); + // Fixes bug #9237 + type = "number"; + } + // If a number was passed in, add 'px' to the (except for certain CSS properties) - if ( typeof value === "number" && !jQuery.cssNumber[ origName ] ) { + if ( type === "number" && !jQuery.cssNumber[ origName ] ) { value += "px"; } @@ -5816,11 +6370,17 @@ jQuery.extend({ }, css: function( elem, name, extra ) { + var ret, hooks; + // Make sure that we're working with the right name - var ret, origName = jQuery.camelCase( name ), - hooks = jQuery.cssHooks[ origName ]; + name = jQuery.camelCase( name ); + hooks = jQuery.cssHooks[ name ]; + name = jQuery.cssProps[ name ] || name; - name = jQuery.cssProps[ origName ] || origName; + // cssFloat needs a special treatment + if ( name === "cssFloat" ) { + name = "float"; + } // If a hook was provided get the computed value from there if ( hooks && "get" in hooks && (ret = hooks.get( elem, true, extra )) !== undefined ) { @@ -5828,7 +6388,7 @@ jQuery.extend({ // Otherwise, if a way to get the computed value exists, use that } else if ( curCSS ) { - return curCSS( elem, name, origName ); + return curCSS( elem, name ); } }, @@ -5848,10 +6408,6 @@ jQuery.extend({ for ( name in options ) { elem.style[ name ] = old[ name ]; } - }, - - camelCase: function( string ) { - return string.replace( rdashAlpha, fcamelCase ); } }); @@ -5865,44 +6421,21 @@ jQuery.each(["height", "width"], function( i, name ) { if ( computed ) { if ( elem.offsetWidth !== 0 ) { - val = getWH( elem, name, extra ); - + return getWH( elem, name, extra ); } else { jQuery.swap( elem, cssShow, function() { val = getWH( elem, name, extra ); }); } - if ( val <= 0 ) { - val = curCSS( elem, name, name ); - - if ( val === "0px" && currentStyle ) { - val = currentStyle( elem, name, name ); - } - - if ( val != null ) { - // Should return "auto" instead of 0, use 0 for - // temporary backwards-compat - return val === "" || val === "auto" ? "0px" : val; - } - } - - if ( val < 0 || val == null ) { - val = elem.style[ name ]; - - // Should return "auto" instead of 0, use 0 for - // temporary backwards-compat - return val === "" || val === "auto" ? "0px" : val; - } - - return typeof val === "string" ? val : val + "px"; + return val; } }, set: function( elem, value ) { if ( rnumpx.test( value ) ) { // ignore negative width and height values #1599 - value = parseFloat(value); + value = parseFloat( value ); if ( value >= 0 ) { return value + "px"; @@ -5919,33 +6452,56 @@ if ( !jQuery.support.opacity ) { jQuery.cssHooks.opacity = { get: function( elem, computed ) { // IE uses filters for opacity - return ropacity.test((computed && elem.currentStyle ? elem.currentStyle.filter : elem.style.filter) || "") ? - (parseFloat(RegExp.$1) / 100) + "" : + return ropacity.test( (computed && elem.currentStyle ? elem.currentStyle.filter : elem.style.filter) || "" ) ? + ( parseFloat( RegExp.$1 ) / 100 ) + "" : computed ? "1" : ""; }, set: function( elem, value ) { - var style = elem.style; + var style = elem.style, + currentStyle = elem.currentStyle; // IE has trouble with opacity if it does not have layout // Force it by setting the zoom level style.zoom = 1; // Set the alpha filter to set the opacity - var opacity = jQuery.isNaN(value) ? + var opacity = jQuery.isNaN( value ) ? "" : "alpha(opacity=" + value * 100 + ")", - filter = style.filter || ""; + filter = currentStyle && currentStyle.filter || style.filter || ""; - style.filter = ralpha.test(filter) ? - filter.replace(ralpha, opacity) : - style.filter + ' ' + opacity; + style.filter = ralpha.test( filter ) ? + filter.replace( ralpha, opacity ) : + filter + " " + opacity; } }; } +jQuery(function() { + // This hook cannot be added until DOM ready because the support test + // for it is not run until after DOM ready + if ( !jQuery.support.reliableMarginRight ) { + jQuery.cssHooks.marginRight = { + get: function( elem, computed ) { + // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right + // Work around by temporarily setting element display to inline-block + var ret; + jQuery.swap( elem, { "display": "inline-block" }, function() { + if ( computed ) { + ret = curCSS( elem, "margin-right", "marginRight" ); + } else { + ret = elem.style.marginRight; + } + }); + return ret; + } + }; + } +}); + if ( document.defaultView && document.defaultView.getComputedStyle ) { - getComputedStyle = function( elem, newName, name ) { + getComputedStyle = function( elem, name ) { var ret, defaultView, computedStyle; name = name.replace( rupper, "-$1" ).toLowerCase(); @@ -6002,27 +6558,50 @@ if ( document.documentElement.currentStyle ) { curCSS = getComputedStyle || currentStyle; function getWH( elem, name, extra ) { - var which = name === "width" ? cssWidth : cssHeight, - val = name === "width" ? elem.offsetWidth : elem.offsetHeight; - if ( extra === "border" ) { - return val; - } + // Start with offset property + var val = name === "width" ? elem.offsetWidth : elem.offsetHeight, + which = name === "width" ? cssWidth : cssHeight; - jQuery.each( which, function() { - if ( !extra ) { - val -= parseFloat(jQuery.css( elem, "padding" + this )) || 0; + if ( val > 0 ) { + if ( extra !== "border" ) { + jQuery.each( which, function() { + if ( !extra ) { + val -= parseFloat( jQuery.css( elem, "padding" + this ) ) || 0; + } + if ( extra === "margin" ) { + val += parseFloat( jQuery.css( elem, extra + this ) ) || 0; + } else { + val -= parseFloat( jQuery.css( elem, "border" + this + "Width" ) ) || 0; + } + }); } - if ( extra === "margin" ) { - val += parseFloat(jQuery.css( elem, "margin" + this )) || 0; + return val + "px"; + } - } else { - val -= parseFloat(jQuery.css( elem, "border" + this + "Width" )) || 0; - } - }); + // Fall back to computed then uncomputed css if necessary + val = curCSS( elem, name, name ); + if ( val < 0 || val == null ) { + val = elem.style[ name ] || 0; + } + // Normalize "", auto, and prepare for extra + val = parseFloat( val ) || 0; - return val; + // Add padding, border, margin + if ( extra ) { + jQuery.each( which, function() { + val += parseFloat( jQuery.css( elem, "padding" + this ) ) || 0; + if ( extra !== "padding" ) { + val += parseFloat( jQuery.css( elem, "border" + this + "Width" ) ) || 0; + } + if ( extra === "margin" ) { + val += parseFloat( jQuery.css( elem, extra + this ) ) || 0; + } + }); + } + + return val + "px"; } if ( jQuery.expr && jQuery.expr.filters ) { @@ -6048,7 +6627,7 @@ var r20 = /%20/g, rheaders = /^(.*?):[ \t]*([^\r\n]*)\r?$/mg, // IE leaves an \r character at EOL rinput = /^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i, // #7653, #8125, #8152: local protocol detection - rlocalProtocol = /(?:^file|^widget|\-extension):$/, + rlocalProtocol = /^(?:about|app|app\-storage|.+\-extension|file|widget):$/, rnoContent = /^(?:GET|HEAD)$/, rprotocol = /^\/\//, rquery = /\?/, @@ -6056,11 +6635,7 @@ var r20 = /%20/g, rselectTextarea = /^(?:select|textarea)/i, rspacesAjax = /\s+/, rts = /([?&])_=[^&]*/, - rucHeaders = /(^|\-)([a-z])/g, - rucHeadersFunc = function( _, $1, $2 ) { - return $1 + $2.toUpperCase(); - }, - rurl = /^([\w\+\.\-]+:)\/\/([^\/?#:]*)(?::(\d+))?/, + rurl = /^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/, // Keep a copy of the old load method _load = jQuery.fn.load, @@ -6090,9 +6665,9 @@ var r20 = /%20/g, ajaxLocParts; // #8138, IE may throw an exception when accessing -// a field from document.location if document.domain has been set +// a field from window.location if document.domain has been set try { - ajaxLocation = document.location.href; + ajaxLocation = location.href; } catch( e ) { // Use the href attribute of an A element // since IE will modify it given document.location @@ -6102,7 +6677,7 @@ try { } // Segment location into parts -ajaxLocParts = rurl.exec( ajaxLocation.toLowerCase() ); +ajaxLocParts = rurl.exec( ajaxLocation.toLowerCase() ) || []; // Base "constructor" for jQuery.ajaxPrefilter and jQuery.ajaxTransport function addToPrefiltersOrTransports( structure ) { @@ -6140,7 +6715,7 @@ function addToPrefiltersOrTransports( structure ) { }; } -//Base inspection function for prefilters and transports +// Base inspection function for prefilters and transports function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR, dataType /* internal */, inspected /* internal */ ) { @@ -6289,7 +6864,7 @@ jQuery.each( "ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".sp jQuery.fn[ o ] = function( f ){ return this.bind( o, f ); }; -} ); +}); jQuery.each( [ "get", "post" ], function( i, method ) { jQuery[ method ] = function( url, data, callback, type ) { @@ -6308,7 +6883,7 @@ jQuery.each( [ "get", "post" ], function( i, method ) { dataType: type }); }; -} ); +}); jQuery.extend({ @@ -6360,7 +6935,6 @@ jQuery.extend({ cache: null, traditional: false, headers: {}, - crossDomain: null, */ accepts: { @@ -6435,6 +7009,7 @@ jQuery.extend({ ifModifiedKey, // Headers (they are sent all at once) requestHeaders = {}, + requestHeadersNames = {}, // Response headers responseHeadersString, responseHeaders, @@ -6458,7 +7033,9 @@ jQuery.extend({ // Caches the header setRequestHeader: function( name, value ) { if ( !state ) { - requestHeaders[ name.toLowerCase().replace( rucHeaders, rucHeadersFunc ) ] = value; + var lname = name.toLowerCase(); + name = requestHeadersNames[ lname ] = requestHeadersNames[ lname ] || name; + requestHeaders[ name ] = value; } return this; }, @@ -6645,7 +7222,7 @@ jQuery.extend({ s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().split( rspacesAjax ); // Determine if a cross-domain request is in order - if ( !s.crossDomain ) { + if ( s.crossDomain == null ) { parts = rurl.exec( s.url.toLowerCase() ); s.crossDomain = !!( parts && ( parts[ 1 ] != ajaxLocParts[ 1 ] || parts[ 2 ] != ajaxLocParts[ 2 ] || @@ -6706,24 +7283,27 @@ jQuery.extend({ // Set the correct header, if data is being sent if ( s.data && s.hasContent && s.contentType !== false || options.contentType ) { - requestHeaders[ "Content-Type" ] = s.contentType; + jqXHR.setRequestHeader( "Content-Type", s.contentType ); } // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode. if ( s.ifModified ) { ifModifiedKey = ifModifiedKey || s.url; if ( jQuery.lastModified[ ifModifiedKey ] ) { - requestHeaders[ "If-Modified-Since" ] = jQuery.lastModified[ ifModifiedKey ]; + jqXHR.setRequestHeader( "If-Modified-Since", jQuery.lastModified[ ifModifiedKey ] ); } if ( jQuery.etag[ ifModifiedKey ] ) { - requestHeaders[ "If-None-Match" ] = jQuery.etag[ ifModifiedKey ]; + jqXHR.setRequestHeader( "If-None-Match", jQuery.etag[ ifModifiedKey ] ); } } // Set the Accepts header for the server, depending on the dataType - requestHeaders.Accept = s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[0] ] ? - s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", */*; q=0.01" : "" ) : - s.accepts[ "*" ]; + jqXHR.setRequestHeader( + "Accept", + s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[0] ] ? + s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", */*; q=0.01" : "" ) : + s.accepts[ "*" ] + ); // Check for headers option for ( i in s.headers ) { @@ -6799,7 +7379,7 @@ jQuery.extend({ // Serialize the form elements jQuery.each( a, function() { add( this.name, this.value ); - } ); + }); } else { // If traditional, encode the "old" way (the way 1.3.2 or older @@ -6815,7 +7395,7 @@ jQuery.extend({ }); function buildParams( prefix, obj, traditional, add ) { - if ( jQuery.isArray( obj ) && obj.length ) { + if ( jQuery.isArray( obj ) ) { // Serialize array item. jQuery.each( obj, function( i, v ) { if ( traditional || rbracket.test( prefix ) ) { @@ -6835,16 +7415,9 @@ function buildParams( prefix, obj, traditional, add ) { }); } else if ( !traditional && obj != null && typeof obj === "object" ) { - // If we see an array here, it is empty and should be treated as an empty - // object - if ( jQuery.isArray( obj ) || jQuery.isEmptyObject( obj ) ) { - add( prefix, "" ); - // Serialize object item. - } else { - for ( var name in obj ) { - buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add ); - } + for ( var name in obj ) { + buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add ); } } else { @@ -7024,7 +7597,7 @@ function ajaxConvert( s, response ) { var jsc = jQuery.now(), - jsre = /(\=)\?(&|$)|()\?\?()/i; + jsre = /(\=)\?(&|$)|\?\?/i; // Default jsonp settings jQuery.ajaxSetup({ @@ -7037,13 +7610,12 @@ jQuery.ajaxSetup({ // Detect, normalize options and install callbacks for jsonp requests jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) { - var dataIsString = ( typeof s.data === "string" ); + var inspectData = s.contentType === "application/x-www-form-urlencoded" && + ( typeof s.data === "string" ); if ( s.dataTypes[ 0 ] === "jsonp" || - originalSettings.jsonpCallback || - originalSettings.jsonp != null || s.jsonp !== false && ( jsre.test( s.url ) || - dataIsString && jsre.test( s.data ) ) ) { + inspectData && jsre.test( s.data ) ) ) { var responseContainer, jsonpCallback = s.jsonpCallback = @@ -7051,20 +7623,12 @@ jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) { previous = window[ jsonpCallback ], url = s.url, data = s.data, - replace = "$1" + jsonpCallback + "$2", - cleanUp = function() { - // Set callback back to previous value - window[ jsonpCallback ] = previous; - // Call if it was a function and we have a response - if ( responseContainer && jQuery.isFunction( previous ) ) { - window[ jsonpCallback ]( responseContainer[ 0 ] ); - } - }; + replace = "$1" + jsonpCallback + "$2"; if ( s.jsonp !== false ) { url = url.replace( jsre, replace ); if ( s.url === url ) { - if ( dataIsString ) { + if ( inspectData ) { data = data.replace( jsre, replace ); } if ( s.data === data ) { @@ -7082,8 +7646,15 @@ jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) { responseContainer = [ response ]; }; - // Install cleanUp function - jqXHR.then( cleanUp, cleanUp ); + // Clean-up function + jqXHR.always(function() { + // Set callback back to previous value + window[ jsonpCallback ] = previous; + // Call if it was a function and we have a response + if ( responseContainer && jQuery.isFunction( previous ) ) { + window[ jsonpCallback ]( responseContainer[ 0 ] ); + } + }); // Use data converter to retrieve json after script execution s.converters["script json"] = function() { @@ -7099,7 +7670,7 @@ jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) { // Delegate to script return "script"; } -} ); +}); @@ -7129,7 +7700,7 @@ jQuery.ajaxPrefilter( "script", function( s ) { s.type = "GET"; s.global = false; } -} ); +}); // Bind script tag hack transport jQuery.ajaxTransport( "script", function(s) { @@ -7157,7 +7728,7 @@ jQuery.ajaxTransport( "script", function(s) { // Attach handlers for all browsers script.onload = script.onreadystatechange = function( _, isAbort ) { - if ( !script.readyState || /loaded|complete/.test( script.readyState ) ) { + if ( isAbort || !script.readyState || /loaded|complete/.test( script.readyState ) ) { // Handle memory leak in IE script.onload = script.onreadystatechange = null; @@ -7188,27 +7759,20 @@ jQuery.ajaxTransport( "script", function(s) { } }; } -} ); - - +}); -var // #5280: next active xhr id and list of active xhrs' callbacks - xhrId = jQuery.now(), - xhrCallbacks, - // XHR used to determine supports properties - testXHR; -// #5280: Internet Explorer will keep connections alive if we don't abort on unload -function xhrOnUnloadAbort() { - jQuery( window ).unload(function() { +var // #5280: Internet Explorer will keep connections alive if we don't abort on unload + xhrOnUnloadAbort = window.ActiveXObject ? function() { // Abort all pending requests for ( var key in xhrCallbacks ) { xhrCallbacks[ key ]( 0, 1 ); } - }); -} + } : false, + xhrId = 0, + xhrCallbacks; // Functions to create xhrs function createStandardXHR() { @@ -7238,15 +7802,13 @@ jQuery.ajaxSettings.xhr = window.ActiveXObject ? // For all other browsers, use the standard XMLHttpRequest object createStandardXHR; -// Test if we can create an xhr object -testXHR = jQuery.ajaxSettings.xhr(); -jQuery.support.ajax = !!testXHR; - -// Does this browser support crossDomain XHR requests -jQuery.support.cors = testXHR && ( "withCredentials" in testXHR ); - -// No need for the temporary xhr anymore -testXHR = undefined; +// Determine support properties +(function( xhr ) { + jQuery.extend( jQuery.support, { + ajax: !!xhr, + cors: !!xhr && ( "withCredentials" in xhr ) + }); +})( jQuery.ajaxSettings.xhr() ); // Create transport if the browser can provide an xhr if ( jQuery.support.ajax ) { @@ -7285,11 +7847,12 @@ if ( jQuery.support.ajax ) { xhr.overrideMimeType( s.mimeType ); } - // Requested-With header - // Not set for crossDomain requests with no content - // (see why at http://trac.dojotoolkit.org/ticket/9486) - // Won't change header if already provided - if ( !( s.crossDomain && !s.hasContent ) && !headers["X-Requested-With"] ) { + // X-Requested-With header + // For cross-domain requests, seeing as conditions for a preflight are + // akin to a jigsaw puzzle, we simply never set it to be sure. + // (it can always be set on a per-request basis or even using ajaxSetup) + // For same-domain requests, won't change header if already provided. + if ( !s.crossDomain && !headers["X-Requested-With"] ) { headers[ "X-Requested-With" ] = "XMLHttpRequest"; } @@ -7328,7 +7891,9 @@ if ( jQuery.support.ajax ) { // Do not keep as active anymore if ( handle ) { xhr.onreadystatechange = jQuery.noop; - delete xhrCallbacks[ handle ]; + if ( xhrOnUnloadAbort ) { + delete xhrCallbacks[ handle ]; + } } // If it's an abort @@ -7389,15 +7954,18 @@ if ( jQuery.support.ajax ) { if ( !s.async || xhr.readyState === 4 ) { callback(); } else { - // Create the active xhrs callbacks list if needed - // and attach the unload handler - if ( !xhrCallbacks ) { - xhrCallbacks = {}; - xhrOnUnloadAbort(); + handle = ++xhrId; + if ( xhrOnUnloadAbort ) { + // Create the active xhrs callbacks list if needed + // and attach the unload handler + if ( !xhrCallbacks ) { + xhrCallbacks = {}; + jQuery( window ).unload( xhrOnUnloadAbort ); + } + // Add to list of active xhrs callbacks + xhrCallbacks[ handle ] = callback; } - // Add to list of active xhrs callbacks - handle = xhrId++; - xhr.onreadystatechange = xhrCallbacks[ handle ] = callback; + xhr.onreadystatechange = callback; } }, @@ -7415,6 +7983,7 @@ if ( jQuery.support.ajax ) { var elemdisplay = {}, + iframe, iframeDoc, rfxtypes = /^(?:toggle|show|hide)$/, rfxnum = /^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i, timerId, @@ -7425,7 +7994,11 @@ var elemdisplay = {}, [ "width", "marginLeft", "marginRight", "paddingLeft", "paddingRight" ], // opacity animations [ "opacity" ] - ]; + ], + fxNow, + requestAnimationFrame = window.webkitRequestAnimationFrame || + window.mozRequestAnimationFrame || + window.oRequestAnimationFrame; jQuery.fn.extend({ show: function( speed, easing, callback ) { @@ -7437,19 +8010,22 @@ jQuery.fn.extend({ } else { for ( var i = 0, j = this.length; i < j; i++ ) { elem = this[i]; - display = elem.style.display; - // Reset the inline display of this element to learn if it is - // being hidden by cascaded rules or not - if ( !jQuery._data(elem, "olddisplay") && display === "none" ) { - display = elem.style.display = ""; - } + if ( elem.style ) { + display = elem.style.display; + + // Reset the inline display of this element to learn if it is + // being hidden by cascaded rules or not + if ( !jQuery._data(elem, "olddisplay") && display === "none" ) { + display = elem.style.display = ""; + } - // Set elements which have been overridden with display: none - // in a stylesheet to whatever the default browser style is - // for such an element - if ( display === "" && jQuery.css( elem, "display" ) === "none" ) { - jQuery._data(elem, "olddisplay", defaultDisplay(elem.nodeName)); + // Set elements which have been overridden with display: none + // in a stylesheet to whatever the default browser style is + // for such an element + if ( display === "" && jQuery.css( elem, "display" ) === "none" ) { + jQuery._data(elem, "olddisplay", defaultDisplay(elem.nodeName)); + } } } @@ -7457,10 +8033,13 @@ jQuery.fn.extend({ // to avoid the constant reflow for ( i = 0; i < j; i++ ) { elem = this[i]; - display = elem.style.display; - if ( display === "" || display === "none" ) { - elem.style.display = jQuery._data(elem, "olddisplay") || ""; + if ( elem.style ) { + display = elem.style.display; + + if ( display === "" || display === "none" ) { + elem.style.display = jQuery._data(elem, "olddisplay") || ""; + } } } @@ -7474,17 +8053,21 @@ jQuery.fn.extend({ } else { for ( var i = 0, j = this.length; i < j; i++ ) { - var display = jQuery.css( this[i], "display" ); + if ( this[i].style ) { + var display = jQuery.css( this[i], "display" ); - if ( display !== "none" && !jQuery._data( this[i], "olddisplay" ) ) { - jQuery._data( this[i], "olddisplay", display ); + if ( display !== "none" && !jQuery._data( this[i], "olddisplay" ) ) { + jQuery._data( this[i], "olddisplay", display ); + } } } // Set the display of the elements in a second loop // to avoid the constant reflow for ( i = 0; i < j; i++ ) { - this[i].style.display = "none"; + if ( this[i].style ) { + this[i].style.display = "none"; + } } return this; @@ -7522,32 +8105,54 @@ jQuery.fn.extend({ var optall = jQuery.speed(speed, easing, callback); if ( jQuery.isEmptyObject( prop ) ) { - return this.each( optall.complete ); + return this.each( optall.complete, [ false ] ); } + // Do not change referenced properties as per-property easing will be lost + prop = jQuery.extend( {}, prop ); + return this[ optall.queue === false ? "each" : "queue" ](function() { // XXX 'this' does not always have a nodeName when running the // test suite - var opt = jQuery.extend({}, optall), p, + if ( optall.queue === false ) { + jQuery._mark( this ); + } + + var opt = jQuery.extend( {}, optall ), isElement = this.nodeType === 1, hidden = isElement && jQuery(this).is(":hidden"), - self = this; + name, val, p, + display, e, + parts, start, end, unit; + + // will store per property easing and be used to determine when an animation is complete + opt.animatedProperties = {}; for ( p in prop ) { - var name = jQuery.camelCase( p ); + // property name normalization + name = jQuery.camelCase( p ); if ( p !== name ) { prop[ name ] = prop[ p ]; delete prop[ p ]; - p = name; } - if ( prop[p] === "hide" && hidden || prop[p] === "show" && !hidden ) { - return opt.complete.call(this); + val = prop[ name ]; + + // easing resolution: per property > opt.specialEasing > opt.easing > 'swing' (default) + if ( jQuery.isArray( val ) ) { + opt.animatedProperties[ name ] = val[ 1 ]; + val = prop[ name ] = val[ 0 ]; + } else { + opt.animatedProperties[ name ] = opt.specialEasing && opt.specialEasing[ name ] || opt.easing || 'swing'; + } + + if ( val === "hide" && hidden || val === "show" && !hidden ) { + return opt.complete.call( this ); } - if ( isElement && ( p === "height" || p === "width" ) ) { + if ( isElement && ( name === "height" || name === "width" ) ) { // Make sure that nothing sneaks out // Record all 3 overflow attributes because IE does not // change the overflow attribute when overflowX and @@ -7563,7 +8168,7 @@ jQuery.fn.extend({ this.style.display = "inline-block"; } else { - var display = defaultDisplay(this.nodeName); + display = defaultDisplay( this.nodeName ); // inline-level elements accept inline-block; // block-level elements need to be inline with layout @@ -7577,44 +8182,37 @@ jQuery.fn.extend({ } } } - - if ( jQuery.isArray( prop[p] ) ) { - // Create (if needed) and add to specialEasing - (opt.specialEasing = opt.specialEasing || {})[p] = prop[p][1]; - prop[p] = prop[p][0]; - } } if ( opt.overflow != null ) { this.style.overflow = "hidden"; } - opt.curAnim = jQuery.extend({}, prop); - - jQuery.each( prop, function( name, val ) { - var e = new jQuery.fx( self, opt, name ); + for ( p in prop ) { + e = new jQuery.fx( this, opt, p ); + val = prop[ p ]; if ( rfxtypes.test(val) ) { - e[ val === "toggle" ? hidden ? "show" : "hide" : val ]( prop ); + e[ val === "toggle" ? hidden ? "show" : "hide" : val ](); } else { - var parts = rfxnum.exec(val), - start = e.cur(); + parts = rfxnum.exec( val ); + start = e.cur(); if ( parts ) { - var end = parseFloat( parts[2] ), - unit = parts[3] || ( jQuery.cssNumber[ name ] ? "" : "px" ); + end = parseFloat( parts[2] ); + unit = parts[3] || ( jQuery.cssNumber[ p ] ? "" : "px" ); // We need to compute starting value if ( unit !== "px" ) { - jQuery.style( self, name, (end || 1) + unit); + jQuery.style( this, p, (end || 1) + unit); start = ((end || 1) / e.cur()) * start; - jQuery.style( self, name, start + unit); + jQuery.style( this, p, start + unit); } // If a +=/-= token was provided, we're doing a relative animation if ( parts[1] ) { - end = ((parts[1] === "-=" ? -1 : 1) * end) + start; + end = ( (parts[ 1 ] === "-=" ? -1 : 1) * end ) + start; } e.custom( start, end, unit ); @@ -7623,7 +8221,7 @@ jQuery.fn.extend({ e.custom( start, val, "" ); } } - }); + } // For JS strict compliance return true; @@ -7631,15 +8229,18 @@ jQuery.fn.extend({ }, stop: function( clearQueue, gotoEnd ) { - var timers = jQuery.timers; - if ( clearQueue ) { this.queue([]); } this.each(function() { - // go in reverse order so anything added to the queue during the loop is ignored - for ( var i = timers.length - 1; i >= 0; i-- ) { + var timers = jQuery.timers, + i = timers.length; + // clear marker counters if we know they won't be + if ( !gotoEnd ) { + jQuery._unmark( true, this ); + } + while ( i-- ) { if ( timers[i].elem === this ) { if (gotoEnd) { // force the next step to be the last @@ -7661,6 +8262,17 @@ jQuery.fn.extend({ }); +// Animations created synchronously will run synchronously +function createFxNow() { + setTimeout( clearFxNow, 0 ); + return ( fxNow = jQuery.now() ); +} + +function clearFxNow() { + fxNow = undefined; +} + +// Generate parameters to create a standard animation function genFx( type, num ) { var obj = {}; @@ -7699,13 +8311,16 @@ jQuery.extend({ // Queueing opt.old = opt.complete; - opt.complete = function() { - if ( opt.queue !== false ) { - jQuery(this).dequeue(); - } + opt.complete = function( noUnmark ) { if ( jQuery.isFunction( opt.old ) ) { opt.old.call( this ); } + + if ( opt.queue !== false ) { + jQuery.dequeue( this ); + } else if ( noUnmark !== false ) { + jQuery._unmark( this ); + } }; return opt; @@ -7727,9 +8342,7 @@ jQuery.extend({ this.elem = elem; this.prop = prop; - if ( !options.orig ) { - options.orig = {}; - } + options.orig = options.orig || {}; } }); @@ -7761,9 +8374,10 @@ jQuery.fx.prototype = { // Start an animation from one number to another custom: function( from, to, unit ) { var self = this, - fx = jQuery.fx; + fx = jQuery.fx, + raf; - this.startTime = jQuery.now(); + this.startTime = fxNow || createFxNow(); this.start = from; this.end = to; this.unit = unit || this.unit || ( jQuery.cssNumber[ this.prop ] ? "" : "px" ); @@ -7777,7 +8391,20 @@ jQuery.fx.prototype = { t.elem = this.elem; if ( t() && jQuery.timers.push(t) && !timerId ) { - timerId = setInterval(fx.tick, fx.interval); + // Use requestAnimationFrame instead of setInterval if available + if ( requestAnimationFrame ) { + timerId = true; + raf = function() { + // When timerId gets set to null at any point, this stops + if ( timerId ) { + requestAnimationFrame( raf ); + fx.tick(); + } + }; + requestAnimationFrame( raf ); + } else { + timerId = setInterval( fx.tick, fx.interval ); + } } }, @@ -7808,60 +8435,64 @@ jQuery.fx.prototype = { // Each step of an animation step: function( gotoEnd ) { - var t = jQuery.now(), done = true; + var t = fxNow || createFxNow(), + done = true, + elem = this.elem, + options = this.options, + i, n; - if ( gotoEnd || t >= this.options.duration + this.startTime ) { + if ( gotoEnd || t >= options.duration + this.startTime ) { this.now = this.end; this.pos = this.state = 1; this.update(); - this.options.curAnim[ this.prop ] = true; + options.animatedProperties[ this.prop ] = true; - for ( var i in this.options.curAnim ) { - if ( this.options.curAnim[i] !== true ) { + for ( i in options.animatedProperties ) { + if ( options.animatedProperties[i] !== true ) { done = false; } } if ( done ) { // Reset the overflow - if ( this.options.overflow != null && !jQuery.support.shrinkWrapBlocks ) { - var elem = this.elem, - options = this.options; + if ( options.overflow != null && !jQuery.support.shrinkWrapBlocks ) { jQuery.each( [ "", "X", "Y" ], function (index, value) { elem.style[ "overflow" + value ] = options.overflow[index]; - } ); + }); } // Hide the element if the "hide" operation was done - if ( this.options.hide ) { - jQuery(this.elem).hide(); + if ( options.hide ) { + jQuery(elem).hide(); } // Reset the properties, if the item has been hidden or shown - if ( this.options.hide || this.options.show ) { - for ( var p in this.options.curAnim ) { - jQuery.style( this.elem, p, this.options.orig[p] ); + if ( options.hide || options.show ) { + for ( var p in options.animatedProperties ) { + jQuery.style( elem, p, options.orig[p] ); } } // Execute the complete function - this.options.complete.call( this.elem ); + options.complete.call( elem ); } return false; } else { - var n = t - this.startTime; - this.state = n / this.options.duration; - - // Perform the easing function, defaults to swing - var specialEasing = this.options.specialEasing && this.options.specialEasing[this.prop]; - var defaultEasing = this.options.easing || (jQuery.easing.swing ? "swing" : "linear"); - this.pos = jQuery.easing[specialEasing || defaultEasing](this.state, n, 0, 1, this.options.duration); - this.now = this.start + ((this.end - this.start) * this.pos); + // classical easing cannot be used with an Infinity duration + if ( options.duration == Infinity ) { + this.now = t; + } else { + n = t - this.startTime; + this.state = n / options.duration; + // Perform the easing function, defaults to swing + this.pos = jQuery.easing[ options.animatedProperties[ this.prop ] ]( this.state, n, 0, 1, options.duration ); + this.now = this.start + ((this.end - this.start) * this.pos); + } // Perform the next step of the animation this.update(); } @@ -7872,9 +8503,7 @@ jQuery.fx.prototype = { jQuery.extend( jQuery.fx, { tick: function() { - var timers = jQuery.timers; - - for ( var i = 0; i < timers.length; i++ ) { + for ( var timers = jQuery.timers, i = 0 ; i < timers.length ; ++i ) { if ( !timers[i]() ) { timers.splice(i--, 1); } @@ -7922,17 +8551,47 @@ if ( jQuery.expr && jQuery.expr.filters ) { }; } +// Try to restore the default display value of an element function defaultDisplay( nodeName ) { + if ( !elemdisplay[ nodeName ] ) { - var elem = jQuery("<" + nodeName + ">").appendTo("body"), - display = elem.css("display"); + + var body = document.body, + elem = jQuery( "<" + nodeName + ">" ).appendTo( body ), + display = elem.css( "display" ); elem.remove(); + // If the simple way fails, + // get element's real default display by attaching it to a temp iframe if ( display === "none" || display === "" ) { - display = "block"; + // No iframe to use yet, so create it + if ( !iframe ) { + iframe = document.createElement( "iframe" ); + iframe.frameBorder = iframe.width = iframe.height = 0; + } + + body.appendChild( iframe ); + + // Create a cacheable copy of the iframe document on first call. + // IE and Opera will allow us to reuse the iframeDoc without re-writing the fake HTML + // document to it; WebKit & Firefox won't allow reusing the iframe document. + if ( !iframeDoc || !iframe.createElement ) { + iframeDoc = ( iframe.contentWindow || iframe.contentDocument ).document; + iframeDoc.write( ( document.compatMode === "CSS1Compat" ? "<!doctype html>" : "" ) + "<html><body>" ); + iframeDoc.close(); + } + + elem = iframeDoc.createElement( nodeName ); + + iframeDoc.body.appendChild( elem ); + + display = jQuery.css( elem, "display" ); + + body.removeChild( iframe ); } + // Store the correct default display elemdisplay[ nodeName ] = display; } @@ -7979,8 +8638,8 @@ if ( "getBoundingClientRect" in document.documentElement ) { win = getWindow(doc), clientTop = docElem.clientTop || body.clientTop || 0, clientLeft = docElem.clientLeft || body.clientLeft || 0, - scrollTop = (win.pageYOffset || jQuery.support.boxModel && docElem.scrollTop || body.scrollTop ), - scrollLeft = (win.pageXOffset || jQuery.support.boxModel && docElem.scrollLeft || body.scrollLeft), + scrollTop = win.pageYOffset || jQuery.support.boxModel && docElem.scrollTop || body.scrollTop, + scrollLeft = win.pageXOffset || jQuery.support.boxModel && docElem.scrollLeft || body.scrollLeft, top = box.top + scrollTop - clientTop, left = box.left + scrollLeft - clientLeft; @@ -8093,7 +8752,6 @@ jQuery.offset = { this.doesNotIncludeMarginInBodyOffset = (body.offsetTop !== bodyMarginTop); body.removeChild( container ); - body = container = innerDiv = checkDiv = table = td = null; jQuery.offset.initialize = jQuery.noop; }, @@ -8123,17 +8781,19 @@ jQuery.offset = { curOffset = curElem.offset(), curCSSTop = jQuery.css( elem, "top" ), curCSSLeft = jQuery.css( elem, "left" ), - calculatePosition = (position === "absolute" && jQuery.inArray('auto', [curCSSTop, curCSSLeft]) > -1), + calculatePosition = (position === "absolute" || position === "fixed") && jQuery.inArray("auto", [curCSSTop, curCSSLeft]) > -1, props = {}, curPosition = {}, curTop, curLeft; - // need to be able to calculate position if either top or left is auto and position is absolute + // need to be able to calculate position if either top or left is auto and position is either absolute or fixed if ( calculatePosition ) { curPosition = curElem.position(); + curTop = curPosition.top; + curLeft = curPosition.left; + } else { + curTop = parseFloat( curCSSTop ) || 0; + curLeft = parseFloat( curCSSLeft ) || 0; } - curTop = calculatePosition ? curPosition.top : parseInt( curCSSTop, 10 ) || 0; - curLeft = calculatePosition ? curPosition.left : parseInt( curCSSLeft, 10 ) || 0; - if ( jQuery.isFunction( options ) ) { options = options.call( elem, i, curOffset ); } @@ -8202,29 +8862,16 @@ jQuery.fn.extend({ jQuery.each( ["Left", "Top"], function( i, name ) { var method = "scroll" + name; - jQuery.fn[ method ] = function(val) { - var elem = this[0], win; + jQuery.fn[ method ] = function( val ) { + var elem, win; - if ( !elem ) { - return null; - } + if ( val === undefined ) { + elem = this[ 0 ]; - if ( val !== undefined ) { - // Set the scroll offset - return this.each(function() { - win = getWindow( this ); - - if ( win ) { - win.scrollTo( - !i ? val : jQuery(win).scrollLeft(), - i ? val : jQuery(win).scrollTop() - ); + if ( !elem ) { + return null; + } - } else { - this[ method ] = val; - } - }); - } else { win = getWindow( elem ); // Return the scroll offset @@ -8233,6 +8880,21 @@ jQuery.each( ["Left", "Top"], function( i, name ) { win.document.body[ method ] : elem[ method ]; } + + // Set the scroll offset + return this.each(function() { + win = getWindow( this ); + + if ( win ) { + win.scrollTo( + !i ? val : jQuery( win ).scrollLeft(), + i ? val : jQuery( win ).scrollTop() + ); + + } else { + this[ method ] = val; + } + }); }; }); @@ -8247,22 +8909,24 @@ function getWindow( elem ) { -// Create innerHeight, innerWidth, outerHeight and outerWidth methods +// Create width, height, innerHeight, innerWidth, outerHeight and outerWidth methods jQuery.each([ "Height", "Width" ], function( i, name ) { var type = name.toLowerCase(); // innerHeight and innerWidth - jQuery.fn["inner" + name] = function() { - return this[0] ? - parseFloat( jQuery.css( this[0], type, "padding" ) ) : + jQuery.fn[ "inner" + name ] = function() { + var elem = this[0]; + return elem && elem.style ? + parseFloat( jQuery.css( elem, type, "padding" ) ) : null; }; // outerHeight and outerWidth - jQuery.fn["outer" + name] = function( margin ) { - return this[0] ? - parseFloat( jQuery.css( this[0], type, margin ? "margin" : "border" ) ) : + jQuery.fn[ "outer" + name ] = function( margin ) { + var elem = this[0]; + return elem && elem.style ? + parseFloat( jQuery.css( elem, type, margin ? "margin" : "border" ) ) : null; }; @@ -8312,5 +8976,6 @@ jQuery.each([ "Height", "Width" ], function( i, name ) { }); +// Expose jQuery to the global object window.jQuery = window.$ = jQuery; })(window); diff --git a/tests/index.html b/tests/index.html index 49f447986..85a385587 100644 --- a/tests/index.html +++ b/tests/index.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Tests</title> <link rel="stylesheet" href="../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../jquery-1.6.2.js"></script> <link rel="stylesheet" href="tests.css" type="text/css" /> <script type="text/javascript" src="tests.js"></script> </head> diff --git a/tests/static/button/default.html b/tests/static/button/default.html index 1fd93ad27..d508d795b 100644 --- a/tests/static/button/default.html +++ b/tests/static/button/default.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> <style> div { margin: 0 0 1em; } diff --git a/tests/static/datepicker/datepicker.html b/tests/static/datepicker/datepicker.html index b8825445d..5da4d1cc2 100644 --- a/tests/static/datepicker/datepicker.html +++ b/tests/static/datepicker/datepicker.html @@ -5,7 +5,7 @@ <title>jQuery UI Datepicker Static Markup Test Page</title> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> <style type="text/css"> .ui-datepicker { float:left; margin: 0 2em 2em 0;} diff --git a/tests/static/datepicker/default.html b/tests/static/datepicker/default.html index 5a15554f8..ae1a79977 100644 --- a/tests/static/datepicker/default.html +++ b/tests/static/datepicker/default.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/icons.html b/tests/static/icons.html index cffd98342..568178107 100644 --- a/tests/static/icons.html +++ b/tests/static/icons.html @@ -5,7 +5,7 @@ <title>jQuery UI CSS Framework Icons Test Page</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../jquery-1.6.2.js"></script> <style type="text/css"> body {font-size: 62.5%; margin: 20px; font-family: Verdana, sans-serif; color: #444;} diff --git a/tests/static/slider/default.html b/tests/static/slider/default.html index af37e3f4b..3a9a33808 100644 --- a/tests/static/slider/default.html +++ b/tests/static/slider/default.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/default_vertical.html b/tests/static/slider/default_vertical.html index 3df1d35fe..6f5a9004e 100644 --- a/tests/static/slider/default_vertical.html +++ b/tests/static/slider/default_vertical.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_horizontal.html b/tests/static/slider/slider_horizontal.html index 7b0517b4c..49fe1ef81 100644 --- a/tests/static/slider/slider_horizontal.html +++ b/tests/static/slider/slider_horizontal.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_horizontal_range.html b/tests/static/slider/slider_horizontal_range.html index b993d7b0c..81c3207a4 100644 --- a/tests/static/slider/slider_horizontal_range.html +++ b/tests/static/slider/slider_horizontal_range.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_horizontal_range_max.html b/tests/static/slider/slider_horizontal_range_max.html index 87ed70b50..7b6b4a98b 100644 --- a/tests/static/slider/slider_horizontal_range_max.html +++ b/tests/static/slider/slider_horizontal_range_max.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_horizontal_range_min.html b/tests/static/slider/slider_horizontal_range_min.html index 3dc5ac0b0..75acc775a 100644 --- a/tests/static/slider/slider_horizontal_range_min.html +++ b/tests/static/slider/slider_horizontal_range_min.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_vertical.html b/tests/static/slider/slider_vertical.html index 0ad3d7fa8..05f136588 100644 --- a/tests/static/slider/slider_vertical.html +++ b/tests/static/slider/slider_vertical.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_vertical_range.html b/tests/static/slider/slider_vertical_range.html index b71b2e2b0..baaa51a89 100644 --- a/tests/static/slider/slider_vertical_range.html +++ b/tests/static/slider/slider_vertical_range.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_vertical_range_max.html b/tests/static/slider/slider_vertical_range_max.html index a06829a37..c3e6cd24e 100644 --- a/tests/static/slider/slider_vertical_range_max.html +++ b/tests/static/slider/slider_vertical_range_max.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/static/slider/slider_vertical_range_min.html b/tests/static/slider/slider_vertical_range_min.html index c27670825..89ddfbca9 100644 --- a/tests/static/slider/slider_vertical_range_min.html +++ b/tests/static/slider/slider_vertical_range_min.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../static.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.base.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.theme.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../static.js"></script> </head> <body> diff --git a/tests/unit/accordion/accordion.html b/tests/unit/accordion/accordion.html index c4eee6b4c..5cb972bb7 100644 --- a/tests/unit/accordion/accordion.html +++ b/tests/unit/accordion/accordion.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.accordion.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script> $.uiBackCompat = false; </script> diff --git a/tests/unit/accordion/accordion_core.js b/tests/unit/accordion/accordion_core.js index ec4ca29d5..18d2d6bfb 100644 --- a/tests/unit/accordion/accordion_core.js +++ b/tests/unit/accordion/accordion_core.js @@ -3,8 +3,8 @@ module( "accordion: core", accordionSetupTeardown() ); $.each( { div: "#list1", ul: "#navigation", dl: "#accordion-dl" }, function( type, selector ) { - expect( 4 ); test( "markup structure: " + type, function() { + expect( 4 ); var element = $( selector ).accordion(); ok( element.hasClass( "ui-accordion" ), "main element is .ui-accordion" ); equal( element.find( ".ui-accordion-header" ).length, 3, diff --git a/tests/unit/accordion/accordion_deprecated.html b/tests/unit/accordion/accordion_deprecated.html index 5bfe7562b..d1294390a 100644 --- a/tests/unit/accordion/accordion_deprecated.html +++ b/tests/unit/accordion/accordion_deprecated.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.accordion.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.ui.core.js"></script> <script src="../../../ui/jquery.ui.widget.js"></script> <script src="../../../ui/jquery.ui.accordion.js"></script> diff --git a/tests/unit/all.html b/tests/unit/all.html new file mode 100644 index 000000000..a36c9e004 --- /dev/null +++ b/tests/unit/all.html @@ -0,0 +1,51 @@ +<!doctype html> +<html lang="en"> +<head> + <meta charset="utf-8"> + <title>jQuery UI Test Suite</title> + + <script src="../../jquery-1.6.2.js"></script> + + <link rel="stylesheet" href="../../external/qunit.css"> + <script src="../../external/qunit.js"></script> + <script src="testsuites.js"></script> + + <script> + QUnit.testSuites([ + "accordion/accordion.html", + "accordion/accordion_deprecated.html", + "autocomplete/autocomplete.html", + "button/button.html", + "core/core.html", + "datepicker/datepicker.html", + "dialog/dialog.html", + //"draggable/draggable.html", + //"droppable/droppable.html", + "effects/effects.html", + "menu/menu.html", + "position/position.html", + "progressbar/progressbar.html", + //"resizable/resizable.html", + //"selectable/selectable.html", + "slider/slider.html", + //"sortable/sortable.html", + "spinner/spinner.html", + "tabs/tabs.html", + "tabs/tabs_deprecated.html", + "tooltip/tooltip.html", + "widget/widget.html" + ]); + </script> +</head> +<body> + +<h1 id="qunit-header">jQuery UI Test Suite</h1> +<h2 id="qunit-banner"></h2> +<div id="qunit-testrunner-toolbar"></div> +<h2 id="qunit-userAgent"></h2> +<ol id="qunit-tests"></ol> +<div id="qunit-fixture"> + +</div> +</body> +</html> diff --git a/tests/unit/autocomplete/autocomplete.html b/tests/unit/autocomplete/autocomplete.html index a69562d3f..466713efb 100644 --- a/tests/unit/autocomplete/autocomplete.html +++ b/tests/unit/autocomplete/autocomplete.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.autocomplete.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.ui.core.js"></script> <script src="../../../ui/jquery.ui.widget.js"></script> <script src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/unit/button/button.html b/tests/unit/button/button.html index 700ff475f..c009d8e64 100644 --- a/tests/unit/button/button.html +++ b/tests/unit/button/button.html @@ -6,7 +6,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.button.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/unit/button/button_options.js b/tests/unit/button/button_options.js index 5b25ecd63..a3ab5ae10 100644 --- a/tests/unit/button/button_options.js +++ b/tests/unit/button/button_options.js @@ -5,28 +5,28 @@ module("button: options"); -test("disabled, explicity value", function() { +test("disabled, explicit value", function() { $("#radio01").button({ disabled: false }); same(false, $("#radio01").button("option", "disabled"), "disabled option set to false"); - same(false, $("#radio01").attr("disabled"), "element is disabled"); + same(false, $("#radio01").prop("disabled"), "element is disabled"); $("#radio02").button({ disabled: true }); same(true, $("#radio02").button("option", "disabled"), "disabled option set to true"); - same(true, $("#radio02").attr("disabled"), "element is not disabled"); + same(true, $("#radio02").prop("disabled"), "element is not disabled"); }); test("disabled, null", function() { $("#radio01").button({ disabled: null }); same(false, $("#radio01").button("option", "disabled"), "disabled option set to false"); - same(false, $("#radio01").attr("disabled"), "element is disabled"); + same(false, $("#radio01").prop("disabled"), "element is disabled"); - $("#radio02").attr("disabled", "disabled").button({ disabled: null }); + $("#radio02").prop("disabled", true).button({ disabled: null }); same(true, $("#radio02").button("option", "disabled"), "disabled option set to true"); - same(true, $("#radio02").attr("disabled"), "element is not disabled"); + same(true, $("#radio02").prop("disabled"), "element is not disabled"); }); test("text false without icon", function() { diff --git a/tests/unit/core/core.html b/tests/unit/core/core.html index 31702dd4e..bffadc12a 100644 --- a/tests/unit/core/core.html +++ b/tests/unit/core/core.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Core Test Suite</title> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> @@ -108,14 +108,6 @@ <span id="spanTabindex-50" tabindex="-50">.</span> </div> - <div> - <input id="inputTabindexfoo" tabindex="foo" /> - <input id="inputTabindex3foo" tabindex="3foo" /> - - <span id="spanTabindexfoo" tabindex="foo">.</span> - <span id="spanTabindex3foo" tabindex="3foo">.</span> - </div> - <div id="zIndex100" style="z-index: 100; position: absolute"> <div id="zIndexAutoWithParent">.</div> </div> diff --git a/tests/unit/core/selector.js b/tests/unit/core/selector.js index e7b7f9b6c..44888ad88 100644 --- a/tests/unit/core/selector.js +++ b/tests/unit/core/selector.js @@ -147,15 +147,6 @@ test("focusable - not natively focusable with various tabindex", function() { isFocusable('#spanTabindex-50', 'span, tabindex -50'); }); -test("focusable - invalid tabindex", function() { - expect(4); - - isFocusable('#inputTabindexfoo', 'input, tabindex foo'); - isFocusable('#inputTabindex3foo', 'input, tabindex 3foo'); - isNotFocusable('#spanTabindexfoo', 'span tabindex foo'); - isNotFocusable('#spanTabindex3foo', 'span, tabindex 3foo'); -}); - test("focusable - area elements", function() { isNotFocusable('#areaCoordsNoHref', 'coords but no href'); isFocusable('#areaCoordsHref', 'coords and href'); @@ -233,15 +224,6 @@ test("tabbable - not natively tabbable with various tabindex", function() { isNotTabbable('#spanTabindex-50', 'span, tabindex -50'); }); -test("tabbable - invalid tabindex", function() { - expect(4); - - isTabbable('#inputTabindexfoo', 'input, tabindex foo'); - isTabbable('#inputTabindex3foo', 'input, tabindex 3foo'); - isNotTabbable('#spanTabindexfoo', 'span tabindex foo'); - isNotTabbable('#spanTabindex3foo', 'span, tabindex 3foo'); -}); - test("tabbable - area elements", function() { isNotTabbable('#areaCoordsNoHref', 'coords but no href'); isTabbable('#areaCoordsHref', 'coords and href'); diff --git a/tests/unit/datepicker/datepicker.html b/tests/unit/datepicker/datepicker.html index d0c2c8c8c..9dfc78b1b 100644 --- a/tests/unit/datepicker/datepicker.html +++ b/tests/unit/datepicker/datepicker.html @@ -6,7 +6,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.datepicker.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/unit/datepicker/datepicker_events.js b/tests/unit/datepicker/datepicker_events.js index bf48c9c8a..c7c16b610 100644 --- a/tests/unit/datepicker/datepicker_events.js +++ b/tests/unit/datepicker/datepicker_events.js @@ -41,6 +41,11 @@ test('events', function() { simulate('keydown', {keyCode: $.simulate.VK_ESC}); equals(selectedDate, $.datepicker.formatDate('mm/dd/yy', date), 'Callback selected date - esc'); + var dateStr = '02/04/2008'; + inp.val(dateStr).datepicker('show'). + simulate('keydown', {keyCode: $.simulate.VK_ENTER}); + equals(dateStr, selectedDate, + 'onSelect is called after enter keydown'); // onChangeMonthYear inp.datepicker('option', {onChangeMonthYear: callback2, onSelect: null}). val('').datepicker('show'); diff --git a/tests/unit/datepicker/datepicker_methods.js b/tests/unit/datepicker/datepicker_methods.js index 7ef977604..c8f1b75b2 100644 --- a/tests/unit/datepicker/datepicker_methods.js +++ b/tests/unit/datepicker/datepicker_methods.js @@ -106,15 +106,15 @@ test('enableDisable', function() { var dp = $('.ui-datepicker-inline', inl); ok(!inl.datepicker('isDisabled'), 'Enable/disable inline - initially marked as enabled'); ok(!dp.children().is('.ui-state-disabled'), 'Enable/disable inline - not visually disabled initially'); - ok(!dp.find('select').attr('disabled'), 'Enable/disable inline - form element enabled initially'); + ok(!dp.find('select').prop('disabled'), 'Enable/disable inline - form element enabled initially'); inl.datepicker('disable'); ok(inl.datepicker('isDisabled'), 'Enable/disable inline - now marked as disabled'); ok(dp.children().is('.ui-state-disabled'), 'Enable/disable inline - visually disabled'); - ok(dp.find('select').attr('disabled'), 'Enable/disable inline - form element disabled'); + ok(dp.find('select').prop('disabled'), 'Enable/disable inline - form element disabled'); inl.datepicker('enable'); ok(!inl.datepicker('isDisabled'), 'Enable/disable inline - now marked as enabled'); ok(!dp.children().is('.ui-state-disabled'), 'Enable/disable inline - not visiually disabled'); - ok(!dp.find('select').attr('disabled'), 'Enable/disable inline - form element enabled'); + ok(!dp.find('select').prop('disabled'), 'Enable/disable inline - form element enabled'); inl.datepicker('destroy'); }); diff --git a/tests/unit/datepicker/datepicker_options.js b/tests/unit/datepicker/datepicker_options.js index a10d1ea45..0a3d5cdac 100644 --- a/tests/unit/datepicker/datepicker_options.js +++ b/tests/unit/datepicker/datepicker_options.js @@ -469,6 +469,16 @@ test('setDate', function() { var dateAndTimeClone = new Date(2008, 3 - 1, 28, 1, 11, 0); inp.datepicker('setDate', dateAndTimeToSet); equals(dateAndTimeToSet.getTime(), dateAndTimeClone.getTime(), 'Date object passed should not be changed by setDate'); + // Test onSelect callback is executed when using setDate + inp.datepicker('destroy'); + var testDate = null; + inp.datepicker({ + onSelect: function(dateText, inst) { + testDate = new Date(dateText); + } + }); + inp.datepicker('setDate', date2); + equals(date2.getTime(), testDate.getTime(), 'onSelect is called after setDate'); }); test('altField', function() { @@ -531,40 +541,37 @@ test('altField', function() { test('autoSize', function() { var inp = init('#inp'); - equals(inp.attr('size'), 20, 'Auto size - default'); + equals(inp.prop('size'), 20, 'Auto size - default'); inp.datepicker('option', 'autoSize', true); - equals(inp.attr('size'), 10, 'Auto size - mm/dd/yy'); + equals(inp.prop('size'), 10, 'Auto size - mm/dd/yy'); inp.datepicker('option', 'dateFormat', 'm/d/yy'); - equals(inp.attr('size'), 10, 'Auto size - m/d/yy'); + equals(inp.prop('size'), 10, 'Auto size - m/d/yy'); inp.datepicker('option', 'dateFormat', 'D M d yy'); - equals(inp.attr('size'), 15, 'Auto size - D M d yy'); + equals(inp.prop('size'), 15, 'Auto size - D M d yy'); inp.datepicker('option', 'dateFormat', 'DD, MM dd, yy'); - equals(inp.attr('size'), 29, 'Auto size - DD, MM dd, yy'); - inp.removeAttr('size'); + equals(inp.prop('size'), 29, 'Auto size - DD, MM dd, yy'); // French inp.datepicker('option', $.extend({autoSize: false}, $.datepicker.regional['fr'])); - equals(inp.attr('size'), 20, 'Auto size - fr - default'); + equals(inp.prop('size'), 29, 'Auto size - fr - default'); inp.datepicker('option', 'autoSize', true); - equals(inp.attr('size'), 10, 'Auto size - fr - dd/mm/yy'); + equals(inp.prop('size'), 10, 'Auto size - fr - dd/mm/yy'); inp.datepicker('option', 'dateFormat', 'm/d/yy'); - equals(inp.attr('size'), 10, 'Auto size - fr - m/d/yy'); + equals(inp.prop('size'), 10, 'Auto size - fr - m/d/yy'); inp.datepicker('option', 'dateFormat', 'D M d yy'); - equals(inp.attr('size'), 18, 'Auto size - fr - D M d yy'); + equals(inp.prop('size'), 18, 'Auto size - fr - D M d yy'); inp.datepicker('option', 'dateFormat', 'DD, MM dd, yy'); - equals(inp.attr('size'), 28, 'Auto size - fr - DD, MM dd, yy'); - inp.removeAttr('size'); + equals(inp.prop('size'), 28, 'Auto size - fr - DD, MM dd, yy'); // Hebrew inp.datepicker('option', $.extend({autoSize: false}, $.datepicker.regional['he'])); - equals(inp.attr('size'), 20, 'Auto size - he - default'); + equals(inp.prop('size'), 28, 'Auto size - he - default'); inp.datepicker('option', 'autoSize', true); - equals(inp.attr('size'), 10, 'Auto size - he - dd/mm/yy'); + equals(inp.prop('size'), 10, 'Auto size - he - dd/mm/yy'); inp.datepicker('option', 'dateFormat', 'm/d/yy'); - equals(inp.attr('size'), 10, 'Auto size - he - m/d/yy'); + equals(inp.prop('size'), 10, 'Auto size - he - m/d/yy'); inp.datepicker('option', 'dateFormat', 'D M d yy'); - equals(inp.attr('size'), 14, 'Auto size - he - D M d yy'); + equals(inp.prop('size'), 14, 'Auto size - he - D M d yy'); inp.datepicker('option', 'dateFormat', 'DD, MM dd, yy'); - equals(inp.attr('size'), 23, 'Auto size - he - DD, MM dd, yy'); - inp.removeAttr('size'); + equals(inp.prop('size'), 23, 'Auto size - he - DD, MM dd, yy'); }); test('daylightSaving', function() { @@ -702,7 +709,7 @@ test('callbacks', function() { ok(day21.is('.ui-datepicker-unselectable'), 'Before show day - unselectable 21'); ok(day20.is('.day10'), 'Before show day - CSS 20'); ok(!day21.is('.day10'), 'Before show day - CSS 21'); - ok(day20.attr('title') == '', 'Before show day - title 20'); + ok(!day20.attr('title'), 'Before show day - title 20'); ok(day21.attr('title') == 'Divisble by 3', 'Before show day - title 21'); inp.datepicker('hide').datepicker('destroy'); }); diff --git a/tests/unit/datepicker/datepicker_tickets.js b/tests/unit/datepicker/datepicker_tickets.js index d5249f905..10647eb13 100644 --- a/tests/unit/datepicker/datepicker_tickets.js +++ b/tests/unit/datepicker/datepicker_tickets.js @@ -30,12 +30,22 @@ test('Ticket 6827: formatDate day of year calculation is wrong during day lights }); test('Ticket #7244: date parser does not fail when too many numbers are passed into the date function', function() { - expect(1); + var date; try{ - var date = $.datepicker.parseDate('dd/mm/yy', '18/04/19881'); + date = $.datepicker.parseDate('dd/mm/yy', '18/04/19881'); + ok(false, "Did not properly detect an invalid date"); }catch(e){ ok("invalid date detected"); } + + try { + date = $.datepicker.parseDate('dd/mm/yy', '18/04/1988 @ 2:43 pm'); + equal(date.getDate(), 18); + equal(date.getMonth(), 3); + equal(date.getFullYear(), 1988); + } catch(e) { + ok(false, "Did not properly parse date with extra text separated by whitespace"); + } }); })(jQuery); diff --git a/tests/unit/dialog/dialog.html b/tests/unit/dialog/dialog.html index 7dc194058..fa78368ef 100644 --- a/tests/unit/dialog/dialog.html +++ b/tests/unit/dialog/dialog.html @@ -6,7 +6,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.dialog.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../external/jquery.bgiframe-2.1.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/unit/dialog/dialog_tickets.js b/tests/unit/dialog/dialog_tickets.js index def2452de..1cfdcefea 100644 --- a/tests/unit/dialog/dialog_tickets.js +++ b/tests/unit/dialog/dialog_tickets.js @@ -65,17 +65,15 @@ test("#6137: dialog('open') causes form elements to reset on IE7", function() { expect(2); d1 = $('<form><input type="radio" name="radio" id="a" value="a" checked="checked"></input>' + - '<input type="radio" name="radio" id="b" value="b">b</input></form>').dialog({autoOpen: false}); + '<input type="radio" name="radio" id="b" value="b">b</input></form>').appendTo( "body" ).dialog({autoOpen: false}); - d1.find('#b')[0].checked = true; + d1.find('#b').prop( "checked", true ); equal($('input:checked').val(), 'b', "checkbox b is checked"); - d2 = $('<div></div>').dialog({autoOpen: false}); - d1.dialog('open'); equal($('input:checked').val(), 'b', "checkbox b is checked"); - d1.add(d2).remove(); + d1.remove(); }); test("#6645: Missing element not found check in overlay", function(){ diff --git a/tests/unit/draggable/draggable.html b/tests/unit/draggable/draggable.html index ca5e77e78..1d949550f 100644 --- a/tests/unit/draggable/draggable.html +++ b/tests/unit/draggable/draggable.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Draggable Test Suite</title> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/unit/droppable/droppable.html b/tests/unit/droppable/droppable.html index ebe745836..3363cb45a 100644 --- a/tests/unit/droppable/droppable.html +++ b/tests/unit/droppable/droppable.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Droppable Test Suite</title> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/unit/effects/effects.html b/tests/unit/effects/effects.html index e3c6d2f4e..3199ba4a8 100644 --- a/tests/unit/effects/effects.html +++ b/tests/unit/effects/effects.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Core Test Suite</title> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script> $.uiBackCompat = false; </script> diff --git a/tests/unit/effects/effects_core.js b/tests/unit/effects/effects_core.js index 4c685ebb6..7c20e22fe 100644 --- a/tests/unit/effects/effects_core.js +++ b/tests/unit/effects/effects_core.js @@ -19,6 +19,18 @@ var minDuration = 15, module( "effects.core" ); +test( "Immediate Return Conditions", function() { + var hidden = $( "div.hidden" ), + count = 0; + expect( 3 ); + hidden.hide( "blind", function() { + equal( ++count, 1, "Hide on hidden returned immediately" ); + }).show().show( "blind", function() { + equal( ++count, 2, "Show on shown returned immediately" ); + }); + equal( ++count, 3, "Both Functions worked properly" ); +}); + $.each( $.effects.effect, function( effect ) { if ( effect === "transfer" ) { return; @@ -123,4 +135,19 @@ asyncTest( "animateClass works with children", function() { }}); }); +asyncTest( "animateClass clears style properties when stopped", function() { + var test = $("div.animateClass"), + style = test[0].style, + orig = style.cssText; + + expect( 2 ); + + test.addClass( "testChangeBackground", duration ); + notEqual( orig, style.cssText, "cssText is the not the same after starting animation" ); + + test.stop( true, true ); + equal( orig, style.cssText, "cssText is the same after stopping animation midway" ); + start(); +}); + })(jQuery); diff --git a/tests/unit/menu/menu.html b/tests/unit/menu/menu.html index c917f5c4b..49e33e7b1 100644 --- a/tests/unit/menu/menu.html +++ b/tests/unit/menu/menu.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.menu.js"></script> @@ -31,7 +31,7 @@ $("#log").data("lastItem",item); $('li:eq(' + item + ') a',menu).trigger("click"); } - + </script> <script type="text/javascript" src="menu_core.js"></script> @@ -41,10 +41,12 @@ <script type="text/javascript" src="menu_options.js"></script> <script type="text/javascript" src="../swarminject.js"></script> - + <style> #qunit-fixture { font-size: 10pt; font-family: 'trebuchet ms', verdana, arial; } #list, #list1 *, #navigation, #navigation * { margin: 0; padding: 0; font-size: 12px; } + #menu3 { height: 250px; overflow: auto; } + #menu4, #menu4 ul { height: 250px; overflow: auto; } </style> </head> <body> @@ -66,6 +68,159 @@ <li class="foo"><a class="foo" href="#">Addyston</a></li> <li class="foo"><a class="foo" href="#">Adelphi</a></li> </ul> + +<ul id="menu2"> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li> + <a href="#">Delphi</a> + <ul> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Saarland</a></li> + <li class="foo"><a class="foo" href="#">Salzburg</a></li> + </ul> + </li> + <li class="foo"><a class="foo" href="#">Saarland</a></li> + <li> + <a href="#">Salzburg</a> + <ul> + <li> + <a href="#">Delphi</a> + <ul> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Saarland</a></li> + <li class="foo"><a class="foo" href="#">Salzburg</a></li> + </ul> + </li> + <li> + <a href="#">Delphi</a> + <ul> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Saarland</a></li> + <li class="foo"><a class="foo" href="#">Salzburg</a></li> + </ul> + </li> + <li class="foo"><a class="foo" href="#">Perch</a></li> + </ul> + </li> +</ul> + +<ul class="foo" id="menu3"> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li class="foo"><a class="foo" href="#">Adelphi</a></li> + <li class="foo"><a class="foo" href="#">Adena</a></li> + <li class="foo"><a class="foo" href="#">Adrian</a></li> + <li class="foo"><a class="foo" href="#">Akron</a></li> + <li class="foo"><a class="foo" href="#">Albany</a></li> + <li class="foo"><a class="foo" href="#">Alexandria</a></li> + <li class="foo"><a class="foo" href="#">Alger</a></li> + <li class="foo"><a class="foo" href="#">Alledonia</a></li> + <li class="foo"><a class="foo" href="#">Alliance</a></li> + <li class="foo"><a class="foo" href="#">Alpha</a></li> + <li class="foo"><a class="foo" href="#">Alvada</a></li> + <li class="foo"><a class="foo" href="#">Alvordton</a></li> + <li class="foo"><a class="foo" href="#">Amanda</a></li> + <li class="foo"><a class="foo" href="#">Amelia</a></li> + <li class="foo"><a class="foo" href="#">Amesville</a></li> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li class="foo"><a class="foo" href="#">Adelphi</a></li> + <li class="foo"><a class="foo" href="#">Adena</a></li> + <li class="foo"><a class="foo" href="#">Adrian</a></li> + <li class="foo"><a class="foo" href="#">Akron</a></li> + <li class="foo"><a class="foo" href="#">Albany</a></li> + <li class="foo"><a class="foo" href="#">Alexandria</a></li> + <li class="foo"><a class="foo" href="#">Alger</a></li> + <li class="foo"><a class="foo" href="#">Alledonia</a></li> + <li class="foo"><a class="foo" href="#">Alliance</a></li> + <li class="foo"><a class="foo" href="#">Alpha</a></li> + <li class="foo"><a class="foo" href="#">Alvada</a></li> + <li class="foo"><a class="foo" href="#">Alvordton</a></li> + <li class="foo"><a class="foo" href="#">Amanda</a></li> + <li class="foo"><a class="foo" href="#">Amelia</a></li> + <li class="foo"><a class="foo" href="#">Amesville</a></li> +</ul> + +<ul class="foo" id="menu4"> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"> + <a class="foo" href="#">Ada</a> + <ul class="foo"> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li class="foo"><a class="foo" href="#">Adelphi</a></li> + <li class="foo"><a class="foo" href="#">Adena</a></li> + <li class="foo"><a class="foo" href="#">Adrian</a></li> + <li class="foo"><a class="foo" href="#">Akron</a></li> + <li class="foo"><a class="foo" href="#">Albany</a></li> + <li class="foo"><a class="foo" href="#">Alexandria</a></li> + <li class="foo"><a class="foo" href="#">Alger</a></li> + <li class="foo"><a class="foo" href="#">Alledonia</a></li> + <li class="foo"><a class="foo" href="#">Alliance</a></li> + <li class="foo"><a class="foo" href="#">Alpha</a></li> + <li class="foo"><a class="foo" href="#">Alvada</a></li> + <li class="foo"><a class="foo" href="#">Alvordton</a></li> + <li class="foo"><a class="foo" href="#">Amanda</a></li> + <li class="foo"><a class="foo" href="#">Amelia</a></li> + <li class="foo"><a class="foo" href="#">Amesville</a></li> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li class="foo"><a class="foo" href="#">Adelphi</a></li> + <li class="foo"><a class="foo" href="#">Adena</a></li> + <li class="foo"><a class="foo" href="#">Adrian</a></li> + <li class="foo"><a class="foo" href="#">Akron</a></li> + <li class="foo"><a class="foo" href="#">Albany</a></li> + </ul> + </li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li class="foo"><a class="foo" href="#">Adelphi</a></li> + <li class="foo"><a class="foo" href="#">Adena</a></li> + <li class="foo"><a class="foo" href="#">Adrian</a></li> + <li class="foo"><a class="foo" href="#">Akron</a></li> + <li class="foo"><a class="foo" href="#">Albany</a></li> + <li class="foo"><a class="foo" href="#">Alexandria</a></li> + <li class="foo"><a class="foo" href="#">Alger</a></li> + <li class="foo"><a class="foo" href="#">Alledonia</a></li> + <li class="foo"><a class="foo" href="#">Alliance</a></li> + <li class="foo"><a class="foo" href="#">Alpha</a></li> + <li class="foo"><a class="foo" href="#">Alvada</a></li> + <li class="foo"><a class="foo" href="#">Alvordton</a></li> + <li class="foo"><a class="foo" href="#">Amanda</a></li> + <li class="foo"><a class="foo" href="#">Amelia</a></li> + <li class="foo"><a class="foo" href="#">Amesville</a></li> + <li class="foo"><a class="foo" href="#">Aberdeen</a></li> + <li class="foo"><a class="foo" href="#">Ada</a></li> + <li class="foo"><a class="foo" href="#">Adamsville</a></li> + <li class="foo"><a class="foo" href="#">Addyston</a></li> + <li class="foo"><a class="foo" href="#">Adelphi</a></li> + <li class="foo"><a class="foo" href="#">Adena</a></li> + <li class="foo"><a class="foo" href="#">Adrian</a></li> + <li class="foo"><a class="foo" href="#">Akron</a></li> + <li class="foo"><a class="foo" href="#">Albany</a></li> + <li class="foo"><a class="foo" href="#">Alexandria</a></li> + <li class="foo"><a class="foo" href="#">Alger</a></li> + <li class="foo"><a class="foo" href="#">Alledonia</a></li> + <li class="foo"><a class="foo" href="#">Alliance</a></li> + <li class="foo"><a class="foo" href="#">Alpha</a></li> + <li class="foo"><a class="foo" href="#">Alvada</a></li> + <li class="foo"><a class="foo" href="#">Alvordton</a></li> + <li class="foo"><a class="foo" href="#">Amanda</a></li> + <li class="foo"><a class="foo" href="#">Amelia</a></li> + <li class="foo"><a class="foo" href="#">Amesville</a></li> +</ul> + <div id="log"></div> </div> diff --git a/tests/unit/menu/menu_events.js b/tests/unit/menu/menu_events.js index a03bec3f6..19ac11c68 100644 --- a/tests/unit/menu/menu_events.js +++ b/tests/unit/menu/menu_events.js @@ -21,4 +21,329 @@ test("handle click on menu", function() { equals( $("#log").html(), "1,3,2,afterclick,1,click,", "Click order not valid."); }); +test( "handle blur: click", function() { + expect( 4 ); + var $menu = $( "#menu1" ).menu({ + focus: function( event, ui ) { + equal( event.originalEvent.type, "click", "focus triggered 'click'" ); + equal( event.type, "menufocus", "focus event.type is 'menufocus'" ); + + }, + blur: function( event, ui ) { + equal( event.originalEvent.type, "click", "blur triggered 'click'" ); + equal( event.type, "menublur", "blur event.type is 'menublur'" ); + } + }); + + $menu.find( "li a:first" ).trigger( "click" ); + $( "<a/>", { id: "remove"} ).appendTo("body").trigger( "click" ); + + $("#remove").remove(); +}); + +test("handle keyboard navigation on menu without scroll and without submenus", function() { + expect(12); + var element = $('#menu1').menu({ + select: function(event, ui) { + log($(ui.item[0]).text()); + }, + focus: function( event, ui ) { + log($(event.target).find(".ui-state-focus").parent().index()); + } + }); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + equals( $("#log").html(), "1,0,keydown,", "Keydown DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.LEFT } ); + equals( $("#log").html(), "keydown,", "Keydown LEFT (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.RIGHT } ); + equals( $("#log").html(), "keydown,", "Keydown RIGHT (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "4,keydown,", "Keydown PAGE_DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "keydown,", "Keydown PAGE_DOWN (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown PAGE_UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "keydown,", "Keydown PAGE_UP (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.END } ); + equals( $("#log").html(), "4,keydown,", "Keydown END"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.HOME } ); + equals( $("#log").html(), "0,keydown,", "Keydown HOME"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ESCAPE } ); + equals( $("#log").html(), "keydown,", "Keydown ESCAPE (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ENTER } ); + equals( $("#log").html(), "Aberdeen,keydown,", "Keydown ENTER"); +}); + +asyncTest("handle keyboard navigation on menu without scroll and with submenus", function() { + expect(14); + var element = $('#menu2').menu({ + select: function(event, ui) { + log($(ui.item[0]).text()); + }, + focus: function( event, ui ) { + log($(event.target).find(".ui-state-focus").parent().index()); + } + }); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + equals( $("#log").html(), "1,0,keydown,", "Keydown DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.LEFT } ); + equals( $("#log").html(), "keydown,", "Keydown LEFT (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.RIGHT } ); + + setTimeout( function() { + equals( $("#log").html(), "0,4,3,2,1,keydown,", "Keydown RIGHT (open submenu)"); + }, 50); + + setTimeout( function() { + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.LEFT } ); + equals( $("#log").html(), "4,keydown,", "Keydown LEFT (close submenu)"); + + //re-open submenu + element.simulate( "keydown", { keyCode: $.ui.keyCode.RIGHT } ); + + setTimeout( function() { + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "2,keydown,", "Keydown PAGE_DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "keydown,", "Keydown PAGE_DOWN (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown PAGE_UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "keydown,", "Keydown PAGE_UP (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.END } ); + equals( $("#log").html(), "2,keydown,", "Keydown END"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.HOME } ); + equals( $("#log").html(), "0,keydown,", "Keydown HOME"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ESCAPE } ); + equals( $("#log").html(), "4,keydown,", "Keydown ESCAPE (close submenu)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ENTER } ); + + setTimeout( function() { + equals( $("#log").html(), "0,keydown,", "Keydown ENTER (open submenu)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ENTER } ); + equals( $("#log").html(), "Ada,keydown,", "Keydown ENTER (select item)"); + + start(); + }, 200); + }, 150); + }, 100); + +}); + +test("handle keyboard navigation on menu with scroll and without submenus", function() { + expect(14); + var element = $('#menu3').menu({ + select: function(event, ui) { + log($(ui.item[0]).text()); + }, + focus: function( event, ui ) { + log($(event.target).find(".ui-state-focus").parent().index()); + } + }); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + equals( $("#log").html(), "1,0,keydown,", "Keydown DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.LEFT } ); + equals( $("#log").html(), "keydown,", "Keydown LEFT (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.RIGHT } ); + equals( $("#log").html(), "keydown,", "Keydown RIGHT (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "10,keydown,", "Keydown PAGE_DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "20,keydown,", "Keydown PAGE_DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "10,keydown,", "Keydown PAGE_UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown PAGE_UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "keydown,", "Keydown PAGE_UP (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.END } ); + equals( $("#log").html(), "37,keydown,", "Keydown END"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "keydown,", "Keydown PAGE_DOWN (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.HOME } ); + equals( $("#log").html(), "0,keydown,", "Keydown HOME"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ESCAPE } ); + equals( $("#log").html(), "keydown,", "Keydown ESCAPE (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ENTER } ); + equals( $("#log").html(), "Aberdeen,keydown,", "Keydown ENTER"); +}); + +asyncTest("handle keyboard navigation on menu with scroll and with submenus", function() { + expect(14); + var element = $('#menu4').menu({ + select: function(event, ui) { + log($(ui.item[0]).text()); + }, + focus: function( event, ui ) { + log($(event.target).find(".ui-state-focus").parent().index()); + } + }); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + equals( $("#log").html(), "1,0,keydown,", "Keydown DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.LEFT } ); + equals( $("#log").html(), "keydown,", "Keydown LEFT (no effect)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.DOWN } ); + element.simulate( "keydown", { keyCode: $.ui.keyCode.RIGHT } ); + + setTimeout( function() { + equals( $("#log").html(), "0,1,keydown,", "Keydown RIGHT (open submenu)"); + }, 50); + + setTimeout( function() { + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.LEFT } ); + equals( $("#log").html(), "1,keydown,", "Keydown LEFT (close submenu)"); + + //re-open submenu + element.simulate( "keydown", { keyCode: $.ui.keyCode.RIGHT } ); + + setTimeout( function() { + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "10,keydown,", "Keydown PAGE_DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); + equals( $("#log").html(), "20,keydown,", "Keydown PAGE_DOWN"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "10,keydown,", "Keydown PAGE_UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); + equals( $("#log").html(), "0,keydown,", "Keydown PAGE_UP"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.END } ); + equals( $("#log").html(), "27,keydown,", "Keydown END"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.HOME } ); + equals( $("#log").html(), "0,keydown,", "Keydown HOME"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ESCAPE } ); + equals( $("#log").html(), "1,keydown,", "Keydown ESCAPE (close submenu)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ENTER } ); + + setTimeout( function() { + equals( $("#log").html(), "0,keydown,", "Keydown ENTER (open submenu)"); + + log("keydown",true); + element.simulate( "keydown", { keyCode: $.ui.keyCode.ENTER } ); + equals( $("#log").html(), "Aberdeen,keydown,", "Keydown ENTER (select item)"); + + start(); + }, 200); + }, 150); + }, 100); + +}); + })(jQuery); diff --git a/tests/unit/position/position.html b/tests/unit/position/position.html index d71bae497..fe8a21f06 100644 --- a/tests/unit/position/position.html +++ b/tests/unit/position/position.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Position Test Suite</title> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script> $.uiBackCompat = false; </script> diff --git a/tests/unit/position/position_core.js b/tests/unit/position/position_core.js index bd8e58612..fd6e643e9 100644 --- a/tests/unit/position/position_core.js +++ b/tests/unit/position/position_core.js @@ -435,6 +435,87 @@ test( "collision: flip, with margin", function() { }, { top: 0, left: 0 }, "right bottom" ); }); +test( "addClass: flipped left", function() { + var elem = $( "#elx" ).position( { + my: "left center", + of: window, + collision: "flip", + at: "right center" + }); + + same( elem.hasClass( 'ui-flipped-left' ), true, 'Has ui-flipped-left class' ); + + elem.position( { + my: "right center", + of: window, + collision: "flip", + at: "left center" + }) + + same( elem.hasClass( 'ui-flipped-left' ), false, 'Removed ui-flipped-left class' ); +}); + +test( "addClass: flipped top", function() { + var elem = $( "#elx" ).position( { + my: "left top", + of: window, + collision: "flip", + at: "right bottom" + }); + + same( elem.hasClass( 'ui-flipped-top' ), true, 'Has ui-flipped-top class' ); + + elem.position( { + my: "left bottom", + of: window, + collision: "flip", + at: "right top" + }); + + same( elem.hasClass( 'ui-flipped-top' ), false, 'Removed ui-flipped-top class' ); +}); + +test( "addClass: flipped right", function() { + var elem = $( "#elx" ).position( { + my: "right center", + of: window, + collision: "flip", + at: "left center" + }); + + same( elem.hasClass( 'ui-flipped-right' ), true, 'Has ui-flipped-right class' ); + + elem.position( { + my: "left center", + of: window, + collision: "flip", + at: "right center" + }); + + same( elem.hasClass( 'ui-flipped-right' ), false, 'Removed ui-flipped-right class' ); + +}); + +test( "addClass: flipped bottom", function() { + var elem = $( "#elx" ).position( { + my: "left bottom", + of: window, + collision: "flip", + at: "right top" + }); + + same( elem.hasClass( 'ui-flipped-bottom' ), true, 'Has ui-flipped-bottom class' ); + + elem.position( { + my: "left top", + of: window, + collision: "flip", + at: "right bottom" + }); + + same( elem.hasClass( 'ui-flipped-bottom' ), false, 'Removed ui-flipped-bottom class' ); +}); + //test( "bug #5280: consistent results (avoid fractional values)", function() { // var wrapper = $( "#bug-5280" ), // elem = wrapper.children(), diff --git a/tests/unit/position/position_core_within.js b/tests/unit/position/position_core_within.js index 567c17192..bfb913335 100644 --- a/tests/unit/position/position_core_within.js +++ b/tests/unit/position/position_core_within.js @@ -438,4 +438,99 @@ test( "collision: flip, with margin", function() { }, { top: addTop + 0, left: addLeft + 0 }, "right bottom" ); }); +test( "addClass: flipped left", function() { + var within = $("#within-container"); + + var elem = $( "#elx" ).position( { + my: "left center", + of: within[0], + within: within, + collision: "flip", + at: "right center" + }); + + same( elem.hasClass( 'ui-flipped-left' ), true, 'Has ui-flipped-left class' ); + + elem.position( { + my: "right center", + of: within[0], + within: within, + collision: "flip", + at: "left center" + }) + + same( elem.hasClass( 'ui-flipped-left' ), false, 'Removed ui-flipped-left class' ); +}); + +test( "addClass: flipped top", function() { + var within = $("#within-container"); + + var elem = $( "#elx" ).position( { + my: "left top", + of: within[0], + within: within, + collision: "flip", + at: "right bottom" + }); + + same( elem.hasClass( 'ui-flipped-top' ), true, 'Has ui-flipped-top class' ); + + elem.position( { + my: "left bottom", + of: within[0], + within: within, + collision: "flip", + at: "right top" + }); + + same( elem.hasClass( 'ui-flipped-top' ), false, 'Removed ui-flipped-top class' ); +}); + +test( "addClass: flipped right", function() { + var within = $("#within-container"); + + var elem = $( "#elx" ).position( { + my: "right center", + of: within[0], + within: within, + collision: "flip", + at: "left center" + }); + + same( elem.hasClass( 'ui-flipped-right' ), true, 'Has ui-flipped-right class' ); + + elem.position( { + my: "left center", + of: within[0], + within: within, + collision: "flip", + at: "right center" + }); + + same( elem.hasClass( 'ui-flipped-right' ), false, 'Removed ui-flipped-right class' ); + +}); + +test( "addClass: flipped bottom", function() { + var within = $("#within-container"); + + var elem = $( "#elx" ).position( { + my: "left bottom", + of: window, + collision: "flip", + at: "right top" + }); + + same( elem.hasClass( 'ui-flipped-bottom' ), true, 'Has ui-flipped-bottom class' ); + + elem.position( { + my: "left top", + of: window, + collision: "flip", + at: "right bottom" + }); + + same( elem.hasClass( 'ui-flipped-bottom' ), false, 'Removed ui-flipped-bottom class' ); +}); + }( jQuery ) ); diff --git a/tests/unit/position/position_deprecated.html b/tests/unit/position/position_deprecated.html index 156235d7b..e7af7cc46 100644 --- a/tests/unit/position/position_deprecated.html +++ b/tests/unit/position/position_deprecated.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Position Test Suite</title> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.ui.position.js"></script> <link rel="stylesheet" href="../../../external/qunit.css"> diff --git a/tests/unit/progressbar/progressbar.html b/tests/unit/progressbar/progressbar.html index 8048203f8..0e812877a 100644 --- a/tests/unit/progressbar/progressbar.html +++ b/tests/unit/progressbar/progressbar.html @@ -6,7 +6,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.progressbar.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.progressbar.js"></script> diff --git a/tests/unit/progressbar/progressbar_core.js b/tests/unit/progressbar/progressbar_core.js index e59579634..a499d858c 100644 --- a/tests/unit/progressbar/progressbar_core.js +++ b/tests/unit/progressbar/progressbar_core.js @@ -22,7 +22,7 @@ test("accessibility", function() { equals(el.attr("aria-disabled"), "true", "aria-disabled on"); el.progressbar("enable"); // FAIL: for some reason IE6 and 7 return a boolean false instead of the string - equals(el.attr("aria-disabled"), $.browser.msie && $.browser.version == 6 || $.browser.version == 7 ? false : "false", "aria-disabled off"); + equals(el.attr("aria-disabled"), "false", "aria-disabled off"); }); })(jQuery); diff --git a/tests/unit/resizable/resizable.html b/tests/unit/resizable/resizable.html index cb88c6751..bb013cf9f 100644 --- a/tests/unit/resizable/resizable.html +++ b/tests/unit/resizable/resizable.html @@ -6,7 +6,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.resizable.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/unit/selectable/selectable.html b/tests/unit/selectable/selectable.html index 85e843cda..a32e574a5 100644 --- a/tests/unit/selectable/selectable.html +++ b/tests/unit/selectable/selectable.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Selectable Test Suite</title> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/unit/slider/slider.html b/tests/unit/slider/slider.html index 6dc84660b..6f52b9024 100644 --- a/tests/unit/slider/slider.html +++ b/tests/unit/slider/slider.html @@ -6,7 +6,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.slider.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/unit/slider/slider_options.js b/tests/unit/slider/slider_options.js index b9a766539..f0abac665 100644 --- a/tests/unit/slider/slider_options.js +++ b/tests/unit/slider/slider_options.js @@ -96,7 +96,7 @@ test("step", function() { min: 0, value: 0, step: 10, - max: 100, + max: 100 }); equals( el.slider("value"), 0 ); @@ -116,7 +116,7 @@ el = $('<div></div>').slider({ min: 0, value: 0, step: 20, - max: 100, + max: 100 }); el.slider("value", 0); diff --git a/tests/unit/sortable/sortable.html b/tests/unit/sortable/sortable.html index 2a55cf363..34b834e05 100644 --- a/tests/unit/sortable/sortable.html +++ b/tests/unit/sortable/sortable.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>jQuery UI Sortable Test Suite</title> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/unit/spinner/spinner.html b/tests/unit/spinner/spinner.html index 1c055afd7..ded4d081d 100644 --- a/tests/unit/spinner/spinner.html +++ b/tests/unit/spinner/spinner.html @@ -5,7 +5,7 @@ <link type="text/css" href="../../../themes/base/jquery.ui.spinner.css" rel="stylesheet" />
- <script type="text/javascript" src="../../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../../external/jquery.global.js"></script>
<script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script>
diff --git a/tests/unit/tabs/tabs.html b/tests/unit/tabs/tabs.html index 60f5e972e..38dad7460 100644 --- a/tests/unit/tabs/tabs.html +++ b/tests/unit/tabs/tabs.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.tabs.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script> $.uiBackCompat = false; </script> diff --git a/tests/unit/tabs/tabs_deprecated.html b/tests/unit/tabs/tabs_deprecated.html index ed6518be3..f1b7f763f 100644 --- a/tests/unit/tabs/tabs_deprecated.html +++ b/tests/unit/tabs/tabs_deprecated.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.tabs.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../external/jquery.cookie.js"></script> <script src="../../../ui/jquery.ui.core.js"></script> <script src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/unit/testsuite.js b/tests/unit/testsuite.js index 3d9e64d60..c8afcbe79 100644 --- a/tests/unit/testsuite.js +++ b/tests/unit/testsuite.js @@ -82,7 +82,7 @@ window.domEqual = function( selector, modifier, message ) { var result = {}; result.nodeName = value[0].nodeName; $.each(attributes, function(index, attr) { - result[attr] = value.attr(attr); + result[attr] = value.prop(attr); }); result.children = []; var children = value.children(); diff --git a/tests/unit/testsuites.js b/tests/unit/testsuites.js new file mode 100644 index 000000000..ffe2d3cc0 --- /dev/null +++ b/tests/unit/testsuites.js @@ -0,0 +1,76 @@ +(function( $, QUnit ) { + +$.extend( QUnit, { + testSuites: function( suites ) { + $.each( suites, function( i, suite ) { + asyncTest( suite, function() { + runSuite( suite ); + }); + }); + }, + + testStart: function( data ) { + // update the test status to show which test suite is running + $( "#qunit-testresult" ).html( "Running " + data.name + "...<br> " ); + }, + + testDone: function() { + // undo the auto-expansion of failed tests + $( "#qunit-tests > li.fail" ).each(function() { + var test = $( this ); + // avoid collapsing test results that the user manually opened + if ( test.data( "auto-collapsed" ) ) { + return; + } + test.data( "auto-collapsed", true ) + .children( "ol" ).hide(); + }); + } +}); + +// generate an iframe to run the test suite and proxy the iframe's QUnit +// to pass all test info to the main page +function runSuite( suite ) { + var body = $( "body" ), + iframe = $( "<iframe>", { src: suite } ) + .css({ + width: 1000, + height: 1000 + }) + .appendTo( body ) + [0], + iframeWin = iframe.contentWindow; + + $( iframeWin ).bind( "load", function() { + var module, test, + count = 0; + + $.extend( iframeWin.QUnit, { + moduleStart: function( data ) { + // capture module name for messages + module = data.name; + }, + + testStart: function( data ) { + // capture test name for messages + test = data.name; + }, + + log: function( data ) { + // pass all test details through to the main page + var message = module + ": " + test + ": " + data.message; + expect( ++count ); + QUnit.push( data.result, data.actual, data.expected, message ); + }, + + done: function() { + // hide the iframe from the main page once the tests are done + // and start the wrapper test from the main page + $( iframe ).hide(); + start(); + } + }); + }); +} + +}( jQuery, QUnit ) ); diff --git a/tests/unit/tooltip/tooltip.html b/tests/unit/tooltip/tooltip.html index 21eff51fd..10bd0f22e 100644 --- a/tests/unit/tooltip/tooltip.html +++ b/tests/unit/tooltip/tooltip.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../themes/base/jquery.ui.tooltip.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.ui.core.js"></script> <script src="../../../ui/jquery.ui.widget.js"></script> <script src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/unit/tooltip/tooltip_methods.js b/tests/unit/tooltip/tooltip_methods.js index 798d55896..74fd35d84 100644 --- a/tests/unit/tooltip/tooltip_methods.js +++ b/tests/unit/tooltip/tooltip_methods.js @@ -40,7 +40,7 @@ test( "enable/disable", function() { element.tooltip( "disable" ); equal( $( ".ui-tooltip" ).length, 0, "no tooltip when disabled" ); - equal( tooltip.attr( "title" ), "", "title removed on disable" ); + equal( tooltip.attr( "title" ), undefined, "title removed on disable" ); element.tooltip( "open" ); equal( $( ".ui-tooltip" ).length, 0, "open does nothing when disabled" ); diff --git a/tests/unit/widget/widget.html b/tests/unit/widget/widget.html index b06aa19f8..bd673978c 100644 --- a/tests/unit/widget/widget.html +++ b/tests/unit/widget/widget.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Widget Test Suite</title> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.ui.core.js"></script> <script src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/visual/addClass/addClass_queue.html b/tests/visual/addClass/addClass_queue.html index 213a2fde4..d7ac334a0 100644 --- a/tests/visual/addClass/addClass_queue.html +++ b/tests/visual/addClass/addClass_queue.html @@ -5,7 +5,7 @@ <title>addClass Visual Test : Queue</title> <link rel="stylesheet" href="../visual.css"> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.effects.core.js"></script> <style> .box { diff --git a/tests/visual/all.html b/tests/visual/all.html index 265d4e35b..4f922e46a 100644 --- a/tests/visual/all.html +++ b/tests/visual/all.html @@ -5,7 +5,7 @@ <title>Simple All</title> <link rel="stylesheet" href="all.css" type="text/css"> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/animate/animate_backgroundColor_hex.html b/tests/visual/animate/animate_backgroundColor_hex.html index c7d8280eb..e3431abae 100644 --- a/tests/visual/animate/animate_backgroundColor_hex.html +++ b/tests/visual/animate/animate_backgroundColor_hex.html @@ -5,7 +5,7 @@ <title>Animate Visual Test : Animate backgroundColor hex</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.effects.core.js"></script> <script type="text/javascript"> function hexFromRGB (r, g, b) { diff --git a/tests/visual/animate/animate_backgroundColor_rgb.html b/tests/visual/animate/animate_backgroundColor_rgb.html index 583c10481..762621bb5 100644 --- a/tests/visual/animate/animate_backgroundColor_rgb.html +++ b/tests/visual/animate/animate_backgroundColor_rgb.html @@ -5,7 +5,7 @@ <title>Animate Visual Test : Animate backgroundColor rgb</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.effects.core.js"></script> <script type="text/javascript"> function randomColorRGB() { diff --git a/tests/visual/animate/animate_color_hex.html b/tests/visual/animate/animate_color_hex.html index 698db2b9e..fb9349111 100644 --- a/tests/visual/animate/animate_color_hex.html +++ b/tests/visual/animate/animate_color_hex.html @@ -5,7 +5,7 @@ <title>Animate Visual Test : Animate color hex</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.effects.core.js"></script> <script type="text/javascript"> function hexFromRGB (r, g, b) { diff --git a/tests/visual/animate/animate_color_rgb.html b/tests/visual/animate/animate_color_rgb.html index ebb868aa3..702b2282f 100644 --- a/tests/visual/animate/animate_color_rgb.html +++ b/tests/visual/animate/animate_color_rgb.html @@ -5,7 +5,7 @@ <title>Animate Visual Test : Animate color rgb</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.effects.core.js"></script> <script type="text/javascript"> function randomColorRGB() { diff --git a/tests/visual/button/button.html b/tests/visual/button/button.html index ab4b58b04..25383c07f 100644 --- a/tests/visual/button/button.html +++ b/tests/visual/button/button.html @@ -9,7 +9,7 @@ #toolbar { margin-top: 2em; padding:0.2em; } #ops1, #ops2, #format, #mode { margin-right: 1em } </style> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../external/jquery.metadata.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/visual/button/button_disabled_true.html b/tests/visual/button/button_disabled_true.html index c1832fcb2..d6e78f529 100644 --- a/tests/visual/button/button_disabled_true.html +++ b/tests/visual/button/button_disabled_true.html @@ -5,7 +5,7 @@ <title>Button Visual Test : Button disabled true</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/visual/button/button_input_type_checkbox.html b/tests/visual/button/button_input_type_checkbox.html index 5596736ff..b9f16b5fd 100644 --- a/tests/visual/button/button_input_type_checkbox.html +++ b/tests/visual/button/button_input_type_checkbox.html @@ -5,7 +5,7 @@ <title>Button Visual Test : Button input type checkbox</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/visual/button/button_option_disabled_true.html b/tests/visual/button/button_option_disabled_true.html index c1832fcb2..d6e78f529 100644 --- a/tests/visual/button/button_option_disabled_true.html +++ b/tests/visual/button/button_option_disabled_true.html @@ -5,7 +5,7 @@ <title>Button Visual Test : Button disabled true</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/visual/button/button_performance.html b/tests/visual/button/button_performance.html index 4d675bb6d..367f1db0e 100644 --- a/tests/visual/button/button_performance.html +++ b/tests/visual/button/button_performance.html @@ -9,7 +9,7 @@ #toolbar { margin-top: 2em; padding:0.2em; } #ops1, #ops2, #format, #mode { margin-right: 1em } </style> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../external/jquery.metadata.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/visual/button/button_ticket_5254.html b/tests/visual/button/button_ticket_5254.html index 9031861e9..7c652768c 100644 --- a/tests/visual/button/button_ticket_5254.html +++ b/tests/visual/button/button_ticket_5254.html @@ -5,7 +5,7 @@ <title>Button Visual Test : Button ticket #5254</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/visual/button/button_ticket_5261.html b/tests/visual/button/button_ticket_5261.html index 494912b1f..cec2f1af4 100644 --- a/tests/visual/button/button_ticket_5261.html +++ b/tests/visual/button/button_ticket_5261.html @@ -5,7 +5,7 @@ <title>Button Visual Test : Button ticket #5261</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/visual/button/button_ticket_5278.html b/tests/visual/button/button_ticket_5278.html index a519cc38e..dae2bf5f0 100644 --- a/tests/visual/button/button_ticket_5278.html +++ b/tests/visual/button/button_ticket_5278.html @@ -5,7 +5,7 @@ <title>Button Visual Test : Button ticket #5278</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.button.js"></script> diff --git a/tests/visual/compound/accordion_dialog.html b/tests/visual/compound/accordion_dialog.html index cf0f25c6d..f7c394a52 100644 --- a/tests/visual/compound/accordion_dialog.html +++ b/tests/visual/compound/accordion_dialog.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Accordion in Dialog</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/compound/accordion_tabs.html b/tests/visual/compound/accordion_tabs.html index 76a960fc3..09a9200fb 100644 --- a/tests/visual/compound/accordion_tabs.html +++ b/tests/visual/compound/accordion_tabs.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Accordion in Tabs</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.accordion.js"></script> diff --git a/tests/visual/compound/datepicker_dialog.html b/tests/visual/compound/datepicker_dialog.html index 26a07a248..0737ecbeb 100644 --- a/tests/visual/compound/datepicker_dialog.html +++ b/tests/visual/compound/datepicker_dialog.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Datepicker in Dialog</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/compound/draggable_accordion.html b/tests/visual/compound/draggable_accordion.html index 8bb74d4af..e95694a52 100644 --- a/tests/visual/compound/draggable_accordion.html +++ b/tests/visual/compound/draggable_accordion.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Draggable in Accordion</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/compound/draggable_accordion_accordion_tabs_draggable.html b/tests/visual/compound/draggable_accordion_accordion_tabs_draggable.html index 2753988f1..bbd60b11c 100644 --- a/tests/visual/compound/draggable_accordion_accordion_tabs_draggable.html +++ b/tests/visual/compound/draggable_accordion_accordion_tabs_draggable.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Draggable in Accordion</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/compound/sortable_accordion_sortable_tabs.html b/tests/visual/compound/sortable_accordion_sortable_tabs.html index 73fc5ab6c..c4adae8cc 100644 --- a/tests/visual/compound/sortable_accordion_sortable_tabs.html +++ b/tests/visual/compound/sortable_accordion_sortable_tabs.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Accordion in Tabs</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/compound/tabs_tabs.html b/tests/visual/compound/tabs_tabs.html index f8a8cb636..9f2655cbf 100644 --- a/tests/visual/compound/tabs_tabs.html +++ b/tests/visual/compound/tabs_tabs.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Tabs in Tabs</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.accordion.js"></script> diff --git a/tests/visual/compound/tabs_tooltips.html b/tests/visual/compound/tabs_tooltips.html index 013ba724b..fe5d224da 100644 --- a/tests/visual/compound/tabs_tooltips.html +++ b/tests/visual/compound/tabs_tooltips.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : Tabs in Tabs</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/compound/widgets_in_dialog.html b/tests/visual/compound/widgets_in_dialog.html index 13680f9bc..11a2505ae 100644 --- a/tests/visual/compound/widgets_in_dialog.html +++ b/tests/visual/compound/widgets_in_dialog.html @@ -5,7 +5,7 @@ <title>Compound Visual Test : All Widgets in Dialog</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/datepicker/datepicker.html b/tests/visual/datepicker/datepicker.html index 274eba22a..bc0ea52a1 100644 --- a/tests/visual/datepicker/datepicker.html +++ b/tests/visual/datepicker/datepicker.html @@ -5,7 +5,7 @@ <title>Datepicker Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/datepicker/datepicker_multi_inline.html b/tests/visual/datepicker/datepicker_multi_inline.html index 64969ec6b..74577d452 100644 --- a/tests/visual/datepicker/datepicker_multi_inline.html +++ b/tests/visual/datepicker/datepicker_multi_inline.html @@ -5,7 +5,7 @@ <title>Simple Datepicker</title> <link rel="stylesheet" href="../all.css" type="text/css"> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/datepicker/datepicker_ticket_4071.html b/tests/visual/datepicker/datepicker_ticket_4071.html index 628234aa7..25ff6e8d4 100644 --- a/tests/visual/datepicker/datepicker_ticket_4071.html +++ b/tests/visual/datepicker/datepicker_ticket_4071.html @@ -5,7 +5,7 @@ <title>Datepicker Visual Test : Datepicker ticket #4071</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/datepicker/datepicker_ticket_4240.html b/tests/visual/datepicker/datepicker_ticket_4240.html index 2349c14d0..34a3cde07 100644 --- a/tests/visual/datepicker/datepicker_ticket_4240.html +++ b/tests/visual/datepicker/datepicker_ticket_4240.html @@ -5,7 +5,7 @@ <title>Datepicker Visual Test : Datepicker ticket #4240</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/datepicker/datepicker_ticket_4443.html b/tests/visual/datepicker/datepicker_ticket_4443.html index 82d81f1d7..1c12c001c 100644 --- a/tests/visual/datepicker/datepicker_ticket_4443.html +++ b/tests/visual/datepicker/datepicker_ticket_4443.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> <link rel="stylesheet" href="http://jquery.com/demo/thickbox/thickbox-code/thickbox.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script src="http://jquery.com/demo/thickbox/thickbox-code/thickbox-compressed.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/visual/datepicker/datepicker_ticket_5676.html b/tests/visual/datepicker/datepicker_ticket_5676.html index c408e8e8b..1dee497a2 100644 --- a/tests/visual/datepicker/datepicker_ticket_5676.html +++ b/tests/visual/datepicker/datepicker_ticket_5676.html @@ -5,7 +5,7 @@ <title>Datepicker Visual Test : Datepicker ticket #5676</title> <link href="../visual.css" type="text/css" rel="stylesheet" /> <link href="../../../themes/base/jquery.ui.all.css" type="text/css" rel="stylesheet"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.ui.core.js"></script> <script src="../../../ui/jquery.ui.widget.js"></script> <script src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/datepicker/datepicker_ticket_7552.html b/tests/visual/datepicker/datepicker_ticket_7552.html new file mode 100644 index 000000000..5ec093975 --- /dev/null +++ b/tests/visual/datepicker/datepicker_ticket_7552.html @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="UTF-8" /> + <title>Datepicker Visual Test : Datepicker ticket #7552</title> + <link rel="stylesheet" href="../visual.css" type="text/css" /> + <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> + <script src="../../../jquery-1.6.2.js"></script> + <script src="../../../ui/jquery.ui.core.js"></script> + <script src="../../../ui/jquery.ui.widget.js"></script> + <script src="../../../ui/jquery.ui.datepicker.js"></script> + <script type="text/javascript"> + $(function() { + $('<div></div>').datepicker().appendTo("body"); + }); + </script> +</head> +<body> + +<h1 class="ui-widget-header"><a href="http://dev.jqueryui.com/ticket/7552">#7552 - A Datepicker created on a detached div has zero height</a></h1> + +</body> +</html> diff --git a/tests/visual/datepicker/multimonth.html b/tests/visual/datepicker/multimonth.html index e78fddf7a..da5dc3b42 100644 --- a/tests/visual/datepicker/multimonth.html +++ b/tests/visual/datepicker/multimonth.html @@ -5,7 +5,7 @@ <title>Datepicker Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/datepicker/viewport.html b/tests/visual/datepicker/viewport.html index 620a80537..d1412fc03 100644 --- a/tests/visual/datepicker/viewport.html +++ b/tests/visual/datepicker/viewport.html @@ -15,7 +15,7 @@ } </style> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.datepicker.js"></script> diff --git a/tests/visual/dialog/dialog_on_page_with_large_dom.html b/tests/visual/dialog/dialog_on_page_with_large_dom.html index 7b0067a88..e06378ca3 100644 --- a/tests/visual/dialog/dialog_on_page_with_large_dom.html +++ b/tests/visual/dialog/dialog_on_page_with_large_dom.html @@ -5,7 +5,7 @@ <title>Dialog Visual Test : Modal Dialog in Large DOM</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../external/jquery.bgiframe-2.1.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> diff --git a/tests/visual/draggable/draggable.html b/tests/visual/draggable/draggable.html index 09982d310..85c096600 100644 --- a/tests/visual/draggable/draggable.html +++ b/tests/visual/draggable/draggable.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable.scroll.html b/tests/visual/draggable/draggable.scroll.html index 84a4ba2d1..206d0d63e 100644 --- a/tests/visual/draggable/draggable.scroll.html +++ b/tests/visual/draggable/draggable.scroll.html @@ -5,7 +5,7 @@ <title>Draggable Scroll Tests</title> <link rel="stylesheet" href="../all.css" type="text/css"> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable_option_containment_array.html b/tests/visual/draggable/draggable_option_containment_array.html index 3fe3802fa..ba0fcb122 100644 --- a/tests/visual/draggable/draggable_option_containment_array.html +++ b/tests/visual/draggable/draggable_option_containment_array.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Draggable option containment array</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable_option_cursorAt_object.html b/tests/visual/draggable/draggable_option_cursorAt_object.html index 00736327f..901f5f262 100644 --- a/tests/visual/draggable/draggable_option_cursorAt_object.html +++ b/tests/visual/draggable/draggable_option_cursorAt_object.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Draggable option cursorAt object</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable_option_handle_selector.html b/tests/visual/draggable/draggable_option_handle_selector.html index 53decb40c..d780f3dc0 100644 --- a/tests/visual/draggable/draggable_option_handle_selector.html +++ b/tests/visual/draggable/draggable_option_handle_selector.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Draggable option handle selector</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable_option_iframeFix_false.html b/tests/visual/draggable/draggable_option_iframeFix_false.html index 9528a5d08..8e17c04cc 100644 --- a/tests/visual/draggable/draggable_option_iframeFix_false.html +++ b/tests/visual/draggable/draggable_option_iframeFix_false.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Draggable option iframeFix false</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable_option_iframeFix_selector.html b/tests/visual/draggable/draggable_option_iframeFix_selector.html index c3655970c..355df8756 100644 --- a/tests/visual/draggable/draggable_option_iframeFix_selector.html +++ b/tests/visual/draggable/draggable_option_iframeFix_selector.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Draggable option iframeFix selector</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/draggable/draggable_option_iframeFix_true.html b/tests/visual/draggable/draggable_option_iframeFix_true.html index de7b31521..0f7f10fe0 100644 --- a/tests/visual/draggable/draggable_option_iframeFix_true.html +++ b/tests/visual/draggable/draggable_option_iframeFix_true.html @@ -5,7 +5,7 @@ <title>Draggable Visual Test : Draggable option iframeFix true</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/droppable/droppable.html b/tests/visual/droppable/droppable.html index 3ec6738bc..833a2b551 100644 --- a/tests/visual/droppable/droppable.html +++ b/tests/visual/droppable/droppable.html @@ -5,7 +5,7 @@ <title>Droppable Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/droppable/droppable_option_accept_default.html b/tests/visual/droppable/droppable_option_accept_default.html index 3aa83353c..cce302c55 100644 --- a/tests/visual/droppable/droppable_option_accept_default.html +++ b/tests/visual/droppable/droppable_option_accept_default.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="droppable.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/droppable/droppable_option_accept_function.html b/tests/visual/droppable/droppable_option_accept_function.html index ff4a7951a..178bcf946 100644 --- a/tests/visual/droppable/droppable_option_accept_function.html +++ b/tests/visual/droppable/droppable_option_accept_function.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="droppable.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/droppable/droppable_option_accept_selector.html b/tests/visual/droppable/droppable_option_accept_selector.html index 65cf18e18..238f53178 100644 --- a/tests/visual/droppable/droppable_option_accept_selector.html +++ b/tests/visual/droppable/droppable_option_accept_selector.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="droppable.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/droppable/droppable_ticket_4087.html b/tests/visual/droppable/droppable_ticket_4087.html index 84945bf55..7f64a45ec 100644 --- a/tests/visual/droppable/droppable_ticket_4087.html +++ b/tests/visual/droppable/droppable_ticket_4087.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>Droppable Visual Test - Droppable ticket 4087</title> <link type="text/css" href="../../../themes/base/jquery.ui.all.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/droppable/droppable_ticket_4088.html b/tests/visual/droppable/droppable_ticket_4088.html index 148d55eb2..0a21e977e 100644 --- a/tests/visual/droppable/droppable_ticket_4088.html +++ b/tests/visual/droppable/droppable_ticket_4088.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>Droppable Visual Test - Droppable ticket 4088</title> <link type="text/css" href="../../../themes/base/jquery.ui.all.css" rel="stylesheet" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/effects/effects.all.html b/tests/visual/effects/effects.all.html index a2f8f62ef..f4ae7ddb5 100644 --- a/tests/visual/effects/effects.all.html +++ b/tests/visual/effects/effects.all.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects Test Suite</title> <link rel="stylesheet" href="effects.all.css" type="text/css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.effects.core.js"></script> <script src="../../../ui/jquery.effects.blind.js"></script> <script src="../../../ui/jquery.effects.bounce.js"></script> diff --git a/tests/visual/effects/effects.scale.html b/tests/visual/effects/effects.scale.html index 9521a1872..5bcded605 100644 --- a/tests/visual/effects/effects.scale.html +++ b/tests/visual/effects/effects.scale.html @@ -4,7 +4,7 @@ <meta charset="utf-8"> <title>jQuery UI Effects Test Suite</title> <link rel="stylesheet" href="effects.all.css" type="text/css"> - <script src="../../../jquery-1.5.1.js"></script> + <script src="../../../jquery-1.6.2.js"></script> <script src="../../../ui/jquery.effects.core.js"></script> <script src="../../../ui/jquery.effects.scale.js"></script> <script src="effects.all.js"></script> diff --git a/tests/visual/menu/drilldown.html b/tests/visual/menu/drilldown.html index e752aa80d..c54c90fde 100644 --- a/tests/visual/menu/drilldown.html +++ b/tests/visual/menu/drilldown.html @@ -4,7 +4,7 @@ <title>Menu Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/menu/menu.html b/tests/visual/menu/menu.html index 1db12f25b..5720d04d9 100644 --- a/tests/visual/menu/menu.html +++ b/tests/visual/menu/menu.html @@ -4,7 +4,7 @@ <title>Menu Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/menu/tablemenu.html b/tests/visual/menu/tablemenu.html index e1c069e18..1eea8e02b 100644 --- a/tests/visual/menu/tablemenu.html +++ b/tests/visual/menu/tablemenu.html @@ -4,7 +4,7 @@ <title>Menu Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.menu.js"></script> diff --git a/tests/visual/mouse/mouse_ticket_6946.html b/tests/visual/mouse/mouse_ticket_6946.html index a4b44ef7e..d8d99ef99 100644 --- a/tests/visual/mouse/mouse_ticket_6946.html +++ b/tests/visual/mouse/mouse_ticket_6946.html @@ -5,7 +5,7 @@ <title>Test for Issue #6946</title> <link rel="stylesheet" href="../all.css" type="text/css"> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/position/position.html b/tests/visual/position/position.html index 11932da0e..5a8b1c814 100644 --- a/tests/visual/position/position.html +++ b/tests/visual/position/position.html @@ -5,7 +5,7 @@ <title>Position Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/position/position_margin.html b/tests/visual/position/position_margin.html index 0c7e32f3c..f47c87a5b 100644 --- a/tests/visual/position/position_margin.html +++ b/tests/visual/position/position_margin.html @@ -5,7 +5,7 @@ <title>Position Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/position/position_within.html b/tests/visual/position/position_within.html index f120a4b47..df8d637ea 100644 --- a/tests/visual/position/position_within.html +++ b/tests/visual/position/position_within.html @@ -7,12 +7,12 @@ <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> - <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> - <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> - <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> - <script type="text/javascript" src="../../../ui/jquery.ui.draggable.js"></script> - <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> + <script src="../../../jquery-1.6.2.js"></script> + <script src="../../../ui/jquery.ui.core.js"></script> + <script src="../../../ui/jquery.ui.widget.js"></script> + <script src="../../../ui/jquery.ui.mouse.js"></script> + <script src="../../../ui/jquery.ui.draggable.js"></script> + <script src="../../../ui/jquery.ui.position.js"></script> <style> html, body { @@ -66,9 +66,20 @@ bottom: 0; background-color: #bcd5e6; text-align: center; - border:solid 2px #555; cursor:move; } + .ui-flipped-top { + border-top: 3px solid #000000; + } + .ui-flipped-bottom { + border-bottom: 3px solid #000000; + } + .ui-flipped-left { + border-left: 3px solid #000000; + } + .ui-flipped-right { + border-right: 3px solid #000000; + } select, input { margin-left: 15px; } diff --git a/tests/visual/resizable/resizable.html b/tests/visual/resizable/resizable.html index e9abf8fe5..eaf6b5726 100644 --- a/tests/visual/resizable/resizable.html +++ b/tests/visual/resizable/resizable.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_alsoResize_child.html b/tests/visual/resizable/resizable_option_alsoResize_child.html index 57f6b0618..f9fd9e9a8 100644 --- a/tests/visual/resizable/resizable_option_alsoResize_child.html +++ b/tests/visual/resizable/resizable_option_alsoResize_child.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option alsoResize child</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_0.5.html b/tests/visual/resizable/resizable_option_aspectRatio_0.5.html index 1c14f0b3e..5326a635f 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_0.5.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_0.5.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 0.5</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_1.0.html b/tests/visual/resizable/resizable_option_aspectRatio_1.0.html index c680bc3ae..eee396f47 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_1.0.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_1.0.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 1.0</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_1.5.html b/tests/visual/resizable/resizable_option_aspectRatio_1.5.html index ffdbc957b..6a3067292 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_1.5.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_1.5.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 1.5</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxHeight_150.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxHeight_150.html index 70228de81..72f653c96 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxHeight_150.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxHeight_150.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 1.0 maxHeight 150</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxWidth_150.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxWidth_150.html index 43773fde4..241a6c9c1 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxWidth_150.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_maxWidth_150.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 1.0 maxWidth 150</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_minHeight_50.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_minHeight_50.html index 514151349..eea988e0d 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_minHeight_50.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_minHeight_50.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 1.0 minHeight 50</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_minWidth_50.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_minWidth_50.html index 33f1457bf..c8509d355 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_minWidth_50.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_minWidth_50.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable option aspectRatio 1.0 maxWidth 50</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh100.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh100.html index 5feafd257..c1c20e123 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh100.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh100.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh50.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh50.html index 05448f603..d45e27492 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh50.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_w100xh50.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_option_aspectRatio_preserve_w50xh100.html b/tests/visual/resizable/resizable_option_aspectRatio_preserve_w50xh100.html index 49ef182ea..4d8e5da15 100644 --- a/tests/visual/resizable/resizable_option_aspectRatio_preserve_w50xh100.html +++ b/tests/visual/resizable/resizable_option_aspectRatio_preserve_w50xh100.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_ticket_3053.html b/tests/visual/resizable/resizable_ticket_3053.html index d0844436a..0178bb935 100644 --- a/tests/visual/resizable/resizable_ticket_3053.html +++ b/tests/visual/resizable/resizable_ticket_3053.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable ticket #3053</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_ticket_4199.html b/tests/visual/resizable/resizable_ticket_4199.html index 234387307..c7929063a 100644 --- a/tests/visual/resizable/resizable_ticket_4199.html +++ b/tests/visual/resizable/resizable_ticket_4199.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable ticket #4199</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_ticket_4217.html b/tests/visual/resizable/resizable_ticket_4217.html index d08342df6..f3cece133 100644 --- a/tests/visual/resizable/resizable_ticket_4217.html +++ b/tests/visual/resizable/resizable_ticket_4217.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable ticket #4217</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_ticket_4940.html b/tests/visual/resizable/resizable_ticket_4940.html index 6a7067c93..52b33028d 100644 --- a/tests/visual/resizable/resizable_ticket_4940.html +++ b/tests/visual/resizable/resizable_ticket_4940.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable ticket #4940</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/resizable/resizable_ticket_5335.html b/tests/visual/resizable/resizable_ticket_5335.html index b8c227844..6927d88a4 100644 --- a/tests/visual/resizable/resizable_ticket_5335.html +++ b/tests/visual/resizable/resizable_ticket_5335.html @@ -5,7 +5,7 @@ <title>Resizable Visual Test : Resizable ticket #5335</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/selectable/selectable.html b/tests/visual/selectable/selectable.html index 76d8174c8..6fb1eae29 100644 --- a/tests/visual/selectable/selectable.html +++ b/tests/visual/selectable/selectable.html @@ -5,7 +5,7 @@ <title>Selectable Visual Test : Default</title> <link rel="stylesheet" href="../all.css" type="text/css"> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/selectable/selectable_ticket_4341.html b/tests/visual/selectable/selectable_ticket_4341.html index 0bd77243b..dbd9643ab 100644 --- a/tests/visual/selectable/selectable_ticket_4341.html +++ b/tests/visual/selectable/selectable_ticket_4341.html @@ -5,7 +5,7 @@ <title>Selectable Visual Test : Selectable ticket #4341</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider.html b/tests/visual/slider/slider.html index 9c666eb4a..816a5e620 100644 --- a/tests/visual/slider/slider.html +++ b/tests/visual/slider/slider.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_horizontal.html b/tests/visual/slider/slider_horizontal.html index 52e13f5b9..1bc971e08 100644 --- a/tests/visual/slider/slider_horizontal.html +++ b/tests/visual/slider/slider_horizontal.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider horizontal</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_horizontal_range.html b/tests/visual/slider/slider_horizontal_range.html index c10451cc5..3b3d60f03 100644 --- a/tests/visual/slider/slider_horizontal_range.html +++ b/tests/visual/slider/slider_horizontal_range.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider horizontal range</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_horizontal_range_max.html b/tests/visual/slider/slider_horizontal_range_max.html index 0cb45fd06..2e52ff0aa 100644 --- a/tests/visual/slider/slider_horizontal_range_max.html +++ b/tests/visual/slider/slider_horizontal_range_max.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider horizontal range max</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_horizontal_range_min.html b/tests/visual/slider/slider_horizontal_range_min.html index 101121b91..7e98fb0c7 100644 --- a/tests/visual/slider/slider_horizontal_range_min.html +++ b/tests/visual/slider/slider_horizontal_range_min.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider horizontal range min</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_in_container_with_scrollbars.html b/tests/visual/slider/slider_in_container_with_scrollbars.html index 0a050ff98..bf5723373 100644 --- a/tests/visual/slider/slider_in_container_with_scrollbars.html +++ b/tests/visual/slider/slider_in_container_with_scrollbars.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider in container with scrollbars</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_method_destroy.html b/tests/visual/slider/slider_method_destroy.html index 931913aaf..5f71871b9 100644 --- a/tests/visual/slider/slider_method_destroy.html +++ b/tests/visual/slider/slider_method_destroy.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider method destroy</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_method_disable.html b/tests/visual/slider/slider_method_disable.html index d7ed75a1a..e060ebd70 100644 --- a/tests/visual/slider/slider_method_disable.html +++ b/tests/visual/slider/slider_method_disable.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider method disable</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_animate_false.html b/tests/visual/slider/slider_option_animate_false.html index fce6e5668..2724278db 100644 --- a/tests/visual/slider/slider_option_animate_false.html +++ b/tests/visual/slider/slider_option_animate_false.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option animate false</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_animate_true.html b/tests/visual/slider/slider_option_animate_true.html index 8d12abcff..b9c0a50ee 100644 --- a/tests/visual/slider/slider_option_animate_true.html +++ b/tests/visual/slider/slider_option_animate_true.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option animate true</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_max_3.html b/tests/visual/slider/slider_option_max_3.html index 82de69272..7ef05e009 100644 --- a/tests/visual/slider/slider_option_max_3.html +++ b/tests/visual/slider/slider_option_max_3.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option max 3</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_max_30.html b/tests/visual/slider/slider_option_max_30.html index 36126ffae..7c0203764 100644 --- a/tests/visual/slider/slider_option_max_30.html +++ b/tests/visual/slider/slider_option_max_30.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option max 30</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_max_300.html b/tests/visual/slider/slider_option_max_300.html index d51cd86e7..df5d13ea4 100644 --- a/tests/visual/slider/slider_option_max_300.html +++ b/tests/visual/slider/slider_option_max_300.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option max 300</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_min_-3.html b/tests/visual/slider/slider_option_min_-3.html index 9a18ed4d0..512d8312c 100644 --- a/tests/visual/slider/slider_option_min_-3.html +++ b/tests/visual/slider/slider_option_min_-3.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option min -3</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_min_-30.html b/tests/visual/slider/slider_option_min_-30.html index 88b655288..7f68b5b42 100644 --- a/tests/visual/slider/slider_option_min_-30.html +++ b/tests/visual/slider/slider_option_min_-30.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option min -30</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_min_-300.html b/tests/visual/slider/slider_option_min_-300.html index 1a55cabc1..0aa6db165 100644 --- a/tests/visual/slider/slider_option_min_-300.html +++ b/tests/visual/slider/slider_option_min_-300.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option min -300</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_orientation_horizontal.html b/tests/visual/slider/slider_option_orientation_horizontal.html index c7efb2f62..a2d61bea9 100644 --- a/tests/visual/slider/slider_option_orientation_horizontal.html +++ b/tests/visual/slider/slider_option_orientation_horizontal.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option orientation 'horizontal'</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_orientation_vertical.html b/tests/visual/slider/slider_option_orientation_vertical.html index 4cecf707d..8b521d70e 100644 --- a/tests/visual/slider/slider_option_orientation_vertical.html +++ b/tests/visual/slider/slider_option_orientation_vertical.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option orientation 'vertical'</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_range_false.html b/tests/visual/slider/slider_option_range_false.html index 976888bc8..3c8566de7 100644 --- a/tests/visual/slider/slider_option_range_false.html +++ b/tests/visual/slider/slider_option_range_false.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option range false</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_range_max.html b/tests/visual/slider/slider_option_range_max.html index 4ae3cb747..be863f08f 100644 --- a/tests/visual/slider/slider_option_range_max.html +++ b/tests/visual/slider/slider_option_range_max.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option range 'max'</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_range_min.html b/tests/visual/slider/slider_option_range_min.html index af9366009..288a7b088 100644 --- a/tests/visual/slider/slider_option_range_min.html +++ b/tests/visual/slider/slider_option_range_min.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option range 'min'</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_range_true.html b/tests/visual/slider/slider_option_range_true.html index b4b4f3ed7..d1d4ffe74 100644 --- a/tests/visual/slider/slider_option_range_true.html +++ b/tests/visual/slider/slider_option_range_true.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option range true</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_step_25.html b/tests/visual/slider/slider_option_step_25.html index c69a54707..a55fe1cba 100644 --- a/tests/visual/slider/slider_option_step_25.html +++ b/tests/visual/slider/slider_option_step_25.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option step 25</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_step_5.html b/tests/visual/slider/slider_option_step_5.html index 560d1026a..3099d0082 100644 --- a/tests/visual/slider/slider_option_step_5.html +++ b/tests/visual/slider/slider_option_step_5.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option step 5</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_value_3.html b/tests/visual/slider/slider_option_value_3.html index 92820cd2f..e1531a27b 100644 --- a/tests/visual/slider/slider_option_value_3.html +++ b/tests/visual/slider/slider_option_value_3.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option value 3</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_value_30.html b/tests/visual/slider/slider_option_value_30.html index 3a7223742..42d76332d 100644 --- a/tests/visual/slider/slider_option_value_30.html +++ b/tests/visual/slider/slider_option_value_30.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option value 30</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_values_25_50_75.html b/tests/visual/slider/slider_option_values_25_50_75.html index eab691b83..30ca81d6e 100644 --- a/tests/visual/slider/slider_option_values_25_50_75.html +++ b/tests/visual/slider/slider_option_values_25_50_75.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option values 25 50 75</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_values_25_75.html b/tests/visual/slider/slider_option_values_25_75.html index 2d57b54ee..8181e4b6e 100644 --- a/tests/visual/slider/slider_option_values_25_75.html +++ b/tests/visual/slider/slider_option_values_25_75.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option values 25 75</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_option_values_50.html b/tests/visual/slider/slider_option_values_50.html index 3f3472581..898ff097f 100644 --- a/tests/visual/slider/slider_option_values_50.html +++ b/tests/visual/slider/slider_option_values_50.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider option values 50</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_ticket_3736.html b/tests/visual/slider/slider_ticket_3736.html index ccc6b1e04..29e784cdb 100644 --- a/tests/visual/slider/slider_ticket_3736.html +++ b/tests/visual/slider/slider_ticket_3736.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider ticket #3736</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_ticket_3762.html b/tests/visual/slider/slider_ticket_3762.html index eade7e3e1..9130d7870 100644 --- a/tests/visual/slider/slider_ticket_3762.html +++ b/tests/visual/slider/slider_ticket_3762.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider ticket #3762</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_ticket_4385.html b/tests/visual/slider/slider_ticket_4385.html index 8a35c162a..736e0164e 100644 --- a/tests/visual/slider/slider_ticket_4385.html +++ b/tests/visual/slider/slider_ticket_4385.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider ticket #4385</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_ticket_4467.html b/tests/visual/slider/slider_ticket_4467.html index a717f611f..16fe470e2 100644 --- a/tests/visual/slider/slider_ticket_4467.html +++ b/tests/visual/slider/slider_ticket_4467.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider ticket #4467</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_vertical.html b/tests/visual/slider/slider_vertical.html index 597f67e14..e920a5ff0 100644 --- a/tests/visual/slider/slider_vertical.html +++ b/tests/visual/slider/slider_vertical.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider vertical</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_vertical_range.html b/tests/visual/slider/slider_vertical_range.html index 0ca3303b3..0b5c832ad 100644 --- a/tests/visual/slider/slider_vertical_range.html +++ b/tests/visual/slider/slider_vertical_range.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider vertical range</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_vertical_range_max.html b/tests/visual/slider/slider_vertical_range_max.html index 212241625..bdf943a38 100644 --- a/tests/visual/slider/slider_vertical_range_max.html +++ b/tests/visual/slider/slider_vertical_range_max.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider vertical range max</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/slider/slider_vertical_range_min.html b/tests/visual/slider/slider_vertical_range_min.html index f94e6cc03..d05d9b0c6 100644 --- a/tests/visual/slider/slider_vertical_range_min.html +++ b/tests/visual/slider/slider_vertical_range_min.html @@ -5,7 +5,7 @@ <title>Slider Visual Test : Slider vertical range min</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/sortable/sortable.html b/tests/visual/sortable/sortable.html index db941bdc3..bc62a16cd 100644 --- a/tests/visual/sortable/sortable.html +++ b/tests/visual/sortable/sortable.html @@ -5,7 +5,7 @@ <title>Sortable Visual Test : Default</title> <link rel="stylesheet" href="../all.css" type="text/css"> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/sortable/sortable_massive_scale.html b/tests/visual/sortable/sortable_massive_scale.html index 8691c039a..70f003c9b 100644 --- a/tests/visual/sortable/sortable_massive_scale.html +++ b/tests/visual/sortable/sortable_massive_scale.html @@ -4,7 +4,7 @@ <meta charset="UTF-8" /> <title>Sortable Massive Scale Test</title> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/sortable/sortable_option_revert_false.html b/tests/visual/sortable/sortable_option_revert_false.html index 1696fd854..87d029fd8 100644 --- a/tests/visual/sortable/sortable_option_revert_false.html +++ b/tests/visual/sortable/sortable_option_revert_false.html @@ -5,7 +5,7 @@ <title>Sortable Visual Test : Sortable option revert false</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/sortable/sortable_option_revert_true.html b/tests/visual/sortable/sortable_option_revert_true.html index 6bd23db68..b7f44a6f8 100644 --- a/tests/visual/sortable/sortable_option_revert_true.html +++ b/tests/visual/sortable/sortable_option_revert_true.html @@ -5,7 +5,7 @@ <title>Sortable Visual Test : Sortable option revert true</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" /> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/sortable/sortable_ticket_4231.html b/tests/visual/sortable/sortable_ticket_4231.html index 8b80808b1..74cded7f0 100644 --- a/tests/visual/sortable/sortable_ticket_4231.html +++ b/tests/visual/sortable/sortable_ticket_4231.html @@ -5,7 +5,7 @@ <title>Visual testcase for #4231</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/sortable/sortable_ticket_5355.html b/tests/visual/sortable/sortable_ticket_5355.html index 45709e2a6..f5058a4c0 100644 --- a/tests/visual/sortable/sortable_ticket_5355.html +++ b/tests/visual/sortable/sortable_ticket_5355.html @@ -5,7 +5,7 @@ <title>Sortable Visual Test : Sortable ticket #5355</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/spinner/spinner.html b/tests/visual/spinner/spinner.html index cd4938f71..0711b4e2b 100644 --- a/tests/visual/spinner/spinner.html +++ b/tests/visual/spinner/spinner.html @@ -4,7 +4,7 @@ <title>Spinner Visual Test Page</title>
<link rel="stylesheet" href="../visual.css" type="text/css" />
<link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" />
- <script type="text/javascript" src="../../../jquery-1.5.1.js"></script>
+ <script type="text/javascript" src="../../../jquery-1.6.2.js"></script>
<script type="text/javascript" src="../../../external/jquery.mousewheel-3.0.4.js"></script>
<script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script>
<script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script>
diff --git a/tests/visual/theme.html b/tests/visual/theme.html index 90c9c3edd..c8508b69b 100644 --- a/tests/visual/theme.html +++ b/tests/visual/theme.html @@ -4,7 +4,7 @@ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>jQuery UI Example Page</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../ui/jquery.ui.mouse.js"></script> diff --git a/tests/visual/tooltip/animations.html b/tests/visual/tooltip/animations.html index f0deac1d3..3465c8018 100644 --- a/tests/visual/tooltip/animations.html +++ b/tests/visual/tooltip/animations.html @@ -4,7 +4,7 @@ <title>Tooltip Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/tooltip/callout.html b/tests/visual/tooltip/callout.html index f7856d076..3fe51a6d0 100644 --- a/tests/visual/tooltip/callout.html +++ b/tests/visual/tooltip/callout.html @@ -4,7 +4,7 @@ <title>Tooltip Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/tests/visual/tooltip/tooltip.html b/tests/visual/tooltip/tooltip.html index 70c850b60..ab6f412f3 100644 --- a/tests/visual/tooltip/tooltip.html +++ b/tests/visual/tooltip/tooltip.html @@ -4,7 +4,7 @@ <title>Tooltip Visual Test: Default</title> <link rel="stylesheet" href="../visual.css" type="text/css" /> <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css"> - <script type="text/javascript" src="../../../jquery-1.5.1.js"></script> + <script type="text/javascript" src="../../../jquery-1.6.2.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.core.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.widget.js"></script> <script type="text/javascript" src="../../../ui/jquery.ui.position.js"></script> diff --git a/ui/i18n/jquery.ui.datepicker-nl.js b/ui/i18n/jquery.ui.datepicker-nl.js index 09634088b..781fe6191 100644 --- a/ui/i18n/jquery.ui.datepicker-nl.js +++ b/ui/i18n/jquery.ui.datepicker-nl.js @@ -8,7 +8,7 @@ jQuery(function($){ currentText: 'Vandaag', monthNames: ['januari', 'februari', 'maart', 'april', 'mei', 'juni', 'juli', 'augustus', 'september', 'oktober', 'november', 'december'], - monthNamesShort: ['jan', 'feb', 'maa', 'apr', 'mei', 'jun', + monthNamesShort: ['jan', 'feb', 'mrt', 'apr', 'mei', 'jun', 'jul', 'aug', 'sep', 'okt', 'nov', 'dec'], dayNames: ['zondag', 'maandag', 'dinsdag', 'woensdag', 'donderdag', 'vrijdag', 'zaterdag'], dayNamesShort: ['zon', 'maa', 'din', 'woe', 'don', 'vri', 'zat'], diff --git a/ui/jquery.effects.blind.js b/ui/jquery.effects.blind.js index b6485b641..5f86bed7b 100644 --- a/ui/jquery.effects.blind.js +++ b/ui/jquery.effects.blind.js @@ -11,74 +11,67 @@ * jquery.effects.core.js */ (function( $, undefined ) { - -var rvertical = /up|down|vertical/; -var rpositivemotion = /up|left|vertical|horizontal/; -$.effects.effect.blind = function( o ) { +var rvertical = /up|down|vertical/, + rpositivemotion = /up|left|vertical|horizontal/; - return this.queue( function() { +$.effects.effect.blind = function( o, done ) { + // Create element + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "height", "width" ], + mode = $.effects.setMode( el, o.mode || "hide" ), + direction = o.direction || "up", + vertical = rvertical.test( direction ), + ref = vertical ? "height" : "width", + ref2 = vertical ? "top" : "left", + motion = rpositivemotion.test( direction ), + animation = {}, + show = mode === "show", + wrapper, distance; - // Create element - var el = $( this ), - props = [ "position", "top", "bottom", "left", "right", "height", "width" ], - mode = $.effects.setMode( el, o.mode || "hide" ), - direction = o.direction || "up", - vertical = rvertical.test( direction ), - ref = vertical ? "height" : "width", - ref2 = vertical ? "top" : "left", - motion = rpositivemotion.test( direction ), - animation = {}, - wrapper, distance; + // if already wrapped, the wrapper's properties are my property. #6245 + if ( el.parent().is( ".ui-effects-wrapper" ) ) { + $.effects.save( el.parent(), props ); + } else { + $.effects.save( el, props ); + } + el.show(); + wrapper = $.effects.createWrapper( el ).css({ + overflow: "hidden" + }); - // if already wrapped, the wrapper's properties are my property. #6245 - if ( el.parent().is( ".ui-effects-wrapper" ) ) { - $.effects.save( el.parent(), props ); - } else { - $.effects.save( el, props ); - } - el.show(); - wrapper = $.effects.createWrapper( el ).css({ - overflow: "hidden" - }); + distance = wrapper[ ref ](); - distance = wrapper[ ref ](); + animation[ ref ] = show ? distance : 0; + if ( !motion ) { + el + .css( vertical ? "bottom" : "right", 0 ) + .css( vertical ? "top" : "left", "" ) + .css({ position: "absolute" }); + animation[ ref2 ] = show ? 0 : distance; + } - animation[ ref ] = ( mode === "show" ? distance : 0 ); - if ( !motion ) { - el - .css( vertical ? "bottom" : "right", 0 ) - .css( vertical ? "top" : "left", "" ) - .css({ position: "absolute" }); - animation[ ref2 ] = ( mode === "show" ) ? 0 : distance; + // start at 0 if we are showing + if ( show ) { + wrapper.css( ref, 0 ); + if ( ! motion ) { + wrapper.css( ref2, distance ); } + } - // start at 0 if we are showing - if ( mode == "show" ) { - wrapper.css( ref, 0 ); - if ( ! motion ) { - wrapper.css( ref2, distance ); + // Animate + wrapper.animate( animation, { + duration: o.duration, + easing: o.easing, + queue: false, + complete: function() { + if ( mode === "hide" ) { + el.hide(); } + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); } - - // Animate - wrapper.animate( animation, { - duration: o.duration, - easing: o.easing, - queue: false, - complete: function() { - if ( mode == "hide" ) { - el.hide(); - } - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - if ( $.isFunction( o.complete ) ) { - o.complete.apply( el[ 0 ], arguments ); - } - el.dequeue(); - } - }); - }); }; diff --git a/ui/jquery.effects.bounce.js b/ui/jquery.effects.bounce.js index 78fedb0ce..41ee34f64 100644 --- a/ui/jquery.effects.bounce.js +++ b/ui/jquery.effects.bounce.js @@ -12,108 +12,101 @@ */ (function( $, undefined ) { -$.effects.effect.bounce = function(o) { - - return this.queue( function( next ) { - var el = $( this ), - props = [ "position", "top", "bottom", "left", "right", "height", "width" ], - - // defaults: - mode = $.effects.setMode( el, o.mode || "effect" ), - hide = mode === "hide", - show = mode === "show", - direction = o.direction || "up", - distance = o.distance, - times = o.times || 5, - - // number of internal animations - anims = times * 2 + ( show || hide ? 1 : 0 ), - speed = o.duration / anims, - easing = o.easing, - - // utility: - ref = ( direction === "up" || direction === "down" ) ? "top" : "left", - motion = ( direction === "up" || direction === "left" ), - i, - upAnim, - downAnim, - - // we will need to re-assemble the queue to stack our animations in place - queue = el.queue(), - queuelen = queue.length; - - // Avoid touching opacity to prevent clearType and PNG issues in IE - if ( show || hide ) { - props.push( "opacity" ); - } - - $.effects.save( el, props ); - el.show(); - $.effects.createWrapper( el ); // Create Wrapper - - // default distance for the BIGGEST bounce is the outer Distance / 3 - if ( !distance ) { - distance = el[ ref === "top" ? "outerHeight" : "outerWidth" ]() / 3; - } - - if ( show ) { - downAnim = { opacity: 1 }; - downAnim[ ref ] = 0; - - // if we are showing, force opacity 0 and set the initial position - // then do the "first" animation - el.css( "opacity", 0 ) - .css( ref, motion ? -distance*2 : distance*2 ) - .animate( downAnim, speed, easing ); - } - - // start at the smallest distance if we are hiding - if ( hide ) { - distance = distance / Math.pow( 2, times - 1 ); - } - - downAnim = {}; +$.effects.effect.bounce = function( o, done ) { + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "height", "width" ], + + // defaults: + mode = $.effects.setMode( el, o.mode || "effect" ), + hide = mode === "hide", + show = mode === "show", + direction = o.direction || "up", + distance = o.distance, + times = o.times || 5, + + // number of internal animations + anims = times * 2 + ( show || hide ? 1 : 0 ), + speed = o.duration / anims, + easing = o.easing, + + // utility: + ref = ( direction === "up" || direction === "down" ) ? "top" : "left", + motion = ( direction === "up" || direction === "left" ), + i, + upAnim, + downAnim, + + // we will need to re-assemble the queue to stack our animations in place + queue = el.queue(), + queuelen = queue.length; + + // Avoid touching opacity to prevent clearType and PNG issues in IE + if ( show || hide ) { + props.push( "opacity" ); + } + + $.effects.save( el, props ); + el.show(); + $.effects.createWrapper( el ); // Create Wrapper + + // default distance for the BIGGEST bounce is the outer Distance / 3 + if ( !distance ) { + distance = el[ ref === "top" ? "outerHeight" : "outerWidth" ]() / 3; + } + + if ( show ) { + downAnim = { opacity: 1 }; downAnim[ ref ] = 0; - // Bounces up/down/left/right then back to 0 -- times * 2 animations happen here - for ( i = 0; i < times; i++ ) { - upAnim = {}; - upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance; - el.animate( upAnim, speed, easing ) - .animate( downAnim, speed, easing ); - - distance = hide ? distance * 2 : distance / 2; - } - - // Last Bounce when Hiding + // if we are showing, force opacity 0 and set the initial position + // then do the "first" animation + el.css( "opacity", 0 ) + .css( ref, motion ? -distance * 2 : distance * 2 ) + .animate( downAnim, speed, easing ); + } + + // start at the smallest distance if we are hiding + if ( hide ) { + distance = distance / Math.pow( 2, times - 1 ); + } + + downAnim = {}; + downAnim[ ref ] = 0; + // Bounces up/down/left/right then back to 0 -- times * 2 animations happen here + for ( i = 0; i < times; i++ ) { + upAnim = {}; + upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance; + + el.animate( upAnim, speed, easing ) + .animate( downAnim, speed, easing ); + + distance = hide ? distance * 2 : distance / 2; + } + + // Last Bounce when Hiding + if ( hide ) { + upAnim = { opacity: 0 }; + upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance; + + el.animate( upAnim, speed, easing ); + } + + el.queue(function() { if ( hide ) { - upAnim = { opacity: 0 }; - upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance; - - el.animate( upAnim, speed, easing ); + el.hide(); } - - el.queue( function( next ) { - if ( hide ) { - el.hide(); - } - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - if ( o.complete ) { - o.complete.apply( el[ 0 ] ); - } - next(); - }); - - // inject all the animations we just queued to be first in line (after "inprogress") - if ( queuelen > 1) { - queue.splice.apply( queue, - [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) ); - } - next(); - + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); }); + // inject all the animations we just queued to be first in line (after "inprogress") + if ( queuelen > 1) { + queue.splice.apply( queue, + [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) ); + } + el.dequeue(); + }; })(jQuery); diff --git a/ui/jquery.effects.clip.js b/ui/jquery.effects.clip.js index dbf0d36c9..c6eecc671 100644 --- a/ui/jquery.effects.clip.js +++ b/ui/jquery.effects.clip.js @@ -12,61 +12,53 @@ */ (function( $, undefined ) { -$.effects.effect.clip = function( o ) { +$.effects.effect.clip = function( o, done ) { + // Create element + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "height", "width" ], + mode = $.effects.setMode( el, o.mode || "hide" ), + show = mode === "show", + direction = o.direction || "vertical", + vert = direction === "vertical", + size = vert ? "height" : "width", + position = vert ? "top" : "left", + animation = {}, + wrapper, animate, distance; - return this.queue( function() { + // Save & Show + $.effects.save( el, props ); + el.show(); - // Create element - var el = $( this ), - props = [ "position", "top", "bottom", "left", "right", "height", "width" ], - mode = $.effects.setMode( el, o.mode || "hide" ), - show = mode === "show", - direction = o.direction || "vertical", - vert = direction === "vertical", - size = vert ? "height" : "width", - position = vert ? "top" : "left", - animation = {}, - wrapper, animate, distance; - - // Save & Show - $.effects.save( el, props ); - el.show(); - - // Create Wrapper - wrapper = $.effects.createWrapper( el ).css({ - overflow: "hidden" - }); - animate = ( el[0].tagName === "IMG" ) ? wrapper : el; - distance = animate[ size ](); + // Create Wrapper + wrapper = $.effects.createWrapper( el ).css({ + overflow: "hidden" + }); + animate = ( el[0].tagName === "IMG" ) ? wrapper : el; + distance = animate[ size ](); - // Shift - if ( show ) { - animate.css( size, 0 ); - animate.css( position, distance / 2 ); - } + // Shift + if ( show ) { + animate.css( size, 0 ); + animate.css( position, distance / 2 ); + } - // Create Animation Object: - animation[ size ] = show ? distance : 0; - animation[ position ] = show ? 0 : distance / 2; + // Create Animation Object: + animation[ size ] = show ? distance : 0; + animation[ position ] = show ? 0 : distance / 2; - // Animate - animate.animate( animation, { - queue: false, - duration: o.duration, - easing: o.easing, - complete: function() { - if ( !show ) { - el.hide(); - } - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - if ( $.isFunction( o.complete ) ) { - o.complete.apply( el[ 0 ], arguments ); - } - el.dequeue(); + // Animate + animate.animate( animation, { + queue: false, + duration: o.duration, + easing: o.easing, + complete: function() { + if ( !show ) { + el.hide(); } - }); - + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); + } }); }; diff --git a/ui/jquery.effects.core.js b/ui/jquery.effects.core.js index 00a803360..b08cd6cf4 100644 --- a/ui/jquery.effects.core.js +++ b/ui/jquery.effects.core.js @@ -536,6 +536,7 @@ $.fn.extend({ effect: function( effect, options, speed, callback ) { var args = _normalizeArguments.apply( this, arguments ), mode = args.mode, + queue = args.queue, effectMethod = $.effects.effect[ args.effect ], // DEPRECATED: remove in 2.0 (#7115) @@ -554,9 +555,32 @@ $.fn.extend({ } } + function run( next ) { + var elem = $( this ), + complete = args.complete, + mode = args.mode; + + function done() { + if ( $.isFunction( complete ) ) { + complete.call( elem[0] ); + } + if ( $.isFunction( next ) ) { + next(); + } + } + + // if the element is hiddden and mode is hide, + // or element is visible and mode is show + if ( elem.is( ":hidden" ) ? mode === "hide" : mode === "show" ) { + done(); + } else { + effectMethod.call( elem[0], args, done ); + } + } + // TODO: remove this check in 2.0, effectMethod will always be true if ( effectMethod ) { - return effectMethod.call( this, args ); + return queue === false ? this.each( run ) : this.queue( queue || "fx", run ); } else { // DEPRECATED: remove in 2.0 (#7115) return oldEffectMethod.call(this, { diff --git a/ui/jquery.effects.drop.js b/ui/jquery.effects.drop.js index 4265b737b..2e7a6ec0f 100644 --- a/ui/jquery.effects.drop.js +++ b/ui/jquery.effects.drop.js @@ -12,51 +12,50 @@ */ (function( $, undefined ) { -$.effects.effect.drop = function( o ) { - - return this.queue( function() { - - var el = $( this ), - props = [ 'position', 'top', 'bottom', 'left', 'right', 'opacity', "height", "width" ], - mode = $.effects.setMode( el, o.mode || 'hide' ), - direction = o.direction || 'left', - ref = ( direction == 'up' || direction == 'down' ) ? 'top' : 'left', - motion = ( direction == 'up' || direction == 'left' ) ? 'pos' : 'neg', - animation = { - opacity: mode == 'show' ? 1 : 0 - }, - distance; - - // Adjust - $.effects.save( el, props ); - el.show(); - $.effects.createWrapper( el ); - - distance = o.distance || el[ ref == 'top' ? 'outerHeight': 'outerWidth' ]({ margin: true }) / 2; - - if ( mode == 'show' ) { - el - .css( 'opacity', 0 ) - .css( ref, motion == 'pos' ? -distance : distance ); +$.effects.effect.drop = function( o, done ) { + + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "opacity", "height", "width" ], + mode = $.effects.setMode( el, o.mode || "hide" ), + show = mode === "show", + direction = o.direction || "left", + ref = ( direction === "up" || direction === "down" ) ? "top" : "left", + motion = ( direction === "up" || direction === "left" ) ? "pos" : "neg", + animation = { + opacity: show ? 1 : 0 + }, + distance; + + // Adjust + $.effects.save( el, props ); + el.show(); + $.effects.createWrapper( el ); + + distance = o.distance || el[ ref == "top" ? "outerHeight": "outerWidth" ]({ margin: true }) / 2; + + if ( show ) { + el + .css( "opacity", 0 ) + .css( ref, motion == "pos" ? -distance : distance ); + } + + // Animation + animation[ ref ] = ( show ? + ( motion === "pos" ? "+=" : "-=" ) : + ( motion === "pos" ? "-=" : "+=" ) ) + + distance; + + // Animate + el.animate( animation, { + queue: false, + duration: o.duration, + easing: o.easing, + complete: function() { + mode == "hide" && el.hide(); + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); } - - // Animation - animation[ ref ] = ((mode == 'show') ? (motion == 'pos' ? '+=' : '-=') : (motion == 'pos' ? '-=' : '+=')) + distance; - - // Animate - el.animate( animation, { - queue: false, - duration: o.duration, - easing: o.easing, - complete: function() { - mode == 'hide' && el.hide(); - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - $.isFunction( o.complete ) && o.complete.apply(this, arguments); - el.dequeue(); - } - }); - }); }; diff --git a/ui/jquery.effects.explode.js b/ui/jquery.effects.explode.js index f5217ecb5..22f506045 100644 --- a/ui/jquery.effects.explode.js +++ b/ui/jquery.effects.explode.js @@ -12,92 +12,85 @@ */ (function( $, undefined ) { -$.effects.effect.explode = function( o ) { +$.effects.effect.explode = function( o, done ) { - return this.queue( function( next ) { + var rows = o.pieces ? Math.round( Math.sqrt( o.pieces ) ) : 3, + cells = rows, + el = $( this ), + mode = $.effects.setMode( el, o.mode || "hide" ), + show = mode === "show", - var rows = o.pieces ? Math.round(Math.sqrt(o.pieces)) : 3, - cells = rows, - el = $( this ), - mode = $.effects.setMode( el, o.mode || 'hide' ), - show = ( mode == 'show' ), + // show and then visibility:hidden the element before calculating offset + offset = el.show().css( "visibility", "hidden" ).offset(), - // show and then visibility:hidden the element before calculating offset - offset = el.show().css( 'visibility', 'hidden' ).offset(), + // width and height of a piece + width = Math.ceil( el.outerWidth() / cells ), + height = Math.ceil( el.outerHeight() / rows ), + pieces = [], - // width and height of a piece - width = Math.ceil( el.outerWidth() / cells ), - height = Math.ceil( el.outerHeight() / rows ), - pieces = [], + // loop + i, j, left, top, mx, my; - // loop - i, j, left, top, mx, my; + // clone the element for each row and cell. + for( i = 0; i < rows ; i++ ) { // ===> + top = offset.top + i * height; + my = i - ( rows - 1 ) / 2 ; - // clone the element for each row and cell. - for( i = 0; i < rows ; i++ ) { // ===> - top = offset.top + i * height; - my = i - ( rows - 1 ) / 2 ; + for( j = 0; j < cells ; j++ ) { // ||| + left = offset.left + j * width; + mx = j - ( cells - 1 ) / 2 ; - for( j = 0; j < cells ; j++ ) { // ||| - left = offset.left + j * width; - mx = j - ( cells - 1 ) / 2 ; + // Create a clone of the now hidden main element that will be absolute positioned + // within a wrapper div off the -left and -top equal to size of our pieces + el + .clone() + .appendTo( "body" ) + .wrap( "<div></div>" ) + .css({ + position: "absolute", + visibility: "visible", + left: -j * width, + top: -i * height + }) - // Create a clone of the now hidden main element that will be absolute positioned - // within a wrapper div off the -left and -top equal to size of our pieces - el - .clone() - .appendTo( 'body' ) - .wrap( '<div></div>' ) - .css({ - position: 'absolute', - visibility: 'visible', - left: -j * width, - top: -i * height - }) - - // select the wrapper - make it overflow: hidden and absolute positioned based on - // where the original was located +left and +top equal to the size of pieces - .parent() - .addClass( 'ui-effects-explode' ) - .css({ - position: 'absolute', - overflow: 'hidden', - width: width, - height: height, - left: left + ( show ? mx * width : 0 ), - top: top + ( show ? my * height : 0 ), - opacity: show ? 0 : 1 - }).animate({ - left: left + ( show ? 0 : mx * width ), - top: top + ( show ? 0 : my * height ), - opacity: show ? 1 : 0 - }, o.duration || 500, o.easing, childComplete ); - } + // select the wrapper - make it overflow: hidden and absolute positioned based on + // where the original was located +left and +top equal to the size of pieces + .parent() + .addClass( "ui-effects-explode" ) + .css({ + position: "absolute", + overflow: "hidden", + width: width, + height: height, + left: left + ( show ? mx * width : 0 ), + top: top + ( show ? my * height : 0 ), + opacity: show ? 0 : 1 + }).animate({ + left: left + ( show ? 0 : mx * width ), + top: top + ( show ? 0 : my * height ), + opacity: show ? 1 : 0 + }, o.duration || 500, o.easing, childComplete ); } + } - // children animate complete: - function childComplete() { - pieces.push( this ); - if ( pieces.length == rows * cells ) { - animComplete(); - } + // children animate complete: + function childComplete() { + pieces.push( this ); + if ( pieces.length == rows * cells ) { + animComplete(); } + } - function animComplete() { - el.css({ - visibility: 'visible' - }); - $( pieces ).remove(); - if ( !show ) { - el.hide(); - } - if ( $.isFunction( o.complete ) ) { - o.complete.apply( el[ 0 ] ); - } - next(); + function animComplete() { + el.css({ + visibility: "visible" + }); + $( pieces ).remove(); + if ( !show ) { + el.hide(); } - }); - + done(); + } }; })(jQuery); diff --git a/ui/jquery.effects.fade.js b/ui/jquery.effects.fade.js index ff1cba5f8..9b79ad3bc 100644 --- a/ui/jquery.effects.fade.js +++ b/ui/jquery.effects.fade.js @@ -12,29 +12,24 @@ */ (function( $, undefined ) { -$.effects.effect.fade = function( o ) { - return this.queue( function( next ) { - var el = $( this ), - mode = $.effects.setMode( el, o.mode || 'toggle' ), - hide = mode === "hide"; +$.effects.effect.fade = function( o, done ) { + var el = $( this ), + mode = $.effects.setMode( el, o.mode || "toggle" ), + hide = mode === "hide"; - el.show(); - el.animate({ - opacity: hide ? 0 : 1 - }, { - queue: false, - duration: o.duration, - easing: o.easing, - complete: function() { - if ( hide ) { - el.hide(); - } - if ( o.complete ) { - o.complete.call( this ); - } - next(); + el.show(); + el.animate({ + opacity: hide ? 0 : 1 + }, { + queue: false, + duration: o.duration, + easing: o.easing, + complete: function() { + if ( hide ) { + el.hide(); } - }); + done(); + } }); }; diff --git a/ui/jquery.effects.fold.js b/ui/jquery.effects.fold.js index 6100c33a1..7c4f583c1 100644 --- a/ui/jquery.effects.fold.js +++ b/ui/jquery.effects.fold.js @@ -12,61 +12,62 @@ */ (function( $, undefined ) { -$.effects.effect.fold = function( o ) { +$.effects.effect.fold = function( o, done ) { - return this.queue( function() { + // Create element + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "height", "width" ], + mode = $.effects.setMode( el, o.mode || "hide" ), + show = mode === "show", + hide = mode === "hide", + size = o.size || 15, + percent = /([0-9]+)%/.exec( size ), + horizFirst = !!o.horizFirst, + widthFirst = show != horizFirst, + ref = widthFirst ? [ "width", "height" ] : [ "height", "width" ], + duration = o.duration / 2, + wrapper, distance, + animation1 = {}, animation2 = {}; - // Create element - var el = $( this ), - props = ['position','top','bottom','left','right','height','width'], - mode = $.effects.setMode(el, o.mode || 'hide'), - size = o.size || 15, - percent = /([0-9]+)%/.exec(size), - horizFirst = !!o.horizFirst, - widthFirst = ((mode == 'show') != horizFirst), - ref = widthFirst ? ['width', 'height'] : ['height', 'width'], - duration = o.duration / 2, - wrapper, distance; + $.effects.save( el, props ); + el.show(); - $.effects.save( el, props ); - el.show(); - - // Create Wrapper - wrapper = $.effects.createWrapper( el ).css({ - overflow: 'hidden' - }); - distance = widthFirst ? - [ wrapper.width(), wrapper.height() ] : - [ wrapper.height(), wrapper.width() ]; - - if ( percent ) { - size = parseInt( percent[ 1 ], 10 ) / 100 * distance[ ( mode == 'hide') ? 0 : 1 ]; - } - mode == 'show' && wrapper.css( horizFirst ? { - height: 0, - width: size - } : { - height: size, - width: 0 - }); + // Create Wrapper + wrapper = $.effects.createWrapper( el ).css({ + overflow: "hidden" + }); + distance = widthFirst ? + [ wrapper.width(), wrapper.height() ] : + [ wrapper.height(), wrapper.width() ]; - // Animation - var animation1 = {}, animation2 = {}; - animation1[ ref[ 0 ] ] = mode == 'show' ? distance[ 0 ] : size; - animation2[ ref[ 1 ] ] = mode == 'show' ? distance[ 1 ] : 0; + if ( percent ) { + size = parseInt( percent[ 1 ], 10 ) / 100 * distance[ hide ? 0 : 1 ]; + } + if ( show ) { + wrapper.css( horizFirst ? { + height: 0, + width: size + } : { + height: size, + width: 0 + }); + } - // Animate - wrapper - .animate( animation1, duration, o.easing ) - .animate( animation2, duration, o.easing, function() { - (mode == 'hide') && el.hide(); - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - jQuery.isFunction(o.complete) && o.complete.apply( el[ 0 ], arguments ); - el.dequeue(); - }); + // Animation + animation1[ ref[ 0 ] ] = show ? distance[ 0 ] : size; + animation2[ ref[ 1 ] ] = show ? distance[ 1 ] : 0; - }); + // Animate + wrapper + .animate( animation1, duration, o.easing ) + .animate( animation2, duration, o.easing, function() { + if ( hide ) { + el.hide(); + } + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); + }); }; diff --git a/ui/jquery.effects.highlight.js b/ui/jquery.effects.highlight.js index cd4f0705a..edde845a3 100644 --- a/ui/jquery.effects.highlight.js +++ b/ui/jquery.effects.highlight.js @@ -12,40 +12,38 @@ */ (function( $, undefined ) { -$.effects.effect.highlight = function( o ) { - return this.queue( function() { - var elem = $( this ), - props = [ 'backgroundImage', 'backgroundColor', 'opacity' ], - mode = $.effects.setMode( elem, o.mode || 'show' ), - animation = { - backgroundColor: elem.css( 'backgroundColor' ) - }; +$.effects.effect.highlight = function( o, done ) { + var elem = $( this ), + props = [ "backgroundImage", "backgroundColor", "opacity" ], + mode = $.effects.setMode( elem, o.mode || "show" ), + animation = { + backgroundColor: elem.css( "backgroundColor" ) + }; - if (mode == 'hide') { - animation.opacity = 0; - } + if (mode === "hide") { + animation.opacity = 0; + } - $.effects.save( elem, props ); - - elem - .show() - .css({ - backgroundImage: 'none', - backgroundColor: o.color || '#ffff99' - }) - .animate( animation, { - queue: false, - duration: o.duration, - easing: o.easing, - complete: function() { - (mode == 'hide' && elem.hide()); - $.effects.restore( elem, props ); - (mode == 'show' && !$.support.opacity && this.style.removeAttribute( 'filter' )); - jQuery.isFunction(o.complete) && o.complete.apply(this, arguments); - elem.dequeue(); + $.effects.save( elem, props ); + + elem + .show() + .css({ + backgroundImage: "none", + backgroundColor: o.color || "#ffff99" + }) + .animate( animation, { + queue: false, + duration: o.duration, + easing: o.easing, + complete: function() { + if ( mode === "hide" ) { + elem.hide(); } - }); - }); + $.effects.restore( elem, props ); + done(); + } + }); }; })(jQuery); diff --git a/ui/jquery.effects.pulsate.js b/ui/jquery.effects.pulsate.js index a0ddf51fd..7d6e9328f 100644 --- a/ui/jquery.effects.pulsate.js +++ b/ui/jquery.effects.pulsate.js @@ -12,56 +12,51 @@ */ (function( $, undefined ) { -$.effects.effect.pulsate = function( o ) { - return this.queue( function( next ) { - var elem = $( this ), - mode = $.effects.setMode( elem, o.mode || "show" ), - show = mode === "show", - hide = mode === "hide", - showhide = ( show || mode === "hide" ), - - // showing or hiding leaves of the "last" animation - anims = ( ( o.times || 5 ) * 2 ) + ( showhide ? 1 : 0 ), - duration = o.duration / anims, - animateTo = 0, - queue = elem.queue(), - queuelen = queue.length, - i; - - if ( show || !elem.is(':visible')) { - elem.css( "opacity", 0 ).show(); - animateTo = 1; - } - - // anims - 1 opacity "toggles" - for ( i = 1; i < anims; i++ ) { - elem.animate({ - opacity: animateTo - }, duration, o.easing ); - animateTo = 1 - animateTo; - } - +$.effects.effect.pulsate = function( o, done ) { + var elem = $( this ), + mode = $.effects.setMode( elem, o.mode || "show" ), + show = mode === "show", + hide = mode === "hide", + showhide = ( show || mode === "hide" ), + + // showing or hiding leaves of the "last" animation + anims = ( ( o.times || 5 ) * 2 ) + ( showhide ? 1 : 0 ), + duration = o.duration / anims, + animateTo = 0, + queue = elem.queue(), + queuelen = queue.length, + i; + + if ( show || !elem.is(":visible")) { + elem.css( "opacity", 0 ).show(); + animateTo = 1; + } + + // anims - 1 opacity "toggles" + for ( i = 1; i < anims; i++ ) { elem.animate({ opacity: animateTo - }, duration, o.easing); + }, duration, o.easing ); + animateTo = 1 - animateTo; + } - elem.queue( function( next ) { - if ( hide ) { - elem.hide(); - } - if ( o.complete ) { - o.complete.apply( this ); - } - next(); - }); + elem.animate({ + opacity: animateTo + }, duration, o.easing); - // We just queued up "anims" animations, we need to put them next in the queue - if ( queuelen > 1) { - queue.splice.apply( queue, - [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) ); + elem.queue(function() { + if ( hide ) { + elem.hide(); } - next(); + done(); }); + + // We just queued up "anims" animations, we need to put them next in the queue + if ( queuelen > 1 ) { + queue.splice.apply( queue, + [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) ); + } + elem.dequeue(); }; })(jQuery); diff --git a/ui/jquery.effects.scale.js b/ui/jquery.effects.scale.js index e00d82497..000fdee28 100644 --- a/ui/jquery.effects.scale.js +++ b/ui/jquery.effects.scale.js @@ -12,249 +12,247 @@ */ (function( $, undefined ) { -$.effects.effect.puff = function( o ) { - return this.queue( function() { - var elem = $( this ), - mode = $.effects.setMode( elem, o.mode || 'hide' ), - percent = parseInt( o.percent, 10 ) || 150, - factor = percent / 100, - original = { - height: elem.height(), - width: elem.width() - }; - - $.extend(o, { - effect: 'scale', - queue: false, - fade: true, - mode: mode, - percent: mode == 'hide' ? percent : 100, - from: mode == 'hide' - ? original - : { - height: original.height * factor, - width: original.width * factor - } - }); +$.effects.effect.puff = function( o, done ) { + var elem = $( this ), + mode = $.effects.setMode( elem, o.mode || "hide" ), + hide = mode === "hide", + percent = parseInt( o.percent, 10 ) || 150, + factor = percent / 100, + original = { + height: elem.height(), + width: elem.width() + }; - elem.effect( o ); + $.extend( o, { + effect: "scale", + queue: false, + fade: true, + mode: mode, + complete: done, + percent: hide ? percent : 100, + from: hide + ? original + : { + height: original.height * factor, + width: original.width * factor + } }); + + elem.effect( o ); }; -$.effects.effect.scale = function( o ) { - - return this[ o.queue === false ? "each" : "queue" ]( function() { - - // Create element - var el = $( this ), - options = $.extend( true, {}, o ), - mode = $.effects.setMode( el, o.mode || 'effect' ), - percent = parseInt( o.percent, 10 ) || ( parseInt( o.percent, 10 ) == 0 ? 0 : ( mode == 'hide' ? 0 : 100 ) ), - direction = o.direction || 'both', - origin = o.origin, - original = { - height: el.height(), - width: el.width(), - outerHeight: el.outerHeight(), - outerWidth: el.outerWidth() - }, - factor = { - y: direction != 'horizontal' ? (percent / 100) : 1, - x: direction != 'vertical' ? (percent / 100) : 1 - }; - - // We are going to pass this effect to the size effect: - options.effect = "size"; - options.queue = false; - - // Set default origin and restore for show/hide - if ( mode != 'effect' ) { - options.origin = origin || ['middle','center']; - options.restore = true; - } +$.effects.effect.scale = function( o, done ) { - options.from = o.from || ( mode == 'show' ? { height: 0, width: 0 } : original ); - options.to = { - height: original.height * factor.y, - width: original.width * factor.x, - outerHeight: original.outerHeight * factor.y, - outerWidth: original.outerWidth * factor.x + // Create element + var el = $( this ), + options = $.extend( true, {}, o ), + mode = $.effects.setMode( el, o.mode || "effect" ), + percent = parseInt( o.percent, 10 ) || ( parseInt( o.percent, 10 ) == 0 ? 0 : ( mode == "hide" ? 0 : 100 ) ), + direction = o.direction || "both", + origin = o.origin, + original = { + height: el.height(), + width: el.width(), + outerHeight: el.outerHeight(), + outerWidth: el.outerWidth() + }, + factor = { + y: direction != "horizontal" ? (percent / 100) : 1, + x: direction != "vertical" ? (percent / 100) : 1 }; - if ( options.fade ) { // Fade option to support puff - if ( mode == 'show' ) { - options.from.opacity = 0; - options.to.opacity = 1; - } - if ( mode == 'hide' ) { - options.from.opacity = 1; - options.to.opacity = 0; - } - }; + // We are going to pass this effect to the size effect: + options.effect = "size"; + options.queue = false; + options.complete = done; + + // Set default origin and restore for show/hide + if ( mode != "effect" ) { + options.origin = origin || ["middle","center"]; + options.restore = true; + } + + options.from = o.from || ( mode == "show" ? { height: 0, width: 0 } : original ); + options.to = { + height: original.height * factor.y, + width: original.width * factor.x, + outerHeight: original.outerHeight * factor.y, + outerWidth: original.outerWidth * factor.x + }; + + if ( options.fade ) { // Fade option to support puff + if ( mode == "show" ) { + options.from.opacity = 0; + options.to.opacity = 1; + } + if ( mode == "hide" ) { + options.from.opacity = 1; + options.to.opacity = 0; + } + }; - // Animate - el.effect(options); - }); + // Animate + el.effect( options ); }; -$.effects.effect.size = function( o ) { - - return this[ o.queue === false ? "each" : "queue" ]( function() { - // Create element - var el = $( this ), - props = [ 'position', 'top', 'bottom', 'left', 'right', 'width', 'height', 'overflow', 'opacity' ], - - // Always restore - props1 = [ 'position', 'top', 'bottom', 'left', 'right', 'overflow', 'opacity' ], - - // Copy for children - props2 = [ 'width', 'height', 'overflow' ], - cProps = [ 'fontSize' ], - vProps = [ 'borderTopWidth', 'borderBottomWidth', 'paddingTop', 'paddingBottom' ], - hProps = [ 'borderLeftWidth', 'borderRightWidth', 'paddingLeft', 'paddingRight' ], - - // Set options - mode = $.effects.setMode( el, o.mode || 'effect' ), - restore = o.restore || mode !== "effect", - scale = o.scale || 'both', - origin = o.origin || [ "middle", "center" ], - original, baseline, factor, - position = el.css( "position" ), - originalVerticalPositioning = el.css( "bottom" ) !== "auto" ? "bottom" : "top"; - originalHorizontalPositioning = el.css( "right" ) !== "auto" ? "right" : "left"; - - if ( mode === "show" ) { - el.show(); +$.effects.effect.size = function( o, done ) { + + // Create element + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "width", "height", "overflow", "opacity" ], + + // Always restore + props1 = [ "position", "top", "bottom", "left", "right", "overflow", "opacity" ], + + // Copy for children + props2 = [ "width", "height", "overflow" ], + cProps = [ "fontSize" ], + vProps = [ "borderTopWidth", "borderBottomWidth", "paddingTop", "paddingBottom" ], + hProps = [ "borderLeftWidth", "borderRightWidth", "paddingLeft", "paddingRight" ], + + // Set options + mode = $.effects.setMode( el, o.mode || "effect" ), + restore = o.restore || mode !== "effect", + scale = o.scale || "both", + origin = o.origin || [ "middle", "center" ], + original, baseline, factor, + position = el.css( "position" ), + originalVerticalPositioning = el.css( "bottom" ) !== "auto" ? "bottom" : "top"; + originalHorizontalPositioning = el.css( "right" ) !== "auto" ? "right" : "left"; + + if ( mode === "show" ) { + el.show(); + } + original = { + height: el.height(), + width: el.width(), + outerHeight: el.outerHeight(), + outerWidth: el.outerWidth() + }; + + el.from = o.from || original; + el.to = o.to || original; + + // Set scaling factor + factor = { + from: { + y: el.from.height / original.height, + x: el.from.width / original.width + }, + to: { + y: el.to.height / original.height, + x: el.to.width / original.width } - original = { - height: el.height(), - width: el.width(), - outerHeight: el.outerHeight(), - outerWidth: el.outerWidth() - }; + }; - el.from = o.from || original; - el.to = o.to || original; + // Scale the css box + if ( scale == "box" || scale == "both" ) { - // Set scaling factor - factor = { - from: { - y: el.from.height / original.height, - x: el.from.width / original.width - }, - to: { - y: el.to.height / original.height, - x: el.to.width / original.width - } + // Vertical props scaling + if ( factor.from.y !== factor.to.y ) { + props = props.concat( vProps ); + el.from = $.effects.setTransition( el, vProps, factor.from.y, el.from ); + el.to = $.effects.setTransition( el, vProps, factor.to.y, el.to ); }; - // Scale the css box - if ( scale == 'box' || scale == 'both' ) { - - // Vertical props scaling - if ( factor.from.y !== factor.to.y ) { - props = props.concat( vProps ); - el.from = $.effects.setTransition( el, vProps, factor.from.y, el.from ); - el.to = $.effects.setTransition( el, vProps, factor.to.y, el.to ); - }; - - // Horizontal props scaling - if ( factor.from.x !== factor.to.x ) { - props = props.concat( hProps ); - el.from = $.effects.setTransition( el, hProps, factor.from.x, el.from ); - el.to = $.effects.setTransition( el, hProps, factor.to.x, el.to ); - }; + // Horizontal props scaling + if ( factor.from.x !== factor.to.x ) { + props = props.concat( hProps ); + el.from = $.effects.setTransition( el, hProps, factor.from.x, el.from ); + el.to = $.effects.setTransition( el, hProps, factor.to.x, el.to ); }; + }; - // Scale the content - if ( scale == 'content' || scale == 'both' ) { + // Scale the content + if ( scale == "content" || scale == "both" ) { - // Vertical props scaling - if ( factor.from.y !== factor.to.y ) { - props = props.concat( cProps ); - el.from = $.effects.setTransition( el, cProps, factor.from.y, el.from ); - el.to = $.effects.setTransition( el, cProps, factor.to.y, el.to ); - }; + // Vertical props scaling + if ( factor.from.y !== factor.to.y ) { + props = props.concat( cProps ); + el.from = $.effects.setTransition( el, cProps, factor.from.y, el.from ); + el.to = $.effects.setTransition( el, cProps, factor.to.y, el.to ); }; - - $.effects.save( el, restore ? props : props1 ); - el.show(); - $.effects.createWrapper( el ); - el.css( 'overflow', 'hidden' ).css( el.from ); - - // Adjust - if (origin) { // Calculate baseline shifts - baseline = $.effects.getBaseline( origin, original ); - el.from.top = ( original.outerHeight - el.outerHeight() ) * baseline.y; - el.from.left = ( original.outerWidth - el.outerWidth() ) * baseline.x; - el.to.top = ( original.outerHeight - el.to.outerHeight ) * baseline.y; - el.to.left = ( original.outerWidth - el.to.outerWidth ) * baseline.x; - } - el.css( el.from ); // set top & left - - // Animate - if ( scale == 'content' || scale == 'both' ) { // Scale the children - - // Add margins/font-size - vProps = vProps.concat([ 'marginTop', 'marginBottom' ]).concat(cProps); - hProps = hProps.concat([ 'marginLeft', 'marginRight' ]); - props2 = props.concat(vProps).concat(hProps); - - el.find( "*[width]" ).each( function(){ - var child = $( this ), - c_original = { - height: child.height(), - width: child.width() - }; - if (restore) $.effects.save(child, props2); - - child.from = { - height: c_original.height * factor.from.y, - width: c_original.width * factor.from.x - }; - child.to = { - height: c_original.height * factor.to.y, - width: c_original.width * factor.to.x + }; + + $.effects.save( el, restore ? props : props1 ); + el.show(); + $.effects.createWrapper( el ); + el.css( "overflow", "hidden" ).css( el.from ); + + // Adjust + if (origin) { // Calculate baseline shifts + baseline = $.effects.getBaseline( origin, original ); + el.from.top = ( original.outerHeight - el.outerHeight() ) * baseline.y; + el.from.left = ( original.outerWidth - el.outerWidth() ) * baseline.x; + el.to.top = ( original.outerHeight - el.to.outerHeight ) * baseline.y; + el.to.left = ( original.outerWidth - el.to.outerWidth ) * baseline.x; + } + el.css( el.from ); // set top & left + + // Animate + if ( scale == "content" || scale == "both" ) { // Scale the children + + // Add margins/font-size + vProps = vProps.concat([ "marginTop", "marginBottom" ]).concat(cProps); + hProps = hProps.concat([ "marginLeft", "marginRight" ]); + props2 = props.concat(vProps).concat(hProps); + + el.find( "*[width]" ).each( function(){ + var child = $( this ), + c_original = { + height: child.height(), + width: child.width() }; + if (restore) $.effects.save(child, props2); + + child.from = { + height: c_original.height * factor.from.y, + width: c_original.width * factor.from.x + }; + child.to = { + height: c_original.height * factor.to.y, + width: c_original.width * factor.to.x + }; - // Vertical props scaling - if ( factor.from.y != factor.to.y ) { - child.from = $.effects.setTransition( child, vProps, factor.from.y, child.from ); - child.to = $.effects.setTransition( child, vProps, factor.to.y, child.to ); - }; + // Vertical props scaling + if ( factor.from.y != factor.to.y ) { + child.from = $.effects.setTransition( child, vProps, factor.from.y, child.from ); + child.to = $.effects.setTransition( child, vProps, factor.to.y, child.to ); + }; - // Horizontal props scaling - if ( factor.from.x != factor.to.x ) { - child.from = $.effects.setTransition( child, hProps, factor.from.x, child.from ); - child.to = $.effects.setTransition( child, hProps, factor.to.x, child.to ); - }; + // Horizontal props scaling + if ( factor.from.x != factor.to.x ) { + child.from = $.effects.setTransition( child, hProps, factor.from.x, child.from ); + child.to = $.effects.setTransition( child, hProps, factor.to.x, child.to ); + }; - // Animate children - child.css( child.from ); - child.animate( child.to, o.duration, o.easing, function() { + // Animate children + child.css( child.from ); + child.animate( child.to, o.duration, o.easing, function() { - // Restore children - if (restore) $.effects.restore( child, props2 ); - }); + // Restore children + if (restore) $.effects.restore( child, props2 ); }); - }; - - // Animate - el.animate( el.to, { - queue: false, - duration: o.duration, - easing: o.easing, - complete: function() { - if ( el.to.opacity === 0 ) { - el.css( 'opacity', el.from.opacity ); - } - if( mode == 'hide' ) { - el.hide(); - } - $.effects.restore( el, restore ? props : props1 ); + }); + }; + + // Animate + el.animate( el.to, { + queue: false, + duration: o.duration, + easing: o.easing, + complete: function() { + if ( el.to.opacity === 0 ) { + el.css( "opacity", el.from.opacity ); + } + if( mode == "hide" ) { + el.hide(); + } + $.effects.restore( el, restore ? props : props1 ); + if ( !restore ) { - // we need to recalculate our positioning based on the new scaling + // we need to calculate our new positioning based on the scaling if ( position === "static" ) { el.css({ position: "relative", @@ -292,13 +290,11 @@ $.effects.effect.size = function( o ) { }); }); } - - $.effects.removeWrapper( el ); - $.isFunction( o.complete ) && o.complete.apply( this, arguments ); // Callback - el.dequeue(); } - }); + $.effects.removeWrapper( el ); + done(); + } }); }; diff --git a/ui/jquery.effects.shake.js b/ui/jquery.effects.shake.js index 52ab331e8..7d83a9bb8 100644 --- a/ui/jquery.effects.shake.js +++ b/ui/jquery.effects.shake.js @@ -12,66 +12,62 @@ */ (function( $, undefined ) { -$.effects.effect.shake = function( o ) { +$.effects.effect.shake = function( o, done ) { - return this.queue( function() { + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "height", "width" ], + mode = $.effects.setMode( el, o.mode || "effect" ), + direction = o.direction || "left", + distance = o.distance || 20, + times = o.times || 3, + anims = times * 2 + 1, + speed = o.duration, + ref = (direction == "up" || direction == "down") ? "top" : "left", + positiveMotion = (direction == "up" || direction == "left"), + animation = {}, + animation1 = {}, + animation2 = {}, + i, - var el = $( this ), - props = [ "position", "top", "bottom", "left", "right", "height", "width" ], - mode = $.effects.setMode( el, o.mode || "effect" ), - direction = o.direction || "left", - distance = o.distance || 20, - times = o.times || 3, - anims = times * 2 + 1, - speed = o.duration, - ref = (direction == "up" || direction == "down") ? "top" : "left", - motion = (direction == "up" || direction == "left") ? "pos" : "neg", - animation = {}, - animation1 = {}, - animation2 = {}, - i, + // we will need to re-assemble the queue to stack our animations in place + queue = el.queue(), + queuelen = queue.length; + - // we will need to re-assemble the queue to stack our animations in place - queue = el.queue(), - queuelen = queue.length; - + $.effects.save( el, props ); + el.show(); + $.effects.createWrapper( el ); - $.effects.save( el, props ); - el.show(); - $.effects.createWrapper( el ); + // Animation + animation[ ref ] = ( positiveMotion ? "-=" : "+=" ) + distance; + animation1[ ref ] = ( positiveMotion ? "+=" : "-=" ) + distance * 2; + animation2[ ref ] = ( positiveMotion ? "-=" : "+=" ) + distance * 2; - // Animation - animation[ ref ] = ( motion == "pos" ? "-=" : "+=" ) + distance; - animation1[ ref ] = ( motion == "pos" ? "+=" : "-=" ) + distance * 2; - animation2[ ref ] = ( motion == "pos" ? "-=" : "+=" ) + distance * 2; + // Animate + el.animate( animation, speed, o.easing ); - // Animate - el.animate( animation, speed, o.easing ); + // Shakes + for ( i = 1; i < times; i++ ) { + el.animate( animation1, speed, o.easing ).animate( animation2, speed, o.easing ); + }; + el + .animate( animation1, speed, o.easing ) + .animate( animation, speed / 2, o.easing ) + .queue(function() { + if ( mode === "hide" ) { + el.hide(); + } + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); + }); - // Shakes - for ( i = 1; i < times; i++ ) { - el.animate( animation1, speed, o.easing ).animate( animation2, speed, o.easing ); - }; - el - .animate( animation1, speed, o.easing ) - .animate( animation, speed / 2, o.easing ) - .queue( function( next ) { - if ( mode === "hide" ) { - el.hide(); - } - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - $.isFunction( o.complete ) && o.complete.apply( this, arguments ); - next(); - }); - - // inject all the animations we just queued to be first in line (after "inprogress") - if ( queuelen > 1) { - queue.splice.apply( queue, - [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) ); - } - el.dequeue(); - }); + // inject all the animations we just queued to be first in line (after "inprogress") + if ( queuelen > 1) { + queue.splice.apply( queue, + [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) ); + } + el.dequeue(); }; diff --git a/ui/jquery.effects.slide.js b/ui/jquery.effects.slide.js index ccb13fa1b..de393c779 100644 --- a/ui/jquery.effects.slide.js +++ b/ui/jquery.effects.slide.js @@ -12,58 +12,54 @@ */ (function( $, undefined ) { -$.effects.effect.slide = function( o ) { +$.effects.effect.slide = function( o, done ) { - return this.queue( function() { + // Create element + var el = $( this ), + props = [ "position", "top", "bottom", "left", "right", "width", "height" ], + mode = $.effects.setMode( el, o.mode || "show" ), + show = mode === "show", + direction = o.direction || "left", + ref = (direction == "up" || direction == "down") ? "top" : "left", + positiveMotion = (direction == "up" || direction == "left"), + distance, + animation = {}, + size; - // Create element - var el = $( this ), - props = [ "position", "top", "bottom", "left", "right", "width", "height" ], - mode = $.effects.setMode( el, o.mode || 'show' ), - direction = o.direction || 'left', - ref = (direction == 'up' || direction == 'down') ? 'top' : 'left', - motion = (direction == 'up' || direction == 'left') ? 'pos' : 'neg', - distance, - animation = {}, - size; - - // Adjust - $.effects.save( el, props ); - el.show(); - distance = o.distance || el[ ref == 'top' ? "outerHeight" : "outerWidth" ]({ - margin: true - }); - - $.effects.createWrapper( el ).css({ - overflow: 'hidden' - }); - - if (mode == 'show') { - el.css( ref, motion == 'pos' ? (isNaN(distance) ? "-" + distance : -distance) : distance ); - } + // Adjust + $.effects.save( el, props ); + el.show(); + distance = o.distance || el[ ref === "top" ? "outerHeight" : "outerWidth" ]({ + margin: true + }); + + $.effects.createWrapper( el ).css({ + overflow: "hidden" + }); + + if ( show ) { + el.css( ref, positiveMotion ? (isNaN(distance) ? "-" + distance : -distance) : distance ); + } - // Animation - animation[ ref ] = ( mode == 'show' ? - (motion == 'pos' ? '+=' : '-=') : - (motion == 'pos' ? '-=' : '+=')) - + distance; + // Animation + animation[ ref ] = ( show ? + ( positiveMotion ? "+=" : "-=") : + ( positiveMotion ? "-=" : "+=")) + + distance; - // Animate - el.animate( animation, { - queue: false, - duration: o.duration, - easing: o.easing, - complete: function() { - if ( mode == 'hide' ) { - el.hide(); - } - $.effects.restore( el, props ); - $.effects.removeWrapper( el ); - $.isFunction(o.complete) && o.complete.apply( this, arguments ); - el.dequeue(); + // Animate + el.animate( animation, { + queue: false, + duration: o.duration, + easing: o.easing, + complete: function() { + if ( mode === "hide" ) { + el.hide(); } - }); - + $.effects.restore( el, props ); + $.effects.removeWrapper( el ); + done(); + } }); }; diff --git a/ui/jquery.effects.transfer.js b/ui/jquery.effects.transfer.js index f0f9d9fd4..1fa291228 100644 --- a/ui/jquery.effects.transfer.js +++ b/ui/jquery.effects.transfer.js @@ -12,39 +12,35 @@ */ (function( $, undefined ) { -$.effects.effect.transfer = function( o ) { - - return this.queue( function() { - var elem = $( this ), - target = $( o.to ), - targetFixed = target.css( "position" ) === "fixed", - body = $("body"), - fixTop = targetFixed ? body.scrollTop() : 0, - fixLeft = targetFixed ? body.scrollLeft() : 0, - endPosition = target.offset(), - animation = { - top: endPosition.top - fixTop , - left: endPosition.left - fixLeft , - height: target.innerHeight(), - width: target.innerWidth() - }, - startPosition = elem.offset(), - transfer = $( '<div class="ui-effects-transfer"></div>' ) - .appendTo( document.body ) - .addClass( o.className ) - .css({ - top: startPosition.top - fixTop , - left: startPosition.left - fixLeft , - height: elem.innerHeight(), - width: elem.innerWidth(), - position: targetFixed ? "fixed" : "absolute" - }) - .animate( animation, o.duration, o.easing, function() { - transfer.remove(); - $.isFunction( o.complete ) && o.complete.apply(elem[0], arguments); - elem.dequeue(); - }); - }); +$.effects.effect.transfer = function( o, done ) { + var elem = $( this ), + target = $( o.to ), + targetFixed = target.css( "position" ) === "fixed", + body = $("body"), + fixTop = targetFixed ? body.scrollTop() : 0, + fixLeft = targetFixed ? body.scrollLeft() : 0, + endPosition = target.offset(), + animation = { + top: endPosition.top - fixTop , + left: endPosition.left - fixLeft , + height: target.innerHeight(), + width: target.innerWidth() + }, + startPosition = elem.offset(), + transfer = $( '<div class="ui-effects-transfer"></div>' ) + .appendTo( document.body ) + .addClass( o.className ) + .css({ + top: startPosition.top - fixTop , + left: startPosition.left - fixLeft , + height: elem.innerHeight(), + width: elem.innerWidth(), + position: targetFixed ? "fixed" : "absolute" + }) + .animate( animation, o.duration, o.easing, function() { + transfer.remove(); + done(); + }); }; })(jQuery); diff --git a/ui/jquery.ui.accordion.js b/ui/jquery.ui.accordion.js index 7602ae9bc..c976e3e69 100644 --- a/ui/jquery.ui.accordion.js +++ b/ui/jquery.ui.accordion.js @@ -12,6 +12,8 @@ * jquery.ui.widget.js */ (function( $, undefined ) { + +var lastToggle = {}; // TODO: use ui-accordion-header-active class and fix styling $.widget( "ui.accordion", { @@ -37,8 +39,6 @@ $.widget( "ui.accordion", { var self = this, options = self.options; - self.running = false; - self.element.addClass( "ui-accordion ui-widget ui-helper-reset" ); self.headers = self.element.find( options.header ) @@ -90,12 +90,11 @@ $.widget( "ui.accordion", { if ( !self.active.length ) { self.headers.eq( 0 ).attr( "tabIndex", 0 ); } else { - self.active - .attr({ - "aria-expanded": "true", - "aria-selected": "true", - tabIndex: 0 - }); + self.active.attr({ + "aria-expanded": "true", + "aria-selected": "true", + tabIndex: 0 + }); } // only need links in tab order for Safari @@ -162,6 +161,13 @@ $.widget( "ui.accordion", { return; } + if ( key === "event" ) { + if ( this.options.event ) { + this.headers.unbind( this.options.event + ".accordion", this._eventHandler ); + } + this._setupEvents( value ); + } + this._super( "_setOption", key, value ); // setting collapsible: false while collapsed; open first panel @@ -169,10 +175,6 @@ $.widget( "ui.accordion", { this._activate( 0 ); } - if ( key === "event" ) { - this._setupEvents( value ); - } - if ( key === "icons" ) { this._destroyIcons(); if ( value ) { @@ -294,7 +296,6 @@ $.widget( "ui.accordion", { }, _setupEvents: function( event ) { - this.headers.unbind( ".accordion" ); if ( event ) { this.headers.bind( event.split( " " ).join( ".accordion " ) + ".accordion", $.proxy( this, "_eventHandler" ) ); @@ -319,8 +320,6 @@ $.widget( "ui.accordion", { event.preventDefault(); if ( options.disabled || - // can't switch during an animation - this.running || // click on active header, but not collapsible ( clickedIsActive && !options.collapsible ) || // allow canceling activation @@ -361,7 +360,6 @@ $.widget( "ui.accordion", { toShow = data.newContent, toHide = data.oldContent; - self.running = true; function complete() { self._completed( data ); } @@ -382,6 +380,8 @@ $.widget( "ui.accordion", { animations[ animation ]({ toShow: toShow, toHide: toHide, + prevShow: lastToggle.toShow, + prevHide: lastToggle.toHide, complete: complete, down: toShow.length && ( !toHide.length || ( toShow.index() < toHide.index() ) ) }, additional ); @@ -412,8 +412,6 @@ $.widget( "ui.accordion", { var toShow = data.newContent, toHide = data.oldContent; - this.running = false; - if ( this.options.heightStyle === "content" ) { toShow.add( toHide ).css({ height: "", @@ -435,6 +433,11 @@ $.widget( "ui.accordion", { $.extend( $.ui.accordion, { animations: { slide: function( options, additions ) { + if ( options.prevShow || options.prevHide ) { + options.prevHide.stop( true, true ); + options.toHide = options.prevShow; + } + var showOverflow = options.toShow.css( "overflow" ), hideOverflow = options.toHide.css( "overflow" ), percentDone = 0, @@ -446,6 +449,9 @@ $.extend( $.ui.accordion, { easing: "swing", duration: 300 }, options, additions ); + + lastToggle = options; + if ( !options.toHide.size() ) { originalWidth = options.toShow[0].style.width; options.toShow @@ -502,10 +508,7 @@ $.extend( $.ui.accordion, { .filter( ":visible" ) .animate( hideProps, { step: function( now, settings ) { - // only calculate the percent when animating height - // IE gets very inconsistent results when animating elements - // with small values, which is common for padding - if ( settings.prop == "height" ) { + if ( settings.prop == "height" || settings.prop == "paddingTop" || settings.prop == "paddingBottom" ) { percentDone = ( settings.end - settings.start === 0 ) ? 0 : ( settings.now - settings.start ) / ( settings.end - settings.start ); } diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js index e39b4649e..59caf625d 100644 --- a/ui/jquery.ui.autocomplete.js +++ b/ui/jquery.ui.autocomplete.js @@ -63,7 +63,7 @@ $.widget( "ui.autocomplete", { "aria-haspopup": "true" }) .bind( "keydown.autocomplete", function( event ) { - if ( self.options.disabled || self.element.attr( "readonly" ) ) { + if ( self.options.disabled || self.element.prop( "readonly" ) ) { suppressKeyPress = true; suppressInput = true; return; diff --git a/ui/jquery.ui.button.js b/ui/jquery.ui.button.js index 482cdc24c..ad17ab0c1 100644 --- a/ui/jquery.ui.button.js +++ b/ui/jquery.ui.button.js @@ -58,7 +58,7 @@ $.widget( "ui.button", { .bind( "reset.button", formResetHandler ); if ( typeof this.options.disabled !== "boolean" ) { - this.options.disabled = this.element.attr( "disabled" ); + this.options.disabled = this.element.prop( "disabled" ); } this._determineButtonType(); @@ -155,7 +155,7 @@ $.widget( "ui.button", { return false; } $( this ).addClass( "ui-state-active" ); - self.buttonElement.attr( "aria-pressed", true ); + self.buttonElement.attr( "aria-pressed", "true" ); var radio = self.element[ 0 ]; radioGroup( radio ) @@ -164,7 +164,7 @@ $.widget( "ui.button", { return $( this ).button( "widget" )[ 0 ]; }) .removeClass( "ui-state-active" ) - .attr( "aria-pressed", false ); + .attr( "aria-pressed", "false" ); }); } else { this.buttonElement @@ -244,7 +244,7 @@ $.widget( "ui.button", { if ( checked ) { this.buttonElement.addClass( "ui-state-active" ); } - this.buttonElement.attr( "aria-pressed", checked ); + this.buttonElement.prop( "aria-pressed", checked ); } else { this.buttonElement = this.element; } @@ -272,9 +272,9 @@ $.widget( "ui.button", { this._super( "_setOption", key, value ); if ( key === "disabled" ) { if ( value ) { - this.element.attr( "disabled", true ); + this.element.prop( "disabled", true ); } else { - this.element.removeAttr( "disabled" ); + this.element.prop( "disabled", false ); } return; } @@ -291,22 +291,22 @@ $.widget( "ui.button", { if ( $( this ).is( ":checked" ) ) { $( this ).button( "widget" ) .addClass( "ui-state-active" ) - .attr( "aria-pressed", true ); + .attr( "aria-pressed", "true" ); } else { $( this ).button( "widget" ) .removeClass( "ui-state-active" ) - .attr( "aria-pressed", false ); + .attr( "aria-pressed", "false" ); } }); } else if ( this.type === "checkbox" ) { if ( this.element.is( ":checked" ) ) { this.buttonElement .addClass( "ui-state-active" ) - .attr( "aria-pressed", true ); + .attr( "aria-pressed", "true" ); } else { this.buttonElement .removeClass( "ui-state-active" ) - .attr( "aria-pressed", false ); + .attr( "aria-pressed", "false" ); } } }, diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index ee0a86338..9f7f0b6e1 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -285,7 +285,9 @@ $.extend(Datepicker.prototype, { if( inst.settings.disabled ) { this._disableDatepicker( target ); } - inst.dpDiv.show(); + // Set display:block in place of inst.dpDiv.show() which won't work on disconnected elements + // http://bugs.jqueryui.com/ticket/7552 - A Datepicker created on a detached div has zero height + inst.dpDiv.css( "display", "block" ); }, /* Pop-up the date picker in a "dialog" box. @@ -377,7 +379,7 @@ $.extend(Datepicker.prototype, { var inline = $target.children('.' + this._inlineClass); inline.children().removeClass('ui-state-disabled'); inline.find("select.ui-datepicker-month, select.ui-datepicker-year"). - removeAttr("disabled"); + prop("disabled", false); } this._disabledInputs = $.map(this._disabledInputs, function(value) { return (value == target ? null : value); }); // delete entry @@ -402,7 +404,7 @@ $.extend(Datepicker.prototype, { var inline = $target.children('.' + this._inlineClass); inline.children().addClass('ui-state-disabled'); inline.find("select.ui-datepicker-month, select.ui-datepicker-year"). - attr("disabled", "disabled"); + prop("disabled", true); } this._disabledInputs = $.map(this._disabledInputs, function(value) { return (value == target ? null : value); }); // delete entry @@ -529,6 +531,13 @@ $.extend(Datepicker.prototype, { $.datepicker._currentClass + ')', inst.dpDiv); if (sel[0]) $.datepicker._selectDay(event.target, inst.selectedMonth, inst.selectedYear, sel[0]); + var onSelect = $.datepicker._get(inst, 'onSelect'); + if (onSelect) { + var dateStr = $.datepicker._formatDate(inst); + + // trigger custom callback + onSelect.apply((inst.input ? inst.input[0] : null), [dateStr, inst]); + } else $.datepicker._hideDatepicker(); return false; // don't submit the form @@ -932,8 +941,7 @@ $.extend(Datepicker.prototype, { else { this._hideDatepicker(); this._lastInput = inst.input[0]; - if (typeof(inst.input[0]) != 'object') - inst.input.focus(); // restore focus + inst.input.focus(); // restore focus this._lastInput = null; } }, @@ -1096,7 +1104,10 @@ $.extend(Datepicker.prototype, { } } if (iValue < value.length){ - throw "Extra/unparsed characters found in date: " + value.substring(iValue); + var extra = value.substr(iValue); + if (!/^\s+/.test(extra)) { + throw "Extra/unparsed characters found in date: " + extra; + } } if (year == -1) year = new Date().getFullYear(); @@ -1393,6 +1404,14 @@ $.extend(Datepicker.prototype, { if (inst.input) { inst.input.val(clear ? '' : this._formatDate(inst)); } + + var onSelect = this._get(inst, 'onSelect'); + if (onSelect) { + var dateStr = this._formatDate(inst); + + // trigger custom callback + onSelect.apply((inst.input ? inst.input[0] : null), [dateStr, inst]); + } }, /* Retrieve the date(s) directly. */ diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index 0eba39842..493ed07e6 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -108,7 +108,8 @@ $.widget("ui.dialog", { }) .mousedown(function( event ) { self.moveToTop( false, event ); - }), + }) + .appendTo( "body" ), uiDialogContent = self.element .show() @@ -155,8 +156,6 @@ $.widget("ui.dialog", { self._createButtons( options.buttons ); self._isOpen = false; - uiDialog.appendTo( document.body ); - if ( $.fn.bgiframe ) { uiDialog.bgiframe(); } @@ -266,8 +265,8 @@ $.widget("ui.dialog", { // Opera 9.5+ resets when parent z-index is changed. // http://bugs.jqueryui.com/ticket/3193 saveScroll = { - scrollTop: self.element.attr( "scrollTop" ), - scrollLeft: self.element.attr( "scrollLeft" ) + scrollTop: self.element.scrollTop(), + scrollLeft: self.element.scrollLeft() }; $.ui.dialog.maxZ += 1; self.uiDialog.css( "z-index", $.ui.dialog.maxZ ); diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index 7dd1a9ce0..c55ae75c9 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -58,6 +58,8 @@ $.widget( "ui.menu", { } var target = $( event.target ).closest( ".ui-menu-item" ); if ( target.length ) { + //Remove ui-state-active class from siblings of the newly focused menu item to avoid a jump caused by adjacent elements both having a class with a border + target.siblings().children( ".ui-state-active" ).removeClass( "ui-state-active" ); self.focus( event, target ); } }) @@ -69,6 +71,18 @@ $.widget( "ui.menu", { if ( target.length ) { self.blur( event ); } + }) + .bind( "focus.menu", function( event ) { + if ( self.options.disabled ) { + return; + } + self.focus( event, $( event.target ).children( ".ui-menu-item:first" ) ); + }) + .bind( "blur.menu", function( event ) { + if ( self.options.disabled ) { + return; + } + self.collapseAll( event ); }); this.refresh(); @@ -87,6 +101,16 @@ $.widget( "ui.menu", { event.preventDefault(); event.stopImmediatePropagation(); break; + case $.ui.keyCode.HOME: + self._move( "first", "first", event ); + event.preventDefault(); + event.stopImmediatePropagation(); + break; + case $.ui.keyCode.END: + self._move( "last", "last", event ); + event.preventDefault(); + event.stopImmediatePropagation(); + break; case $.ui.keyCode.UP: self.previous( event ); event.preventDefault(); @@ -98,20 +122,20 @@ $.widget( "ui.menu", { event.stopImmediatePropagation(); break; case $.ui.keyCode.LEFT: - if (self.left( event )) { + if (self.collapse( event )) { event.stopImmediatePropagation(); } event.preventDefault(); break; case $.ui.keyCode.RIGHT: - if (self.right( event )) { + if (self.expand( event )) { event.stopImmediatePropagation(); } event.preventDefault(); break; case $.ui.keyCode.ENTER: if ( self.active.children( "a[aria-haspopup='true']" ).length ) { - if ( self.right( event ) ) { + if ( self.expand( event ) ) { event.stopImmediatePropagation(); } } @@ -122,7 +146,7 @@ $.widget( "ui.menu", { event.preventDefault(); break; case $.ui.keyCode.ESCAPE: - if ( self.left( event ) ) { + if ( self.collapse( event ) ) { event.stopImmediatePropagation(); } event.preventDefault(); @@ -170,6 +194,14 @@ $.widget( "ui.menu", { } } }); + + this._bind( document, { + click: function( event ) { + if ( !$( event.target ).closest( ".ui-menu" ).length ) { + this.collapseAll( event ); + } + } + }); }, _destroy: function() { @@ -239,20 +271,20 @@ $.widget( "ui.menu", { var nested, self = this; - this.blur(); + this.blur( event ); if ( this._hasScroll() ) { - var borderTop = parseFloat( $.curCSS( this.element[0], "borderTopWidth", true ) ) || 0, - paddingTop = parseFloat( $.curCSS( this.element[0], "paddingTop", true ) ) || 0, - offset = item.offset().top - this.element.offset().top - borderTop - paddingTop, - scroll = this.element.scrollTop(), - elementHeight = this.element.height(), + var borderTop = parseFloat( $.curCSS( this.activeMenu[0], "borderTopWidth", true ) ) || 0, + paddingTop = parseFloat( $.curCSS( this.activeMenu[0], "paddingTop", true ) ) || 0, + offset = item.offset().top - this.activeMenu.offset().top - borderTop - paddingTop, + scroll = this.activeMenu.scrollTop(), + elementHeight = this.activeMenu.height(), itemHeight = item.height(); if ( offset < 0 ) { - this.element.scrollTop( scroll + offset ); + this.activeMenu.scrollTop( scroll + offset ); } else if ( offset + itemHeight > elementHeight ) { - this.element.scrollTop( scroll + offset - elementHeight + itemHeight ); + this.activeMenu.scrollTop( scroll + offset - elementHeight + itemHeight ); } } @@ -287,10 +319,19 @@ $.widget( "ui.menu", { this.active.children( "a" ).removeClass( "ui-state-focus" ); this.active = null; + + this._trigger( "blur", event, { item: this.active } ); }, _startOpening: function( submenu ) { clearTimeout( this.timer ); + + // Don't open if already open fixes a Firefox bug that caused a .5 pixel + // shift in the submenu position when mousing over the carat icon + if ( submenu.attr( "aria-hidden" ) !== "true" ) { + return; + } + var self = this; self.timer = setTimeout( function() { self._close(); @@ -319,7 +360,7 @@ $.widget( "ui.menu", { .position( position ); }, - closeAll: function() { + collapseAll: function( event ) { this.element .find( "ul" ) .hide() @@ -329,7 +370,7 @@ $.widget( "ui.menu", { .find( "a.ui-state-active" ) .removeClass( "ui-state-active" ); - this.blur(); + this.blur( event ); this.activeMenu = this.element; }, @@ -344,7 +385,7 @@ $.widget( "ui.menu", { .removeClass( "ui-state-active" ); }, - left: function( event ) { + collapse: function( event ) { var newItem = this.active && this.active.parents("li:not(.ui-menubar-item)").first(); if ( newItem && newItem.length ) { this.active.parent() @@ -356,7 +397,7 @@ $.widget( "ui.menu", { } }, - right: function( event ) { + expand: function( event ) { var self = this, newItem = this.active && this.active.children("ul").children("li").first(); @@ -372,11 +413,11 @@ $.widget( "ui.menu", { }, next: function(event) { - this._move( "next", ".ui-menu-item", "first", event ); + this._move( "next", "first", event ); }, previous: function(event) { - this._move( "prev", ".ui-menu-item", "last", event ); + this._move( "prev", "last", event ); }, first: function() { @@ -387,25 +428,36 @@ $.widget( "ui.menu", { return this.active && !this.active.nextAll( ".ui-menu-item" ).length; }, - _move: function( direction, edge, filter, event ) { + _move: function( direction, filter, event ) { if ( !this.active ) { - this.focus( event, this.activeMenu.children( edge )[ filter ]() ); + this.focus( event, this.activeMenu.children( ".ui-menu-item" )[ filter ]() ); return; } - var next = this.active[ direction + "All" ]( ".ui-menu-item" ).eq( 0 ); + + var next; + if ( direction === "first" || direction === "last" ) { + next = this.active[ direction === "first" ? "prevAll" : "nextAll" ]( ".ui-menu-item" ).eq( -1 ); + } else { + next = this.active[ direction + "All" ]( ".ui-menu-item" ).eq( 0 ); + } + if ( next.length ) { this.focus( event, next ); } else { - this.focus( event, this.activeMenu.children( edge )[ filter ]() ); + this.focus( event, this.activeMenu.children( ".ui-menu-item" )[ filter ]() ); } }, nextPage: function( event ) { if ( this._hasScroll() ) { - if ( !this.active || this.last() ) { + if ( !this.active ) { this.focus( event, this.activeMenu.children( ".ui-menu-item" ).first() ); return; } + if ( this.last() ) { + return; + } + var base = this.active.offset().top, height = this.element.height(), result; @@ -417,14 +469,17 @@ $.widget( "ui.menu", { this.focus( event, result ); } else { this.focus( event, this.activeMenu.children( ".ui-menu-item" ) - [ !this.active || this.last() ? "first" : "last" ]() ); + [ !this.active ? "first" : "last" ]() ); } }, previousPage: function( event ) { if ( this._hasScroll() ) { - if ( !this.active || this.first() ) { - this.focus( event, this.activeMenu.children( ".ui-menu-item" ).last() ); + if ( !this.active ) { + this.focus( event, this.activeMenu.children( ".ui-menu-item" ).first() ); + return; + } + if ( this.first() ) { return; } @@ -438,22 +493,20 @@ $.widget( "ui.menu", { this.focus( event, result ); } else { - this.focus( event, this.activeMenu.children( ".ui-menu-item" ) - [ !this.active || this.first() ? ":last" : ":first" ]() ); + this.focus( event, this.activeMenu.children( ".ui-menu-item" ).first() ); } }, _hasScroll: function() { - // TODO: just use .prop() when we drop support for jQuery <1.6 - return this.element.height() < this.element[ $.fn.prop ? "prop" : "attr" ]( "scrollHeight" ); + return this.element.height() < this.element.prop( "scrollHeight" ); }, select: function( event ) { - // save active reference before closeAll triggers blur + // save active reference before collapseAll triggers blur var ui = { item: this.active }; - this.closeAll(); + this.collapseAll( event ); this._trigger( "select", event, ui ); } }); diff --git a/ui/jquery.ui.menubar.js b/ui/jquery.ui.menubar.js index 39e75924e..9af3aa080 100644 --- a/ui/jquery.ui.menubar.js +++ b/ui/jquery.ui.menubar.js @@ -20,6 +20,7 @@ $.widget( "ui.menubar", { version: "@VERSION", options: { + autoExpand: false, buttons: false, menuIcon: false, position: { @@ -48,15 +49,17 @@ $.widget( "ui.menubar", { }, select: function( event, ui ) { ui.item.parents( "ul.ui-menu:last" ).hide(); - that._trigger( "select", event, ui ); that._close(); // TODO what is this targetting? there's probably a better way to access it $(event.target).prev().focus(); + that._trigger( "select", event, ui ); } }) .hide() - .attr( "aria-hidden", "true" ) - .attr( "aria-expanded", "false" ) + .attr({ + "aria-hidden": "true", + "aria-expanded": "false" + }) .bind( "keydown.menubar", function( event ) { var menu = $( this ); if ( menu.is( ":hidden" ) ) @@ -89,7 +92,11 @@ $.widget( "ui.menubar", { that._close(); return; } - if ( ( that.open && event.type == "mouseenter" ) || event.type == "click" ) { + if ( ( that.open && event.type == "mouseenter" ) || event.type == "click" || that.options.autoExpand ) { + if( that.options.autoExpand ) { + clearTimeout( that.timer ); + } + that._open( event, menu ); } }) @@ -116,6 +123,22 @@ $.widget( "ui.menubar", { .attr( "aria-haspopup", "true" ) .wrapInner( "<span class='ui-button-text'></span>" ); + if ( that.options.autoExpand ) { + input.bind( "mouseleave.menubar", function( event ) { + that.timer = setTimeout( function() { + that._close(); + }, 150 ); + }); + menu.bind( "mouseleave.menubar", function( event ) { + that.timer = setTimeout( function() { + that._close(); + }, 150 ); + }) + .bind( "mouseenter.menubar", function( event ) { + clearTimeout( that.timer ); + }); + } + // TODO review if these options are a good choice, maybe they can be merged if ( that.options.menuIcon ) { input.addClass( "ui-state-default" ).append( "<span class='ui-button-icon-secondary ui-icon ui-icon-triangle-1-s'></span>" ); @@ -130,7 +153,7 @@ $.widget( "ui.menubar", { }); that._bind( { keydown: function( event ) { - if ( event.keyCode == $.ui.keyCode.ESCAPE && that.active && that.active.menu( "left", event ) !== true ) { + if ( event.keyCode == $.ui.keyCode.ESCAPE && that.active && that.active.menu( "collapse", event ) !== true ) { var active = that.active; that.active.blur(); that._close( event ); @@ -151,19 +174,19 @@ $.widget( "ui.menubar", { _destroy : function() { var items = this.element.children( "li" ) .removeClass( "ui-menubar-item" ) - .removeAttr( "role", "presentation" ) + .removeAttr( "role" ) .children( "button, a" ); this.element .removeClass( "ui-menubar ui-widget-header ui-helper-clearfix" ) - .removeAttr( "role", "menubar" ) + .removeAttr( "role" ) .unbind( ".menubar" ); items .unbind( ".menubar" ) .removeClass( "ui-button ui-widget ui-button-text-only ui-menubar-link ui-state-default" ) - .removeAttr( "role", "menuitem" ) - .removeAttr( "aria-haspopup", "true" ) + .removeAttr( "role" ) + .removeAttr( "aria-haspopup" ) // TODO unwrap? .children( "span.ui-button-text" ).each(function( i, e ) { var item = $( this ); @@ -175,8 +198,8 @@ $.widget( "ui.menubar", { this.element.find( ":ui-menu" ) .menu( "destroy" ) .show() - .removeAttr( "aria-hidden", "true" ) - .removeAttr( "aria-expanded", "false" ) + .removeAttr( "aria-hidden" ) + .removeAttr( "aria-expanded" ) .removeAttr( "tabindex" ) .unbind( ".menubar" ); }, @@ -185,10 +208,12 @@ $.widget( "ui.menubar", { if ( !this.active || !this.active.length ) return; this.active - .menu( "closeAll" ) + .menu( "collapseAll" ) .hide() - .attr( "aria-hidden", "true" ) - .attr( "aria-expanded", "false" ); + .attr({ + "aria-hidden": "true", + "aria-expanded": "false" + }); this.active .prev() .removeClass( "ui-state-active" ) @@ -205,10 +230,12 @@ $.widget( "ui.menubar", { // TODO refactor, almost the same as _close above, but don't remove tabIndex if ( this.active ) { this.active - .menu( "closeAll" ) + .menu( "collapseAll" ) .hide() - .attr( "aria-hidden", "true" ) - .attr( "aria-expanded", "false" ); + .attr({ + "aria-hidden": "true", + "aria-expanded": "false" + }); this.active .prev() .removeClass( "ui-state-active" ); diff --git a/ui/jquery.ui.popup.js b/ui/jquery.ui.popup.js index d455346dc..508209a55 100644 --- a/ui/jquery.ui.popup.js +++ b/ui/jquery.ui.popup.js @@ -41,7 +41,7 @@ $.widget( "ui.popup", { } this.options.trigger - .attr( "aria-haspopup", true ) + .attr( "aria-haspopup", "true" ) .attr( "aria-owns", this.element.attr( "id" ) ); this.element @@ -163,8 +163,8 @@ $.widget( "ui.popup", { this.element .show() - .attr( "aria-hidden", false ) - .attr( "aria-expanded", true ) + .attr( "aria-hidden", "false" ) + .attr( "aria-expanded", "true" ) .position( position ); if (this.element.is( ":ui-menu" )) { //popup is a menu @@ -194,8 +194,8 @@ $.widget( "ui.popup", { close: function( event ) { this.element .hide() - .attr( "aria-hidden", true ) - .attr( "aria-expanded", false ); + .attr( "aria-hidden", "true" ) + .attr( "aria-expanded", "false" ); this.options.trigger.attr( "tabindex" , 0 ); if ( this.removeTabIndex ) { diff --git a/ui/jquery.ui.position.js b/ui/jquery.ui.position.js index 3bae0d010..23a98b491 100644 --- a/ui/jquery.ui.position.js +++ b/ui/jquery.ui.position.js @@ -204,7 +204,8 @@ $.fn.position = function( options ) { offset: [ atOffset[ 0 ] + myOffset[ 0 ], atOffset [ 1 ] + myOffset[ 1 ] ], my: options.my, at: options.at, - within: within + within: within, + elem : elem }); } }); @@ -265,6 +266,9 @@ $.ui.position = { return; } + data.elem + .removeClass( "ui-flipped-left ui-flipped-right" ); + var within = data.within, win = $( window ), isWindow = $.isWindow( data.within[0] ), @@ -283,6 +287,10 @@ $.ui.position = { -data.targetWidth, offset = -2 * data.offset[ 0 ]; if ( overLeft < 0 || overRight > 0 ) { + + data.elem + .addClass( "ui-flipped-" + ( overLeft < 0 ? "right" : "left" ) ); + position.left += myOffset + atOffset + offset; } }, @@ -290,6 +298,10 @@ $.ui.position = { if ( data.at[ 1 ] === center ) { return; } + + data.elem + .removeClass( "ui-flipped-top ui-flipped-bottom" ); + var within = data.within, win = $( window ), isWindow = $.isWindow( data.within[0] ), @@ -308,6 +320,10 @@ $.ui.position = { -data.targetHeight, offset = -2 * data.offset[ 1 ]; if ( overTop < 0 || overBottom > 0 ) { + + data.elem + .addClass( "ui-flipped-" + ( overTop < 0 ? "bottom" : "top" ) ); + position.top += myOffset + atOffset + offset; } } diff --git a/ui/jquery.ui.slider.js b/ui/jquery.ui.slider.js index 978155370..9c5d21ffb 100644 --- a/ui/jquery.ui.slider.js +++ b/ui/jquery.ui.slider.js @@ -502,10 +502,10 @@ $.widget( "ui.slider", $.ui.mouse, { if ( value ) { this.handles.filter( ".ui-state-focus" ).blur(); this.handles.removeClass( "ui-state-hover" ); - this.handles.attr( "disabled", "disabled" ); + this.handles.prop( "disabled", true ); this.element.addClass( "ui-disabled" ); } else { - this.handles.removeAttr( "disabled" ); + this.handles.prop( "disabled", false ); this.element.removeClass( "ui-disabled" ); } break; diff --git a/ui/jquery.ui.spinner.js b/ui/jquery.ui.spinner.js index 951b336ed..b03c59709 100644 --- a/ui/jquery.ui.spinner.js +++ b/ui/jquery.ui.spinner.js @@ -302,10 +302,10 @@ $.widget( "ui.spinner", { if ( key === "disabled" ) { if ( value ) { - this.element.attr( "disabled", true ); + this.element.prop( "disabled", true ); this.buttons.button( "disable" ); } else { - this.element.removeAttr( "disabled" ); + this.element.prop( "disabled", false ); this.buttons.button( "enable" ); } } @@ -343,7 +343,7 @@ $.widget( "ui.spinner", { destroy: function() { this.element .removeClass( "ui-spinner-input" ) - .removeAttr( "disabled" ) + .prop( "disabled", false ) .removeAttr( "autocomplete" ) .removeAttr( "role" ) .removeAttr( "aria-valuemin" ) diff --git a/ui/jquery.ui.tooltip.js b/ui/jquery.ui.tooltip.js index f19061bc3..5e32459fc 100644 --- a/ui/jquery.ui.tooltip.js +++ b/ui/jquery.ui.tooltip.js @@ -148,7 +148,14 @@ $.widget( "ui.tooltip", { this._bind( target, { mouseleave: "close", - blur: "close" + blur: "close", + keyup: function( event ) { + if ( event.keyCode == $.ui.keyCode.ESCAPE ) { + var fakeEvent = $.Event(event); + fakeEvent.currentTarget = target[0]; + this.close( fakeEvent, true ); + } + } }); }, @@ -176,7 +183,7 @@ $.widget( "ui.tooltip", { delete that.tooltips[ this.id ]; }); - target.unbind( "mouseleave.tooltip blur.tooltip" ); + target.unbind( "mouseleave.tooltip blur.tooltip keyup.tooltip" ); this._trigger( "close", event, { tooltip: tooltip } ); }, |