aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--demos/datepicker/jquery.ui.datepicker-fr.js12
-rw-r--r--package.json2
-rw-r--r--tests/unit/datepicker/datepicker_options.js8
-rw-r--r--tests/unit/slider/slider_core.js3
-rw-r--r--tests/unit/slider/slider_events.js3
-rw-r--r--tests/unit/slider/slider_methods.js3
-rw-r--r--tests/unit/slider/slider_options.js20
-rw-r--r--themes/base/jquery.ui.datepicker.css3
-rw-r--r--themes/base/jquery.ui.spinner.css4
-rw-r--r--themes/base/jquery.ui.tabs.css11
-rw-r--r--ui/jquery.ui.dialog.js27
-rw-r--r--ui/jquery.ui.slider.js9
12 files changed, 62 insertions, 43 deletions
diff --git a/demos/datepicker/jquery.ui.datepicker-fr.js b/demos/datepicker/jquery.ui.datepicker-fr.js
index 934afd1d0..2d06743a6 100644
--- a/demos/datepicker/jquery.ui.datepicker-fr.js
+++ b/demos/datepicker/jquery.ui.datepicker-fr.js
@@ -8,12 +8,12 @@ jQuery(function($){
prevText: 'Précédent',
nextText: 'Suivant',
currentText: 'Aujourd\'hui',
- monthNames: ['Janvier','Février','Mars','Avril','Mai','Juin',
- 'Juillet','Août','Septembre','Octobre','Novembre','Décembre'],
- monthNamesShort: ['Janv.','Févr.','Mars','Avril','Mai','Juin',
- 'Juil.','Août','Sept.','Oct.','Nov.','Déc.'],
- dayNames: ['Dimanche','Lundi','Mardi','Mercredi','Jeudi','Vendredi','Samedi'],
- dayNamesShort: ['Dim.','Lun.','Mar.','Mer.','Jeu.','Ven.','Sam.'],
+ monthNames: ['janvier', 'février', 'mars', 'avril', 'mai', 'juin',
+ 'juillet', 'août', 'septembre', 'octobre', 'novembre', 'décembre'],
+ monthNamesShort: ['janv.', 'févr.', 'mars', 'avril', 'mai', 'juin',
+ 'juil.', 'août', 'sept.', 'oct.', 'nov.', 'déc.'],
+ dayNames: ['dimanche', 'lundi', 'mardi', 'mercredi', 'jeudi', 'vendredi', 'samedi'],
+ dayNamesShort: ['dim.', 'lun.', 'mar.', 'mer.', 'jeu.', 'ven.', 'sam.'],
dayNamesMin: ['D','L','M','M','J','V','S'],
weekHeader: 'Sem.',
dateFormat: 'dd/mm/yy',
diff --git a/package.json b/package.json
index c3e0a04d3..b74d1397e 100644
--- a/package.json
+++ b/package.json
@@ -64,7 +64,7 @@
"grunt-html": "0.3.3",
"grunt-git-authors": "1.2.0",
"rimraf": "2.1.4",
- "testswarm": "1.0.0-alpha"
+ "testswarm": "1.1.0"
},
"keywords": []
}
diff --git a/tests/unit/datepicker/datepicker_options.js b/tests/unit/datepicker/datepicker_options.js
index a775a5302..25257e99f 100644
--- a/tests/unit/datepicker/datepicker_options.js
+++ b/tests/unit/datepicker/datepicker_options.js
@@ -1057,13 +1057,13 @@ test("formatDate", function() {
settings = {dayNamesShort: fr.dayNamesShort, dayNames: fr.dayNames,
monthNamesShort: fr.monthNamesShort, monthNames: fr.monthNames};
equal($.datepicker.formatDate("D M y", new Date(2001, 4 - 1, 9), settings),
- "Lun. Avril 01", "Format date D M y with settings");
+ "lun. avril 01", "Format date D M y with settings");
equal($.datepicker.formatDate("DD MM yy", new Date(2001, 4 - 1, 9), settings),
- "Lundi Avril 2001", "Format date DD MM yy with settings");
+ "lundi avril 2001", "Format date DD MM yy with settings");
equal($.datepicker.formatDate("DD, MM d, yy", new Date(2001, 4 - 1, 9), settings),
- "Lundi, Avril 9, 2001", "Format date DD, MM d, yy with settings");
+ "lundi, avril 9, 2001", "Format date DD, MM d, yy with settings");
equal($.datepicker.formatDate("'jour' d 'de' MM (''DD''), yy",
- new Date(2001, 4 - 1, 9), settings), "jour 9 de Avril ('Lundi'), 2001",
+ new Date(2001, 4 - 1, 9), settings), "jour 9 de avril ('lundi'), 2001",
"Format date 'jour' d 'de' MM (''DD''), yy with settings");
});
diff --git a/tests/unit/slider/slider_core.js b/tests/unit/slider/slider_core.js
index 19c9abb8e..3649bded0 100644
--- a/tests/unit/slider/slider_core.js
+++ b/tests/unit/slider/slider_core.js
@@ -1,6 +1,3 @@
-/*
- * slider unit tests
- */
(function( $ ) {
//
// Slider Test Helper Functions
diff --git a/tests/unit/slider/slider_events.js b/tests/unit/slider/slider_events.js
index 92b0bdedd..ec93a0565 100644
--- a/tests/unit/slider/slider_events.js
+++ b/tests/unit/slider/slider_events.js
@@ -1,6 +1,3 @@
-/*
- * slider_events.js
- */
(function( $ ) {
module( "slider: events" );
diff --git a/tests/unit/slider/slider_methods.js b/tests/unit/slider/slider_methods.js
index bd9023133..c5c7e1254 100644
--- a/tests/unit/slider/slider_methods.js
+++ b/tests/unit/slider/slider_methods.js
@@ -1,6 +1,3 @@
-/*
- * slider_methods.js
- */
(function( $ ) {
module( "slider: methods" );
diff --git a/tests/unit/slider/slider_options.js b/tests/unit/slider/slider_options.js
index 3a6f55390..5cfb5351a 100644
--- a/tests/unit/slider/slider_options.js
+++ b/tests/unit/slider/slider_options.js
@@ -1,6 +1,3 @@
-/*
- * slider_options.js
- */
(function( $ ) {
var element, options;
@@ -200,7 +197,7 @@ test( "values", function() {
});
test( "range", function() {
- expect( 27 );
+ expect( 33 );
var range;
// min
@@ -300,6 +297,21 @@ test( "range", function() {
equal( element.slider( "option", "values" ), null, "values" );
deepEqual( element.slider( "values" ), [] , "values" );
element.slider( "destroy" );
+
+ // Change range from true to false
+ element = $( "<div></div>" ).slider({
+ range: true,
+ min: 1,
+ max: 10,
+ step: 1
+ }).slider( "option", "range", false );
+ equal( element.find( ".ui-slider-handle" ).length, 2, "range switch from true to false, both handles remain" );
+ equal( element.find( ".ui-slider-range" ).length, 0, "range switch from true to false" );
+ equal( element.slider( "option", "value" ), 0 , "option value" );
+ equal( element.slider( "value" ), 1 , "value" );
+ deepEqual( element.slider( "option", "values" ), [1, 1], "option values" );
+ deepEqual( element.slider( "values" ), [1, 1], "values" );
+ element.slider( "destroy" );
});
})( jQuery );
diff --git a/themes/base/jquery.ui.datepicker.css b/themes/base/jquery.ui.datepicker.css
index 5d9e71549..224924e27 100644
--- a/themes/base/jquery.ui.datepicker.css
+++ b/themes/base/jquery.ui.datepicker.css
@@ -58,9 +58,6 @@
font-size: 1em;
margin: 1px 0;
}
-.ui-datepicker select.ui-datepicker-month-year {
- width: 100%;
-}
.ui-datepicker select.ui-datepicker-month,
.ui-datepicker select.ui-datepicker-year {
width: 49%;
diff --git a/themes/base/jquery.ui.spinner.css b/themes/base/jquery.ui.spinner.css
index 1504fc3f7..db05c520b 100644
--- a/themes/base/jquery.ui.spinner.css
+++ b/themes/base/jquery.ui.spinner.css
@@ -38,13 +38,13 @@
overflow: hidden;
right: 0;
}
-/* more specificity required here to overide default borders */
+/* more specificity required here to override default borders */
.ui-spinner a.ui-spinner-button {
border-top: none;
border-bottom: none;
border-right: none;
}
-/* vertical centre icon */
+/* vertically center icon */
.ui-spinner .ui-icon {
position: absolute;
margin-top: -8px;
diff --git a/themes/base/jquery.ui.tabs.css b/themes/base/jquery.ui.tabs.css
index b8f77b040..4994f210a 100644
--- a/themes/base/jquery.ui.tabs.css
+++ b/themes/base/jquery.ui.tabs.css
@@ -26,7 +26,7 @@
padding: 0;
white-space: nowrap;
}
-.ui-tabs .ui-tabs-nav li a {
+.ui-tabs .ui-tabs-nav .ui-tabs-anchor {
float: left;
padding: .5em 1em;
text-decoration: none;
@@ -35,13 +35,12 @@
margin-bottom: -1px;
padding-bottom: 1px;
}
-.ui-tabs .ui-tabs-nav li.ui-tabs-active a,
-.ui-tabs .ui-tabs-nav li.ui-state-disabled a,
-.ui-tabs .ui-tabs-nav li.ui-tabs-loading a {
+.ui-tabs .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor,
+.ui-tabs .ui-tabs-nav li.ui-state-disabled .ui-tabs-anchor,
+.ui-tabs .ui-tabs-nav li.ui-tabs-loading .ui-tabs-anchor {
cursor: text;
}
-.ui-tabs .ui-tabs-nav li a, /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
-.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active a {
+.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor {
cursor: pointer;
}
.ui-tabs .ui-tabs-panel {
diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js
index 16095292c..b94757505 100644
--- a/ui/jquery.ui.dialog.js
+++ b/ui/jquery.ui.dialog.js
@@ -454,10 +454,15 @@ $.widget( "ui.dialog", {
that._trigger( "drag", event, filteredUi( ui ) );
},
stop: function( event, ui ) {
- options.position = [
- ui.position.left - that.document.scrollLeft(),
- ui.position.top - that.document.scrollTop()
- ];
+ var left = ui.offset.left - that.document.scrollLeft(),
+ top = ui.offset.top - that.document.scrollTop();
+
+ options.position = {
+ my: "left top",
+ at: "left" + (left >= 0 ? "+" : "") + left + " " +
+ "top" + (top >= 0 ? "+" : "") + top,
+ of: that.window
+ };
$( this ).removeClass("ui-dialog-dragging");
that._unblockFrames();
that._trigger( "dragStop", event, filteredUi( ui ) );
@@ -503,8 +508,18 @@ $.widget( "ui.dialog", {
that._trigger( "resize", event, filteredUi( ui ) );
},
stop: function( event, ui ) {
- options.height = $( this ).height();
- options.width = $( this ).width();
+ var offset = that.uiDialog.offset(),
+ left = offset.left - that.document.scrollLeft(),
+ top = offset.top - that.document.scrollTop();
+
+ options.height = that.uiDialog.height();
+ options.width = that.uiDialog.width();
+ options.position = {
+ my: "left top",
+ at: "left" + (left >= 0 ? "+" : "") + left + " " +
+ "top" + (top >= 0 ? "+" : "") + top,
+ of: that.window
+ };
$( this ).removeClass("ui-dialog-resizing");
that._unblockFrames();
that._trigger( "resizeStop", event, filteredUi( ui ) );
diff --git a/ui/jquery.ui.slider.js b/ui/jquery.ui.slider.js
index ee7b3538f..e4f1cf7c9 100644
--- a/ui/jquery.ui.slider.js
+++ b/ui/jquery.ui.slider.js
@@ -131,7 +131,10 @@ $.widget( "ui.slider", $.ui.mouse, {
this.range.addClass( classes +
( ( options.range === "min" || options.range === "max" ) ? " ui-slider-range-" + options.range : "" ) );
} else {
- this.range = $([]);
+ if ( this.range ) {
+ this.range.remove();
+ }
+ this.range = null;
}
},
@@ -145,7 +148,9 @@ $.widget( "ui.slider", $.ui.mouse, {
_destroy: function() {
this.handles.remove();
- this.range.remove();
+ if ( this.range ) {
+ this.range.remove();
+ }
this.element
.removeClass( "ui-slider" +