mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-11-21 11:04:24 +00:00
Merge branch 'master' into selectmenu
This commit is contained in:
commit
c59fbbaad7
42
AUTHORS.txt
42
AUTHORS.txt
@ -4,14 +4,14 @@ A list of current team members is available at http://jqueryui.com/about
|
|||||||
Paul Bakaus <paul.bakaus@googlemail.com>
|
Paul Bakaus <paul.bakaus@googlemail.com>
|
||||||
Richard Worth <rdworth@gmail.com>
|
Richard Worth <rdworth@gmail.com>
|
||||||
Yehuda Katz <wycats@gmail.com>
|
Yehuda Katz <wycats@gmail.com>
|
||||||
Sean Catchpole <littlecooldude@gmail.com>
|
Sean Catchpole <sean@sunsean.com>
|
||||||
John Resig <jeresig@gmail.com>
|
John Resig <jeresig@gmail.com>
|
||||||
Tane Piper <tane@tanepiper.com>
|
Tane Piper <piper.tane@gmail.com>
|
||||||
Dmitri Gaskin <dmitrig01@gmail.com>
|
Dmitri Gaskin <dmitrig01@gmail.com>
|
||||||
Klaus Hartl <klaus.hartl@googlemail.com>
|
Klaus Hartl <klaus.hartl@googlemail.com>
|
||||||
Stefan Petre <stefan.petre@gmail.com>
|
Stefan Petre <stefan.petre@gmail.com>
|
||||||
Gilles van den Hoven <gilles@webunity.nl>
|
Gilles van den Hoven <gilles@webunity.nl>
|
||||||
Micheil Smith <micheil@brandedcode.com>
|
Micheil Bryan Smith <micheil@brandedcode.com>
|
||||||
Jörn Zaefferer <joern.zaefferer@gmail.com>
|
Jörn Zaefferer <joern.zaefferer@gmail.com>
|
||||||
Marc Grabanski <m@marcgrabanski.com>
|
Marc Grabanski <m@marcgrabanski.com>
|
||||||
Keith Wood <kbwood.au@gmail.com>
|
Keith Wood <kbwood.au@gmail.com>
|
||||||
@ -81,9 +81,9 @@ Khaled AlHourani <me@khaledalhourani.com>
|
|||||||
Marian Rudzynski <mr@impaled.org>
|
Marian Rudzynski <mr@impaled.org>
|
||||||
Jean-Francois Remy <jfremy@virtuoz.com>
|
Jean-Francois Remy <jfremy@virtuoz.com>
|
||||||
Doug Blood <dougblood@gmail.com>
|
Doug Blood <dougblood@gmail.com>
|
||||||
Filippo Cavallarin <poplix@papuasia.org>
|
Filippo Cavallarin <filippo.cavallarin@codseq.it>
|
||||||
Heiko Henning <h.henning@educa.ch>
|
Heiko Henning <h.henning@educa.ch>
|
||||||
Aliaxandr Rahalevich <saksmlz@gmail.com>
|
Aliaksandr Rahalevich <saksmlz@gmail.com>
|
||||||
Mario Visic <mario@mariovisic.com>
|
Mario Visic <mario@mariovisic.com>
|
||||||
Xavi Ramirez <xavi.rmz@gmail.com>
|
Xavi Ramirez <xavi.rmz@gmail.com>
|
||||||
Max Schnur <max.schnur@gmail.com>
|
Max Schnur <max.schnur@gmail.com>
|
||||||
@ -92,7 +92,7 @@ Corey Frang <gnarf@gnarf.net>
|
|||||||
Aaron Peterson <aaronp123@yahoo.com>
|
Aaron Peterson <aaronp123@yahoo.com>
|
||||||
Ivan Peters <ivan@ivanpeters.com>
|
Ivan Peters <ivan@ivanpeters.com>
|
||||||
Mohamed Cherif Bouchelaghem <cherifbouchelaghem@yahoo.fr>
|
Mohamed Cherif Bouchelaghem <cherifbouchelaghem@yahoo.fr>
|
||||||
Marcos Sousa <marcos.sousa@corp.globo.com>
|
Marcos Sousa <falecomigo@marcossousa.com>
|
||||||
Michael DellaNoce <mdellanoce@mailtrust.com>
|
Michael DellaNoce <mdellanoce@mailtrust.com>
|
||||||
George Marshall <echosx@gmail.com>
|
George Marshall <echosx@gmail.com>
|
||||||
Tobias Brunner <tobias@strongswan.org>
|
Tobias Brunner <tobias@strongswan.org>
|
||||||
@ -114,8 +114,8 @@ Hans Hillen <hans.hillen@gmail.com>
|
|||||||
Mark Johnson <virgofx@live.com>
|
Mark Johnson <virgofx@live.com>
|
||||||
Trey Hunner <treyhunner@gmail.com>
|
Trey Hunner <treyhunner@gmail.com>
|
||||||
Shane Whittet <whittet@gmail.com>
|
Shane Whittet <whittet@gmail.com>
|
||||||
Edward Faulkner <ef@alum.mit.edu>
|
Edward A Faulkner <ef@alum.mit.edu>
|
||||||
Adam Baratz <adam.baratz@gmail.com>
|
Adam Baratz <adam@adambaratz.com>
|
||||||
Kato Kazuyoshi <kato.kazuyoshi@gmail.com>
|
Kato Kazuyoshi <kato.kazuyoshi@gmail.com>
|
||||||
Eike Send <eike.send@gmail.com>
|
Eike Send <eike.send@gmail.com>
|
||||||
Kris Borchers <kris.borchers@gmail.com>
|
Kris Borchers <kris.borchers@gmail.com>
|
||||||
@ -125,27 +125,27 @@ Carson McDonald <carson@ioncannon.net>
|
|||||||
Jason Davies <jason@jasondavies.com>
|
Jason Davies <jason@jasondavies.com>
|
||||||
Garrison Locke <gplocke@gmail.com>
|
Garrison Locke <gplocke@gmail.com>
|
||||||
David Murdoch <musicisair@yahoo.com>
|
David Murdoch <musicisair@yahoo.com>
|
||||||
Ben Boyle <benjamins.boyle@gmail.com>
|
Benjamin Scott Boyle <benjamins.boyle@gmail.com>
|
||||||
Jesse Baird <jebaird@gmail.com>
|
Jesse Baird <jebaird@gmail.com>
|
||||||
Jonathan Vingiano <jvingiano@gmail.com>
|
Jonathan Vingiano <jvingiano@gmail.com>
|
||||||
Dylan Just <dev@ephox.com>
|
Dylan Just <dev@ephox.com>
|
||||||
Tomy Kaira <tomykaira@gmail.com>
|
Hiroshi Tomita <tomykaira@gmail.com>
|
||||||
Glenn Goodrich <glenn.goodrich@gmail.com>
|
Glenn Goodrich <glenn.goodrich@gmail.com>
|
||||||
Ashek Elahi <mail.ashek@gmail.com>
|
Tarafder Ashek-E-Elahi <mail.ashek@gmail.com>
|
||||||
Ryan Neufeld <ryan@neufeldmail.com>
|
Ryan Neufeld <ryan@neufeldmail.com>
|
||||||
Marc Neuwirth <marc.neuwirth@gmail.com>
|
Marc Neuwirth <marc.neuwirth@gmail.com>
|
||||||
Philip Graham <philip.robert.graham@gmail.com>
|
Philip Graham <philip.robert.graham@gmail.com>
|
||||||
Benjamin Sterling <benjamin.sterling@kenzomedia.com>
|
Benjamin Sterling <benjamin.sterling@kenzomedia.com>
|
||||||
Wesley Walser <wwalser@atlassian.com>
|
Wesley Walser <waw325@gmail.com>
|
||||||
Kouhei Sutou <kou@clear-code.com>
|
Kouhei Sutou <kou@clear-code.com>
|
||||||
Karl Kirch <karl.ctr.kirch@faa.gov>
|
Karl Kirch <karlkrch@gmail.com>
|
||||||
Chris Kelly <ckdake@ckdake.com>
|
Chris Kelly <ckdake@ckdake.com>
|
||||||
Jay Oster <jay@loyalize.com>
|
Jay Oster <jay@loyalize.com>
|
||||||
Alex Polomoshnov <alex.polomoshnov@gmail.com>
|
Alexander Polomoshnov <alex.polomoshnov@gmail.com>
|
||||||
David Leal <dgleal@gmail.com>
|
David Leal <dgleal@gmail.com>
|
||||||
igor milla <igor.fsp.milla@gmail.com>
|
Igor Milla <igor.fsp.milla@gmail.com>
|
||||||
Dave Methvin <dave.methvin@gmail.com>
|
Dave Methvin <dave.methvin@gmail.com>
|
||||||
Florian Gutmann <blackfeet@gmx.at>
|
Florian Gutmann <f.gutmann@chronimo.com>
|
||||||
Marwan Al Jubeh <marwan.aljubeh@gmail.com>
|
Marwan Al Jubeh <marwan.aljubeh@gmail.com>
|
||||||
Milan Broum <midlis@googlemail.com>
|
Milan Broum <midlis@googlemail.com>
|
||||||
Sebastian Sauer <info@dynpages.de>
|
Sebastian Sauer <info@dynpages.de>
|
||||||
@ -157,7 +157,7 @@ David Soms <david.soms@gmail.com>
|
|||||||
David De Sloovere <david.desloovere@hotmail.com>
|
David De Sloovere <david.desloovere@hotmail.com>
|
||||||
Michael P. Jung <michael.jung@terreon.de>
|
Michael P. Jung <michael.jung@terreon.de>
|
||||||
Shannon Pekary <spekary@gmail.com>
|
Shannon Pekary <spekary@gmail.com>
|
||||||
Matthew Hutton <meh@corefiling.co.uk>
|
Matthew Edward Hutton <meh@corefiling.co.uk>
|
||||||
James Khoury <james@jameskhoury.com>
|
James Khoury <james@jameskhoury.com>
|
||||||
Rob Loach <robloach@gmail.com>
|
Rob Loach <robloach@gmail.com>
|
||||||
Alberto Monteiro <betimbrasil@gmail.com>
|
Alberto Monteiro <betimbrasil@gmail.com>
|
||||||
@ -168,7 +168,7 @@ Genie <386@mail.com>
|
|||||||
Rick Waldron <waldron.rick@gmail.com>
|
Rick Waldron <waldron.rick@gmail.com>
|
||||||
Ian Simpson <spoonlikesham@gmail.com>
|
Ian Simpson <spoonlikesham@gmail.com>
|
||||||
Lev Kitsis <spam4lev@gmail.com>
|
Lev Kitsis <spam4lev@gmail.com>
|
||||||
TJ VanToll <tj.vantoll@gmail.com>
|
Ted VanToll <tj.vantoll@gmail.com>
|
||||||
Justin Domnitz <jdomnitz@gmail.com>
|
Justin Domnitz <jdomnitz@gmail.com>
|
||||||
Douglas Cerna <douglascerna@yahoo.com>
|
Douglas Cerna <douglascerna@yahoo.com>
|
||||||
Bert ter Heide <bertjh@hotmail.com>
|
Bert ter Heide <bertjh@hotmail.com>
|
||||||
@ -189,11 +189,11 @@ Eneko Illarramendi <eneko@illarra.com>
|
|||||||
EungJun Yi <semtlenori@gmail.com>
|
EungJun Yi <semtlenori@gmail.com>
|
||||||
Courtland Allen <courtlandallen@gmail.com>
|
Courtland Allen <courtlandallen@gmail.com>
|
||||||
Viktar Varvanovich <non4eg@gmail.com>
|
Viktar Varvanovich <non4eg@gmail.com>
|
||||||
Danny Trunk <dtrunk90@googlemail.com>
|
Danny Trunk <dtrunk90@gmail.com>
|
||||||
Pavel Stetina <pavel.stetina@nangu.tv>
|
Pavel Stetina <pavel.stetina@nangu.tv>
|
||||||
Mike Stay <metaweta@gmail.com>
|
Michael Stay <metaweta@gmail.com>
|
||||||
Steven Roussey <sroussey@gmail.com>
|
Steven Roussey <sroussey@gmail.com>
|
||||||
Mike Hollis <hollis21@gmail.com>
|
Michael Hollis <hollis21@gmail.com>
|
||||||
Lee Rowlands <lee.rowlands@previousnext.com.au>
|
Lee Rowlands <lee.rowlands@previousnext.com.au>
|
||||||
Timmy Willison <timmywillisn@gmail.com>
|
Timmy Willison <timmywillisn@gmail.com>
|
||||||
Karl Swedberg <kswedberg@gmail.com>
|
Karl Swedberg <kswedberg@gmail.com>
|
||||||
|
13
build/.jshintrc
Normal file
13
build/.jshintrc
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
{
|
||||||
|
"curly": true,
|
||||||
|
"eqnull": true,
|
||||||
|
"eqeqeq": true,
|
||||||
|
"expr": true,
|
||||||
|
"noarg": true,
|
||||||
|
"node": true,
|
||||||
|
"onevar": true,
|
||||||
|
"smarttabs": true,
|
||||||
|
"strict": false,
|
||||||
|
"trailing": true,
|
||||||
|
"undef": true
|
||||||
|
}
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env node
|
#!/usr/bin/env node
|
||||||
|
/*global cat:true cd:true cp:true echo:true exec:true exit:true ls:true*/
|
||||||
|
|
||||||
var baseDir, repoDir, prevVersion, newVersion, nextVersion, tagTime,
|
var baseDir, repoDir, prevVersion, newVersion, nextVersion, tagTime,
|
||||||
fs = require( "fs" ),
|
fs = require( "fs" ),
|
||||||
@ -40,6 +41,9 @@ walk([
|
|||||||
section( "gathering contributors" ),
|
section( "gathering contributors" ),
|
||||||
gatherContributors,
|
gatherContributors,
|
||||||
|
|
||||||
|
section( "generating quick download" ),
|
||||||
|
generateQuickDownload,
|
||||||
|
|
||||||
section( "updating trac" ),
|
section( "updating trac" ),
|
||||||
updateTrac,
|
updateTrac,
|
||||||
confirm
|
confirm
|
||||||
@ -250,13 +254,41 @@ function gatherContributors() {
|
|||||||
echo ( "Adding people thanked in commits..." );
|
echo ( "Adding people thanked in commits..." );
|
||||||
contributors = contributors.concat(
|
contributors = contributors.concat(
|
||||||
gitLog( "%b%n%s" ).filter(function( line ) {
|
gitLog( "%b%n%s" ).filter(function( line ) {
|
||||||
return /thank/i.test( line );
|
return (/thank/i).test( line );
|
||||||
}));
|
}));
|
||||||
|
|
||||||
fs.writeFileSync( contributorsPath, contributors.join( "\n" ) );
|
fs.writeFileSync( contributorsPath, contributors.join( "\n" ) );
|
||||||
echo( "Stored contributors in " + contributorsPath.cyan + "." );
|
echo( "Stored contributors in " + contributorsPath.cyan + "." );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function generateQuickDownload() {
|
||||||
|
var config,
|
||||||
|
downloadDir = repoDir + "/node_modules/download.jqueryui.com",
|
||||||
|
filename = "jquery-ui-" + newVersion + ".custom.zip",
|
||||||
|
destination = baseDir + "/" + filename;
|
||||||
|
|
||||||
|
cd( downloadDir );
|
||||||
|
|
||||||
|
// Update jQuery UI version for download builder
|
||||||
|
config = JSON.parse( cat( "config.json" ) );
|
||||||
|
config.jqueryUi = newVersion;
|
||||||
|
JSON.stringify( config ).to( "config.json" );
|
||||||
|
|
||||||
|
// Generate quick download
|
||||||
|
// TODO: Find a way to avoid having to clone jquery-ui inside download builder
|
||||||
|
if ( exec( "grunt prepare build" ).code !== 0 ) {
|
||||||
|
abort( "Error generating quick download." );
|
||||||
|
}
|
||||||
|
cp( downloadDir + "/release/" + filename, destination );
|
||||||
|
// cp() doesn't have error handling, so check for the file
|
||||||
|
if ( ls( destination ).length !== 1 ) {
|
||||||
|
abort( "Error copying quick download." );
|
||||||
|
}
|
||||||
|
|
||||||
|
// Go back to repo directory for consistency
|
||||||
|
cd( repoDir );
|
||||||
|
}
|
||||||
|
|
||||||
function updateTrac() {
|
function updateTrac() {
|
||||||
echo( newVersion.cyan + " was tagged at " + tagTime.cyan + "." );
|
echo( newVersion.cyan + " was tagged at " + tagTime.cyan + "." );
|
||||||
echo( "Close the " + newVersion.cyan + " Milestone with the above date and time." );
|
echo( "Close the " + newVersion.cyan + " Milestone with the above date and time." );
|
||||||
@ -347,8 +379,8 @@ function bootstrap( fn ) {
|
|||||||
return process.exit( 1 );
|
return process.exit( 1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
require( baseDir + "/node_modules/shelljs/global" );
|
require( "shelljs/global" );
|
||||||
require( baseDir + "/node_modules/colors" );
|
require( "colors" );
|
||||||
|
|
||||||
fn();
|
fn();
|
||||||
});
|
});
|
||||||
|
@ -177,8 +177,8 @@ grunt.registerTask( "generate_themes", function() {
|
|||||||
distFolder = "dist/" + grunt.template.process( grunt.config( "files.dist" ), grunt.config() );
|
distFolder = "dist/" + grunt.template.process( grunt.config( "files.dist" ), grunt.config() );
|
||||||
try {
|
try {
|
||||||
require.resolve( "download.jqueryui.com" );
|
require.resolve( "download.jqueryui.com" );
|
||||||
} catch( e ) {
|
} catch( error ) {
|
||||||
throw "You need to manually install download.jqueryui.com for this task to work";
|
throw new Error( "You need to manually install download.jqueryui.com for this task to work" );
|
||||||
}
|
}
|
||||||
|
|
||||||
// copy release files into download builder to avoid cloning again
|
// copy release files into download builder to avoid cloning again
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
defaultDate: "+1w",
|
defaultDate: "+1w",
|
||||||
changeMonth: true,
|
changeMonth: true,
|
||||||
numberOfMonths: 3,
|
numberOfMonths: 3,
|
||||||
onSelect: function( selectedDate ) {
|
onClose: function( selectedDate ) {
|
||||||
$( "#to" ).datepicker( "option", "minDate", selectedDate );
|
$( "#to" ).datepicker( "option", "minDate", selectedDate );
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -23,7 +23,7 @@
|
|||||||
defaultDate: "+1w",
|
defaultDate: "+1w",
|
||||||
changeMonth: true,
|
changeMonth: true,
|
||||||
numberOfMonths: 3,
|
numberOfMonths: 3,
|
||||||
onSelect: function( selectedDate ) {
|
onClose: function( selectedDate ) {
|
||||||
$( "#from" ).datepicker( "option", "maxDate", selectedDate );
|
$( "#from" ).datepicker( "option", "maxDate", selectedDate );
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<title>jQuery UI Position - Default functionality</title>
|
<title>jQuery UI Position - Image Cycler</title>
|
||||||
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
|
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
|
||||||
<script src="../../jquery-1.8.2.js"></script>
|
<script src="../../jquery-1.8.2.js"></script>
|
||||||
<script src="../../ui/jquery.ui.core.js"></script>
|
<script src="../../ui/jquery.ui.core.js"></script>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<title>jQuery UI Spinner - Default functionality</title>
|
<title>jQuery UI Spinner - Currency</title>
|
||||||
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
|
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
|
||||||
<script src="../../jquery-1.8.2.js"></script>
|
<script src="../../jquery-1.8.2.js"></script>
|
||||||
<script src="../../external/jquery.mousewheel.js"></script>
|
<script src="../../external/jquery.mousewheel.js"></script>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<title>jQuery UI Tooltip - Default functionality</title>
|
<title>jQuery UI Tooltip - Custom Styling</title>
|
||||||
<link rel="stylesheet" href="../../themes/base/jquery.ui.tooltip.css">
|
<link rel="stylesheet" href="../../themes/base/jquery.ui.tooltip.css">
|
||||||
<script src="../../jquery-1.8.2.js"></script>
|
<script src="../../jquery-1.8.2.js"></script>
|
||||||
<script src="../../ui/jquery.ui.core.js"></script>
|
<script src="../../ui/jquery.ui.core.js"></script>
|
||||||
|
2
grunt.js
2
grunt.js
@ -287,7 +287,7 @@ grunt.initConfig({
|
|||||||
// TODO remove items from this list once rewritten
|
// TODO remove items from this list once rewritten
|
||||||
return !( /(mouse|datepicker|draggable|droppable|resizable|selectable|sortable)\.js$/ ).test( file );
|
return !( /(mouse|datepicker|draggable|droppable|resizable|selectable|sortable)\.js$/ ).test( file );
|
||||||
}),
|
}),
|
||||||
grunt: [ "grunt.js", "build/tasks/*.js" ],
|
grunt: [ "grunt.js", "build/**/*.js" ],
|
||||||
tests: "tests/unit/**/*.js"
|
tests: "tests/unit/**/*.js"
|
||||||
},
|
},
|
||||||
csslint: {
|
csslint: {
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
"name": "jquery-ui",
|
"name": "jquery-ui",
|
||||||
"title": "jQuery UI",
|
"title": "jQuery UI",
|
||||||
"description": "A curated set of user interface interactions, effects, widgets, and themes built on top of the jQuery JavaScript Library.",
|
"description": "A curated set of user interface interactions, effects, widgets, and themes built on top of the jQuery JavaScript Library.",
|
||||||
"version": "1.9.0pre",
|
"version": "1.9.1pre",
|
||||||
"homepage": "http://jqueryui.com",
|
"homepage": "http://jqueryui.com",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "jQuery Foundation and other contributors",
|
"name": "jQuery Foundation and other contributors",
|
||||||
|
@ -148,7 +148,7 @@ $.extend( $.simulate.prototype, {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// TODO: can we hook into core's logic?
|
// TODO: can we hook into core's logic?
|
||||||
if ( $.browser.msie || $.browser.opera ) {
|
if ( $.ui.ie || (({}).toString.call( window.opera ) === "[object Opera]") ) {
|
||||||
// TODO: is charCode ever <0 ? Can we just use charCode || keyCode?
|
// TODO: is charCode ever <0 ? Can we just use charCode || keyCode?
|
||||||
event.keyCode = (options.charCode > 0) ? options.charCode : options.keyCode;
|
event.keyCode = (options.charCode > 0) ? options.charCode : options.keyCode;
|
||||||
event.charCode = undefined;
|
event.charCode = undefined;
|
||||||
|
@ -59,7 +59,7 @@ test('baseStructure', function() {
|
|||||||
var header, title, table, thead, week, panel, inl, child,
|
var header, title, table, thead, week, panel, inl, child,
|
||||||
inp = init('#inp').focus(),
|
inp = init('#inp').focus(),
|
||||||
dp = $('#ui-datepicker-div'),
|
dp = $('#ui-datepicker-div'),
|
||||||
iframe = ($.browser.msie && parseInt($.browser.version, 10) < 7);
|
iframe = ($.ui.ie6);
|
||||||
ok(dp.is(':visible'), 'Structure - datepicker visible');
|
ok(dp.is(':visible'), 'Structure - datepicker visible');
|
||||||
ok(!dp.is('.ui-datepicker-rtl'), 'Structure - not right-to-left');
|
ok(!dp.is('.ui-datepicker-rtl'), 'Structure - not right-to-left');
|
||||||
ok(!dp.is('.ui-datepicker-multi'), 'Structure - not multi-month');
|
ok(!dp.is('.ui-datepicker-multi'), 'Structure - not multi-month');
|
||||||
@ -186,7 +186,7 @@ test('customStructure', function() {
|
|||||||
inp = init('#inp', $.datepicker.regional.he);
|
inp = init('#inp', $.datepicker.regional.he);
|
||||||
inp.data('showButtonPanel.datepicker',true);
|
inp.data('showButtonPanel.datepicker',true);
|
||||||
inp.focus();
|
inp.focus();
|
||||||
iframe = ($.browser.msie && parseInt($.browser.version, 10) < 7);
|
iframe = ($.ui.ie6);
|
||||||
ok(dp.is('.ui-datepicker-rtl'), 'Structure RTL - right-to-left');
|
ok(dp.is('.ui-datepicker-rtl'), 'Structure RTL - right-to-left');
|
||||||
header = dp.children(':first');
|
header = dp.children(':first');
|
||||||
ok(header.is('div.ui-datepicker-header'), 'Structure RTL - header division');
|
ok(header.is('div.ui-datepicker-header'), 'Structure RTL - header division');
|
||||||
|
@ -7,7 +7,7 @@ var disabled = TestHelpers.tabs.disabled,
|
|||||||
module( "tabs: options" );
|
module( "tabs: options" );
|
||||||
|
|
||||||
test( "{ active: default }", function() {
|
test( "{ active: default }", function() {
|
||||||
expect( 4 );
|
expect( 6 );
|
||||||
|
|
||||||
var element = $( "#tabs1" ).tabs();
|
var element = $( "#tabs1" ).tabs();
|
||||||
equal( element.tabs( "option", "active" ), 0, "should be 0 by default" );
|
equal( element.tabs( "option", "active" ), 0, "should be 0 by default" );
|
||||||
@ -19,6 +19,12 @@ test( "{ active: default }", function() {
|
|||||||
equal( element.tabs( "option", "active" ), 2, "should be 2 based on URL" );
|
equal( element.tabs( "option", "active" ), 2, "should be 2 based on URL" );
|
||||||
state( element, 0, 0, 1 );
|
state( element, 0, 0, 1 );
|
||||||
element.tabs( "destroy" );
|
element.tabs( "destroy" );
|
||||||
|
|
||||||
|
location.hash = "#custom-id";
|
||||||
|
element = $( "#tabs2" ).tabs();
|
||||||
|
equal( element.tabs( "option", "active" ), 3, "should be 3 based on URL" );
|
||||||
|
state( element, 0, 0, 0, 1, 0 );
|
||||||
|
element.tabs( "destroy" );
|
||||||
location.hash = "#";
|
location.hash = "#";
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -3,13 +3,20 @@
|
|||||||
module( "tooltip: methods" );
|
module( "tooltip: methods" );
|
||||||
|
|
||||||
test( "destroy", function() {
|
test( "destroy", function() {
|
||||||
expect( 2 );
|
expect( 3 );
|
||||||
|
var element = $( "#tooltipped1" );
|
||||||
|
|
||||||
domEqual( "#tooltipped1", function() {
|
domEqual( "#tooltipped1", function() {
|
||||||
$( "#tooltipped1" ).tooltip().tooltip( "destroy" );
|
element.tooltip().tooltip( "destroy" );
|
||||||
});
|
});
|
||||||
|
|
||||||
// make sure that open tooltips are removed on destroy
|
// make sure that open tooltips are removed on destroy
|
||||||
$( "#tooltipped1" ).tooltip().tooltip( "open" ).tooltip( "destroy" );
|
domEqual( "#tooltipped1", function() {
|
||||||
|
element
|
||||||
|
.tooltip()
|
||||||
|
.tooltip( "open", $.Event( "mouseover", { target: element[0] }) )
|
||||||
|
.tooltip( "destroy" );
|
||||||
|
});
|
||||||
equal( $( ".ui-tooltip" ).length, 0 );
|
equal( $( ".ui-tooltip" ).length, 0 );
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -29,6 +36,23 @@ test( "open/close", function() {
|
|||||||
$.fx.off = false;
|
$.fx.off = false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// #8626 - Calling open() without an event
|
||||||
|
test( "open/close with tracking", function() {
|
||||||
|
expect( 3 );
|
||||||
|
$.fx.off = true;
|
||||||
|
var tooltip,
|
||||||
|
element = $( "#tooltipped1" ).tooltip({ track: true });
|
||||||
|
equal( $( ".ui-tooltip" ).length, 0, "no tooltip on init" );
|
||||||
|
|
||||||
|
element.tooltip( "open" );
|
||||||
|
tooltip = $( "#" + element.data( "ui-tooltip-id" ) );
|
||||||
|
ok( tooltip.is( ":visible" ) );
|
||||||
|
|
||||||
|
element.tooltip( "close" );
|
||||||
|
ok( tooltip.is( ":hidden" ) );
|
||||||
|
$.fx.off = false;
|
||||||
|
});
|
||||||
|
|
||||||
test( "enable/disable", function() {
|
test( "enable/disable", function() {
|
||||||
expect( 7 );
|
expect( 7 );
|
||||||
$.fx.off = true;
|
$.fx.off = true;
|
||||||
|
6
themes/base/jquery.ui.autocomplete.css
vendored
6
themes/base/jquery.ui.autocomplete.css
vendored
@ -8,7 +8,11 @@
|
|||||||
*
|
*
|
||||||
* http://docs.jquery.com/UI/Autocomplete#theming
|
* http://docs.jquery.com/UI/Autocomplete#theming
|
||||||
*/
|
*/
|
||||||
.ui-autocomplete { position: absolute; cursor: default; }
|
.ui-autocomplete {
|
||||||
|
position: absolute;
|
||||||
|
top: 0; /* #8656 */
|
||||||
|
cursor: default;
|
||||||
|
}
|
||||||
|
|
||||||
/* workarounds */
|
/* workarounds */
|
||||||
* html .ui-autocomplete { width:1px; } /* without this, the menu expands to 100% in IE6 */
|
* html .ui-autocomplete { width:1px; } /* without this, the menu expands to 100% in IE6 */
|
||||||
|
2
themes/base/jquery.ui.theme.css
vendored
2
themes/base/jquery.ui.theme.css
vendored
@ -27,7 +27,7 @@
|
|||||||
.ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { border: 1px solid #d3d3d3/*{borderColorDefault}*/; background: #e6e6e6/*{bgColorDefault}*/ url(images/ui-bg_glass_75_e6e6e6_1x400.png)/*{bgImgUrlDefault}*/ 50%/*{bgDefaultXPos}*/ 50%/*{bgDefaultYPos}*/ repeat-x/*{bgDefaultRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #555555/*{fcDefault}*/; }
|
.ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { border: 1px solid #d3d3d3/*{borderColorDefault}*/; background: #e6e6e6/*{bgColorDefault}*/ url(images/ui-bg_glass_75_e6e6e6_1x400.png)/*{bgImgUrlDefault}*/ 50%/*{bgDefaultXPos}*/ 50%/*{bgDefaultYPos}*/ repeat-x/*{bgDefaultRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #555555/*{fcDefault}*/; }
|
||||||
.ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited { color: #555555/*{fcDefault}*/; text-decoration: none; }
|
.ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited { color: #555555/*{fcDefault}*/; text-decoration: none; }
|
||||||
.ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus { border: 1px solid #999999/*{borderColorHover}*/; background: #dadada/*{bgColorHover}*/ url(images/ui-bg_glass_75_dadada_1x400.png)/*{bgImgUrlHover}*/ 50%/*{bgHoverXPos}*/ 50%/*{bgHoverYPos}*/ repeat-x/*{bgHoverRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcHover}*/; }
|
.ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus { border: 1px solid #999999/*{borderColorHover}*/; background: #dadada/*{bgColorHover}*/ url(images/ui-bg_glass_75_dadada_1x400.png)/*{bgImgUrlHover}*/ 50%/*{bgHoverXPos}*/ 50%/*{bgHoverYPos}*/ repeat-x/*{bgHoverRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcHover}*/; }
|
||||||
.ui-state-hover a, .ui-state-hover a:hover { color: #212121/*{fcHover}*/; text-decoration: none; }
|
.ui-state-hover a, .ui-state-hover a:hover, .ui-state-hover a:link, .ui-state-hover a:visited { color: #212121/*{fcHover}*/; text-decoration: none; }
|
||||||
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active { border: 1px solid #aaaaaa/*{borderColorActive}*/; background: #ffffff/*{bgColorActive}*/ url(images/ui-bg_glass_65_ffffff_1x400.png)/*{bgImgUrlActive}*/ 50%/*{bgActiveXPos}*/ 50%/*{bgActiveYPos}*/ repeat-x/*{bgActiveRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcActive}*/; }
|
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active { border: 1px solid #aaaaaa/*{borderColorActive}*/; background: #ffffff/*{bgColorActive}*/ url(images/ui-bg_glass_65_ffffff_1x400.png)/*{bgImgUrlActive}*/ 50%/*{bgActiveXPos}*/ 50%/*{bgActiveYPos}*/ repeat-x/*{bgActiveRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcActive}*/; }
|
||||||
.ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #212121/*{fcActive}*/; text-decoration: none; }
|
.ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #212121/*{fcActive}*/; text-decoration: none; }
|
||||||
|
|
||||||
|
8
ui/jquery.ui.core.js
vendored
8
ui/jquery.ui.core.js
vendored
@ -69,7 +69,7 @@ $.fn.extend({
|
|||||||
|
|
||||||
scrollParent: function() {
|
scrollParent: function() {
|
||||||
var scrollParent;
|
var scrollParent;
|
||||||
if (($.browser.msie && (/(static|relative)/).test(this.css('position'))) || (/absolute/).test(this.css('position'))) {
|
if (($.ui.ie && (/(static|relative)/).test(this.css('position'))) || (/absolute/).test(this.css('position'))) {
|
||||||
scrollParent = this.parents().filter(function() {
|
scrollParent = this.parents().filter(function() {
|
||||||
return (/(relative|absolute|fixed)/).test($.css(this,'position')) && (/(auto|scroll)/).test($.css(this,'overflow')+$.css(this,'overflow-y')+$.css(this,'overflow-x'));
|
return (/(relative|absolute|fixed)/).test($.css(this,'position')) && (/(auto|scroll)/).test($.css(this,'overflow')+$.css(this,'overflow-y')+$.css(this,'overflow-x'));
|
||||||
}).eq(0);
|
}).eq(0);
|
||||||
@ -258,6 +258,12 @@ $(function() {
|
|||||||
|
|
||||||
// deprecated
|
// deprecated
|
||||||
|
|
||||||
|
(function() {
|
||||||
|
var uaMatch = /msie ([\w.]+)/.exec( navigator.userAgent.toLowerCase() ) || [];
|
||||||
|
$.ui.ie = uaMatch.length ? true : false;
|
||||||
|
$.ui.ie6 = parseFloat( uaMatch[ 1 ], 10 ) === 6;
|
||||||
|
})();
|
||||||
|
|
||||||
$.fn.extend({
|
$.fn.extend({
|
||||||
disableSelection: function() {
|
disableSelection: function() {
|
||||||
return this.bind( ( $.support.selectstart ? "selectstart" : "mousedown" ) +
|
return this.bind( ( $.support.selectstart ? "selectstart" : "mousedown" ) +
|
||||||
|
2
ui/jquery.ui.datepicker.js
vendored
2
ui/jquery.ui.datepicker.js
vendored
@ -1605,7 +1605,7 @@ $.extend(Datepicker.prototype, {
|
|||||||
}
|
}
|
||||||
html += group;
|
html += group;
|
||||||
}
|
}
|
||||||
html += buttonPanel + ($.browser.msie && parseInt($.browser.version,10) < 7 && !inst.inline ?
|
html += buttonPanel + ($.ui.ie6 && !inst.inline ?
|
||||||
'<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>' : '');
|
'<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>' : '');
|
||||||
inst._keyEvent = false;
|
inst._keyEvent = false;
|
||||||
return html;
|
return html;
|
||||||
|
6
ui/jquery.ui.dialog.js
vendored
6
ui/jquery.ui.dialog.js
vendored
@ -364,7 +364,7 @@ $.widget("ui.dialog", {
|
|||||||
props = $.isFunction( props ) ?
|
props = $.isFunction( props ) ?
|
||||||
{ click: props, text: name } :
|
{ click: props, text: name } :
|
||||||
props;
|
props;
|
||||||
var button = $( "<button type='button'>" )
|
var button = $( "<button type='button'></button>" )
|
||||||
.attr( props, true )
|
.attr( props, true )
|
||||||
.unbind( "click" )
|
.unbind( "click" )
|
||||||
.click(function() {
|
.click(function() {
|
||||||
@ -768,7 +768,7 @@ $.extend( $.ui.dialog.overlay, {
|
|||||||
var scrollHeight,
|
var scrollHeight,
|
||||||
offsetHeight;
|
offsetHeight;
|
||||||
// handle IE
|
// handle IE
|
||||||
if ( $.browser.msie ) {
|
if ( $.ui.ie ) {
|
||||||
scrollHeight = Math.max(
|
scrollHeight = Math.max(
|
||||||
document.documentElement.scrollHeight,
|
document.documentElement.scrollHeight,
|
||||||
document.body.scrollHeight
|
document.body.scrollHeight
|
||||||
@ -793,7 +793,7 @@ $.extend( $.ui.dialog.overlay, {
|
|||||||
var scrollWidth,
|
var scrollWidth,
|
||||||
offsetWidth;
|
offsetWidth;
|
||||||
// handle IE
|
// handle IE
|
||||||
if ( $.browser.msie ) {
|
if ( $.ui.ie ) {
|
||||||
scrollWidth = Math.max(
|
scrollWidth = Math.max(
|
||||||
document.documentElement.scrollWidth,
|
document.documentElement.scrollWidth,
|
||||||
document.body.scrollWidth
|
document.body.scrollWidth
|
||||||
|
18
ui/jquery.ui.draggable.js
vendored
18
ui/jquery.ui.draggable.js
vendored
@ -318,7 +318,7 @@ $.widget("ui.draggable", $.ui.mouse, {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if((this.offsetParent[0] == document.body) //This needs to be actually done for all browsers, since pageX/pageY includes this information
|
if((this.offsetParent[0] == document.body) //This needs to be actually done for all browsers, since pageX/pageY includes this information
|
||||||
|| (this.offsetParent[0].tagName && this.offsetParent[0].tagName.toLowerCase() == 'html' && $.browser.msie)) //Ugly IE fix
|
|| (this.offsetParent[0].tagName && this.offsetParent[0].tagName.toLowerCase() == 'html' && $.ui.ie)) //Ugly IE fix
|
||||||
po = { top: 0, left: 0 };
|
po = { top: 0, left: 0 };
|
||||||
|
|
||||||
return {
|
return {
|
||||||
@ -571,13 +571,29 @@ $.ui.plugin.add("draggable", "connectToSortable", {
|
|||||||
|
|
||||||
$.each(inst.sortables, function(i) {
|
$.each(inst.sortables, function(i) {
|
||||||
|
|
||||||
|
var innermostIntersecting = false;
|
||||||
|
var thisSortable = this;
|
||||||
//Copy over some variables to allow calling the sortable's native _intersectsWith
|
//Copy over some variables to allow calling the sortable's native _intersectsWith
|
||||||
this.instance.positionAbs = inst.positionAbs;
|
this.instance.positionAbs = inst.positionAbs;
|
||||||
this.instance.helperProportions = inst.helperProportions;
|
this.instance.helperProportions = inst.helperProportions;
|
||||||
this.instance.offset.click = inst.offset.click;
|
this.instance.offset.click = inst.offset.click;
|
||||||
|
|
||||||
if(this.instance._intersectsWith(this.instance.containerCache)) {
|
if(this.instance._intersectsWith(this.instance.containerCache)) {
|
||||||
|
innermostIntersecting = true;
|
||||||
|
$.each(inst.sortables, function () {
|
||||||
|
this.instance.positionAbs = inst.positionAbs;
|
||||||
|
this.instance.helperProportions = inst.helperProportions;
|
||||||
|
this.instance.offset.click = inst.offset.click;
|
||||||
|
if (this != thisSortable
|
||||||
|
&& this.instance._intersectsWith(this.instance.containerCache)
|
||||||
|
&& $.ui.contains(thisSortable.instance.element[0], this.instance.element[0]))
|
||||||
|
innermostIntersecting = false;
|
||||||
|
return innermostIntersecting;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if(innermostIntersecting) {
|
||||||
//If it intersects, we use a little isOver variable and set it once, so our move-in stuff gets fired only once
|
//If it intersects, we use a little isOver variable and set it once, so our move-in stuff gets fired only once
|
||||||
if(!this.instance.isOver) {
|
if(!this.instance.isOver) {
|
||||||
|
|
||||||
|
2
ui/jquery.ui.mouse.js
vendored
2
ui/jquery.ui.mouse.js
vendored
@ -111,7 +111,7 @@ $.widget("ui.mouse", {
|
|||||||
|
|
||||||
_mouseMove: function(event) {
|
_mouseMove: function(event) {
|
||||||
// IE mouseup check - mouseup happened when mouse was out of window
|
// IE mouseup check - mouseup happened when mouse was out of window
|
||||||
if ($.browser.msie && !(document.documentMode >= 9) && !event.button) {
|
if ($.ui.ie && !(document.documentMode >= 9) && !event.button) {
|
||||||
return this._mouseUp(event);
|
return this._mouseUp(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
4
ui/jquery.ui.resizable.js
vendored
4
ui/jquery.ui.resizable.js
vendored
@ -466,8 +466,8 @@ $.widget("ui.resizable", $.ui.mouse, {
|
|||||||
this.helper = this.helper || $('<div style="overflow:hidden;"></div>');
|
this.helper = this.helper || $('<div style="overflow:hidden;"></div>');
|
||||||
|
|
||||||
// fix ie6 offset TODO: This seems broken
|
// fix ie6 offset TODO: This seems broken
|
||||||
var ie6 = $.browser.msie && $.browser.version < 7, ie6offset = (ie6 ? 1 : 0),
|
var ie6offset = ($.ui.ie6 ? 1 : 0),
|
||||||
pxyoffset = ( ie6 ? 2 : -1 );
|
pxyoffset = ( $.ui.ie6 ? 2 : -1 );
|
||||||
|
|
||||||
this.helper.addClass(this._helper).css({
|
this.helper.addClass(this._helper).css({
|
||||||
width: this.element.outerWidth() + pxyoffset,
|
width: this.element.outerWidth() + pxyoffset,
|
||||||
|
31
ui/jquery.ui.sortable.js
vendored
31
ui/jquery.ui.sortable.js
vendored
@ -562,14 +562,13 @@ $.widget("ui.sortable", $.ui.mouse, {
|
|||||||
|
|
||||||
var list = this.currentItem.find(":data(" + this.widgetName + "-item)");
|
var list = this.currentItem.find(":data(" + this.widgetName + "-item)");
|
||||||
|
|
||||||
for (var i=0; i < this.items.length; i++) {
|
this.items = $.grep(this.items, function (item) {
|
||||||
|
|
||||||
for (var j=0; j < list.length; j++) {
|
for (var j=0; j < list.length; j++) {
|
||||||
if(list[j] == this.items[i].item[0])
|
if(list[j] == item.item[0])
|
||||||
this.items.splice(i,1);
|
return false;
|
||||||
};
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -735,16 +734,26 @@ $.widget("ui.sortable", $.ui.mouse, {
|
|||||||
if(this.containers.length === 1) {
|
if(this.containers.length === 1) {
|
||||||
this.containers[innermostIndex]._trigger("over", event, this._uiHash(this));
|
this.containers[innermostIndex]._trigger("over", event, this._uiHash(this));
|
||||||
this.containers[innermostIndex].containerCache.over = 1;
|
this.containers[innermostIndex].containerCache.over = 1;
|
||||||
} else if(this.currentContainer != this.containers[innermostIndex]) {
|
} else {
|
||||||
|
|
||||||
//When entering a new container, we will find the item with the least distance and append our item near it
|
//When entering a new container, we will find the item with the least distance and append our item near it
|
||||||
var dist = 10000; var itemWithLeastDistance = null; var base = this.positionAbs[this.containers[innermostIndex].floating ? 'left' : 'top'];
|
var dist = 10000; var itemWithLeastDistance = null;
|
||||||
|
var posProperty = this.containers[innermostIndex].floating ? 'left' : 'top';
|
||||||
|
var sizeProperty = this.containers[innermostIndex].floating ? 'width' : 'height';
|
||||||
|
var base = this.positionAbs[posProperty] + this.offset.click[posProperty];
|
||||||
for (var j = this.items.length - 1; j >= 0; j--) {
|
for (var j = this.items.length - 1; j >= 0; j--) {
|
||||||
if(!$.contains(this.containers[innermostIndex].element[0], this.items[j].item[0])) continue;
|
if(!$.contains(this.containers[innermostIndex].element[0], this.items[j].item[0])) continue;
|
||||||
var cur = this.containers[innermostIndex].floating ? this.items[j].item.offset().left : this.items[j].item.offset().top;
|
if(this.items[j].item[0] == this.currentItem[0]) continue;
|
||||||
|
var cur = this.items[j].item.offset()[posProperty];
|
||||||
|
var nearBottom = false;
|
||||||
|
if(Math.abs(cur - base) > Math.abs(cur + this.items[j][sizeProperty] - base)){
|
||||||
|
nearBottom = true;
|
||||||
|
cur += this.items[j][sizeProperty];
|
||||||
|
}
|
||||||
|
|
||||||
if(Math.abs(cur - base) < dist) {
|
if(Math.abs(cur - base) < dist) {
|
||||||
dist = Math.abs(cur - base); itemWithLeastDistance = this.items[j];
|
dist = Math.abs(cur - base); itemWithLeastDistance = this.items[j];
|
||||||
this.direction = (cur - base > 0) ? 'down' : 'up';
|
this.direction = nearBottom ? "up": "down";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -822,7 +831,7 @@ $.widget("ui.sortable", $.ui.mouse, {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if((this.offsetParent[0] == document.body) //This needs to be actually done for all browsers, since pageX/pageY includes this information
|
if((this.offsetParent[0] == document.body) //This needs to be actually done for all browsers, since pageX/pageY includes this information
|
||||||
|| (this.offsetParent[0].tagName && this.offsetParent[0].tagName.toLowerCase() == 'html' && $.browser.msie)) //Ugly IE fix
|
|| (this.offsetParent[0].tagName && this.offsetParent[0].tagName.toLowerCase() == 'html' && $.ui.ie)) //Ugly IE fix
|
||||||
po = { top: 0, left: 0 };
|
po = { top: 0, left: 0 };
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
11
ui/jquery.ui.tabs.js
vendored
11
ui/jquery.ui.tabs.js
vendored
@ -51,7 +51,8 @@ $.widget( "ui.tabs", {
|
|||||||
var panel,
|
var panel,
|
||||||
that = this,
|
that = this,
|
||||||
options = this.options,
|
options = this.options,
|
||||||
active = options.active;
|
active = options.active,
|
||||||
|
locationHash = location.hash.substring( 1 );
|
||||||
|
|
||||||
this.running = false;
|
this.running = false;
|
||||||
|
|
||||||
@ -80,9 +81,9 @@ $.widget( "ui.tabs", {
|
|||||||
|
|
||||||
if ( active === null ) {
|
if ( active === null ) {
|
||||||
// check the fragment identifier in the URL
|
// check the fragment identifier in the URL
|
||||||
if ( location.hash ) {
|
if ( locationHash ) {
|
||||||
this.anchors.each(function( i, anchor ) {
|
this.tabs.each(function( i, tab ) {
|
||||||
if ( anchor.hash === location.hash ) {
|
if ( $( tab ).attr( "aria-controls" ) === locationHash ) {
|
||||||
active = i;
|
active = i;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -91,7 +92,7 @@ $.widget( "ui.tabs", {
|
|||||||
|
|
||||||
// check for a tab marked active via a class
|
// check for a tab marked active via a class
|
||||||
if ( active === null ) {
|
if ( active === null ) {
|
||||||
active = this.tabs.filter( ".ui-tabs-active" ).index();
|
active = this.tabs.index( this.tabs.filter( ".ui-tabs-active" ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
// no active tab, set to false
|
// no active tab, set to false
|
||||||
|
22
ui/jquery.ui.tooltip.js
vendored
22
ui/jquery.ui.tooltip.js
vendored
@ -140,6 +140,8 @@ $.widget( "ui.tooltip", {
|
|||||||
this._find( target ).position( $.extend({
|
this._find( target ).position( $.extend({
|
||||||
of: target
|
of: target
|
||||||
}, this.options.position ) );
|
}, this.options.position ) );
|
||||||
|
// Stop tracking (#8622)
|
||||||
|
this._off( this.document, "mousemove" );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -214,7 +216,7 @@ $.widget( "ui.tooltip", {
|
|||||||
positionOption.of = event;
|
positionOption.of = event;
|
||||||
tooltip.position( positionOption );
|
tooltip.position( positionOption );
|
||||||
}
|
}
|
||||||
if ( this.options.track && /^mouse/.test( event.originalEvent.type ) ) {
|
if ( this.options.track && event && /^mouse/.test( event.originalEvent.type ) ) {
|
||||||
positionOption = $.extend( {}, this.options.position );
|
positionOption = $.extend( {}, this.options.position );
|
||||||
this._on( this.document, {
|
this._on( this.document, {
|
||||||
mousemove: position
|
mousemove: position
|
||||||
@ -315,8 +317,24 @@ $.widget( "ui.tooltip", {
|
|||||||
},
|
},
|
||||||
|
|
||||||
_destroy: function() {
|
_destroy: function() {
|
||||||
$.each( this.tooltips, function( id ) {
|
var that = this;
|
||||||
|
|
||||||
|
// close open tooltips
|
||||||
|
$.each( this.tooltips, function( id, element ) {
|
||||||
|
// Delegate to close method to handle common cleanup
|
||||||
|
var event = $.Event( "blur" );
|
||||||
|
event.target = event.currentTarget = element[0];
|
||||||
|
that.close( event, true );
|
||||||
|
|
||||||
|
// Remove immediately; destroying an open tooltip doesn't use the
|
||||||
|
// hide animation
|
||||||
$( "#" + id ).remove();
|
$( "#" + id ).remove();
|
||||||
|
|
||||||
|
// Restore the title
|
||||||
|
if ( element.data( "ui-tooltip-title" ) ) {
|
||||||
|
element.attr( "title", element.data( "ui-tooltip-title" ) );
|
||||||
|
element.removeData( "ui-tooltip-title" );
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user