jquery-mobile-rails-assets 1.4.0 → 1.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/images/jquery-mobile/icons-png/action-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/action-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/alert-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/alert-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-d-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-d-l-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-d-l-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-d-r-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-d-r-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-d-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-l-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-l-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-r-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-r-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-u-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-u-l-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-u-l-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-u-r-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-u-r-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/arrow-u-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/audio-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/audio-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/back-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/back-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/bars-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/bars-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/bullets-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/bullets-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/calendar-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/calendar-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/camera-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/camera-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-d-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-d-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-l-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-l-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-r-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-r-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-u-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/carat-u-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/check-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/check-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/clock-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/clock-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/cloud-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/cloud-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/comment-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/comment-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/delete-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/delete-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/edit-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/edit-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/eye-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/eye-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/forbidden-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/forbidden-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/forward-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/forward-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/gear-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/gear-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/grid-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/grid-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/heart-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/heart-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/home-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/home-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/info-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/info-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/location-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/location-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/lock-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/lock-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/mail-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/mail-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/minus-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/minus-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/navigation-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/navigation-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/phone-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/phone-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/plus-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/plus-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/power-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/power-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/recycle-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/recycle-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/refresh-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/refresh-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/search-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/search-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/shop-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/shop-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/star-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/star-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/tag-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/tag-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/user-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/user-white.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/video-black.png +0 -0
- data/app/assets/images/jquery-mobile/icons-png/video-white.png +0 -0
- data/app/assets/javascripts/jquery.mobile.js +410 -215
- data/app/assets/stylesheets/jquery.mobile.css.scss +282 -333
- data/lib/jquery-mobile-rails-assets/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 14d90189b04e73974d202af3acf5cad4b2fa975f
|
4
|
+
data.tar.gz: 8e8159b89d1abc2ab9528dd8cad665b33485c0aa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0d8e2479efec2c29d21b83cf2e9ba2e09d32e591db672ddfddd574715bdad8c5c3bd08302f18f4b933025bf7fbec2efcb478ea15a29971cbaa6e6a20e75458ea
|
7
|
+
data.tar.gz: fa870275e2fbf6dcaaea1c4fae7d53c2be587b693989771588272cb1341d1b01e65a52b8593587512568e2db7f282173628f07892ca4b450d73bb02815cd5c6e
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -1,9 +1,9 @@
|
|
1
1
|
/*!
|
2
|
-
* jQuery Mobile 1.4.
|
3
|
-
* Git HEAD hash:
|
2
|
+
* jQuery Mobile 1.4.1
|
3
|
+
* Git HEAD hash: 18c1e32bfc4e0e92756dedc105d799131607f5bb <> Date: Wed Feb 12 2014 22:15:20 UTC
|
4
4
|
* http://jquerymobile.com
|
5
5
|
*
|
6
|
-
* Copyright 2010,
|
6
|
+
* Copyright 2010, 2014 jQuery Foundation, Inc. and other contributors
|
7
7
|
* Released under the MIT license.
|
8
8
|
* http://jquery.org/license
|
9
9
|
*
|
@@ -30,7 +30,7 @@
|
|
30
30
|
$.extend( $.mobile, {
|
31
31
|
|
32
32
|
// Version of the jQuery Mobile Framework
|
33
|
-
version: "1.4.
|
33
|
+
version: "1.4.1",
|
34
34
|
|
35
35
|
// Deprecated and no longer used in 1.4 remove in 1.5
|
36
36
|
// Define the url parameter used for referencing widget-generated sub-pages.
|
@@ -517,6 +517,7 @@ $.ui.plugin = {
|
|
517
517
|
};
|
518
518
|
|
519
519
|
})( jQuery );
|
520
|
+
|
520
521
|
(function( $, window, undefined ) {
|
521
522
|
|
522
523
|
$.extend( $.mobile, {
|
@@ -792,7 +793,7 @@ $.ui.plugin = {
|
|
792
793
|
|
793
794
|
|
794
795
|
/*!
|
795
|
-
* jQuery UI Widget
|
796
|
+
* jQuery UI Widget c0ab71056b936627e8a7821f03c044aec6280a40
|
796
797
|
* http://jqueryui.com
|
797
798
|
*
|
798
799
|
* Copyright 2013 jQuery Foundation and other contributors
|
@@ -1482,8 +1483,17 @@ $.mobile.widget = $.Widget;
|
|
1482
1483
|
})(jQuery, this);
|
1483
1484
|
|
1484
1485
|
|
1486
|
+
/*!
|
1487
|
+
* jQuery hashchange event - v1.3 - 7/21/2010
|
1488
|
+
* http://benalman.com/projects/jquery-hashchange-plugin/
|
1489
|
+
*
|
1490
|
+
* Copyright (c) 2010 "Cowboy" Ben Alman
|
1491
|
+
* Dual licensed under the MIT and GPL licenses.
|
1492
|
+
* http://benalman.com/about/license/
|
1493
|
+
*/
|
1494
|
+
|
1485
1495
|
// Script: jQuery hashchange event
|
1486
|
-
//
|
1496
|
+
//
|
1487
1497
|
// *Version: 1.3, Last updated: 7/21/2010*
|
1488
1498
|
//
|
1489
1499
|
// Project Home - http://benalman.com/projects/jquery-hashchange-plugin/
|
@@ -1560,7 +1570,9 @@ $.mobile.widget = $.Widget;
|
|
1560
1570
|
// extra awesomeness that BBQ provides. This plugin will be included as
|
1561
1571
|
// part of jQuery BBQ, but also be available separately.
|
1562
1572
|
|
1563
|
-
(function(
|
1573
|
+
(function($,window,undefined){
|
1574
|
+
'$:nomunge'; // Used by YUI compressor.
|
1575
|
+
|
1564
1576
|
// Reused string.
|
1565
1577
|
var str_hashchange = 'hashchange',
|
1566
1578
|
|
@@ -1726,14 +1738,14 @@ $.mobile.widget = $.Widget;
|
|
1726
1738
|
// event for browsers that don't natively support it, including creating a
|
1727
1739
|
// polling loop to watch for hash changes and in IE 6/7 creating a hidden
|
1728
1740
|
// Iframe to enable back and forward.
|
1729
|
-
fake_onhashchange = (function()
|
1741
|
+
fake_onhashchange = (function(){
|
1730
1742
|
var self = {},
|
1731
1743
|
timeout_id,
|
1732
1744
|
|
1733
1745
|
// Remember the initial hash so it doesn't get triggered immediately.
|
1734
1746
|
last_hash = get_fragment(),
|
1735
1747
|
|
1736
|
-
fn_retval = function(
|
1748
|
+
fn_retval = function(val){ return val; },
|
1737
1749
|
history_set = fn_retval,
|
1738
1750
|
history_get = fn_retval;
|
1739
1751
|
|
@@ -1770,7 +1782,7 @@ $.mobile.widget = $.Widget;
|
|
1770
1782
|
// vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
|
1771
1783
|
// vvvvvvvvvvvvvvvvvvv REMOVE IF NOT SUPPORTING IE6/7/8 vvvvvvvvvvvvvvvvvvv
|
1772
1784
|
// vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
|
1773
|
-
window.attachEvent && !window.addEventListener && !supports_onhashchange && (function()
|
1785
|
+
window.attachEvent && !window.addEventListener && !supports_onhashchange && (function(){
|
1774
1786
|
// Not only do IE6/7 need the "magical" Iframe treatment, but so does IE8
|
1775
1787
|
// when running in "IE7 compatibility" mode.
|
1776
1788
|
|
@@ -1779,7 +1791,7 @@ $.mobile.widget = $.Widget;
|
|
1779
1791
|
|
1780
1792
|
// When the event is bound and polling starts in IE 6/7, create a hidden
|
1781
1793
|
// Iframe for history handling.
|
1782
|
-
self.start = function()
|
1794
|
+
self.start = function(){
|
1783
1795
|
if ( !iframe ) {
|
1784
1796
|
iframe_src = $.fn[ str_hashchange ].src;
|
1785
1797
|
iframe_src = iframe_src && iframe_src + get_fragment();
|
@@ -1790,7 +1802,7 @@ $.mobile.widget = $.Widget;
|
|
1790
1802
|
|
1791
1803
|
// When Iframe has completely loaded, initialize the history and
|
1792
1804
|
// start polling.
|
1793
|
-
.one( 'load', function()
|
1805
|
+
.one( 'load', function(){
|
1794
1806
|
iframe_src || history_set( get_fragment() );
|
1795
1807
|
poll();
|
1796
1808
|
})
|
@@ -1806,7 +1818,7 @@ $.mobile.widget = $.Widget;
|
|
1806
1818
|
// prettify the back/next history menu entries. Since IE sometimes
|
1807
1819
|
// errors with "Unspecified error" the very first time this is set
|
1808
1820
|
// (yes, very useful) wrap this with a try/catch block.
|
1809
|
-
doc.onpropertychange = function()
|
1821
|
+
doc.onpropertychange = function(){
|
1810
1822
|
try {
|
1811
1823
|
if ( event.propertyName === 'title' ) {
|
1812
1824
|
iframe.document.title = doc.title;
|
@@ -1843,7 +1855,7 @@ $.mobile.widget = $.Widget;
|
|
1843
1855
|
iframe_doc.open();
|
1844
1856
|
|
1845
1857
|
// Set document.domain for the Iframe document as well, if necessary.
|
1846
|
-
domain && iframe_doc.write( '<script>document.domain="' + domain + '"
|
1858
|
+
domain && iframe_doc.write( '<script>document.domain="' + domain + '"</script>' );
|
1847
1859
|
|
1848
1860
|
iframe_doc.close();
|
1849
1861
|
|
@@ -1867,8 +1879,6 @@ $.mobile.widget = $.Widget;
|
|
1867
1879
|
/*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas. Dual MIT/BSD license */
|
1868
1880
|
window.matchMedia = window.matchMedia || (function( doc, undefined ) {
|
1869
1881
|
|
1870
|
-
|
1871
|
-
|
1872
1882
|
var bool,
|
1873
1883
|
docElem = doc.documentElement,
|
1874
1884
|
refNode = docElem.firstElementChild || docElem.firstChild,
|
@@ -1940,43 +1950,10 @@ var fakeBody = $( "<body>" ).prependTo( "html" ),
|
|
1940
1950
|
fbCSS = fakeBody[ 0 ].style,
|
1941
1951
|
vendors = [ "Webkit", "Moz", "O" ],
|
1942
1952
|
webos = "palmGetResource" in window, //only used to rule out scrollTop
|
1943
|
-
opera = window.opera,
|
1944
1953
|
operamini = window.operamini && ({}).toString.call( window.operamini ) === "[object OperaMini]",
|
1945
1954
|
bb = window.blackberry && !propExists( "-webkit-transform" ), //only used to rule out box shadow, as it's filled opaque on BB 5 and lower
|
1946
1955
|
nokiaLTE7_3;
|
1947
1956
|
|
1948
|
-
function validStyle( prop, value, check_vend ) {
|
1949
|
-
var div = document.createElement( "div" ),
|
1950
|
-
uc = function( txt ) {
|
1951
|
-
return txt.charAt( 0 ).toUpperCase() + txt.substr( 1 );
|
1952
|
-
},
|
1953
|
-
vend_pref = function( vend ) {
|
1954
|
-
if ( vend === "" ) {
|
1955
|
-
return "";
|
1956
|
-
} else {
|
1957
|
-
return "-" + vend.charAt( 0 ).toLowerCase() + vend.substr( 1 ) + "-";
|
1958
|
-
}
|
1959
|
-
},
|
1960
|
-
check_style = function( vend ) {
|
1961
|
-
var vend_prop = vend_pref( vend ) + prop + ": " + value + ";",
|
1962
|
-
uc_vend = uc( vend ),
|
1963
|
-
propStyle = uc_vend + ( uc_vend === "" ? prop : uc( prop ) );
|
1964
|
-
|
1965
|
-
div.setAttribute( "style", vend_prop );
|
1966
|
-
|
1967
|
-
if ( !!div.style[ propStyle ] ) {
|
1968
|
-
ret = true;
|
1969
|
-
}
|
1970
|
-
},
|
1971
|
-
check_vends = check_vend ? check_vend : vendors,
|
1972
|
-
i, ret;
|
1973
|
-
|
1974
|
-
for( i = 0; i < check_vends.length; i++ ) {
|
1975
|
-
check_style( check_vends[i] );
|
1976
|
-
}
|
1977
|
-
return !!ret;
|
1978
|
-
}
|
1979
|
-
|
1980
1957
|
// inline SVG support test
|
1981
1958
|
function inlineSVG() {
|
1982
1959
|
// Thanks Modernizr & Erik Dahlstrom
|
@@ -2123,10 +2100,6 @@ function fixedPosition() {
|
|
2123
2100
|
}
|
2124
2101
|
|
2125
2102
|
$.extend( $.support, {
|
2126
|
-
cssTransitions: "WebKitTransitionEvent" in window ||
|
2127
|
-
validStyle( "transition", "height 100ms linear", [ "Webkit", "Moz", "" ] ) &&
|
2128
|
-
!$.mobile.browser.oldIE && !opera,
|
2129
|
-
|
2130
2103
|
// Note, Chrome for iOS has an extremely quirky implementation of popstate.
|
2131
2104
|
// We've chosen to take the shortest path to a bug fix here for issue #5426
|
2132
2105
|
// See the following link for information about the regex chosen
|
@@ -2141,7 +2114,6 @@ $.extend( $.support, {
|
|
2141
2114
|
cssPseudoElement: !!propExists( "content" ),
|
2142
2115
|
touchOverflow: !!propExists( "overflowScrolling" ),
|
2143
2116
|
cssTransform3d: transform3dTest(),
|
2144
|
-
cssAnimations: !!propExists( "animationName" ),
|
2145
2117
|
boxShadow: !!propExists( "boxShadow" ) && !bb,
|
2146
2118
|
fixedPosition: fixedPosition(),
|
2147
2119
|
scrollTop: ("pageXOffset" in window ||
|
@@ -3155,6 +3127,101 @@ if ( !$.support.boxShadow ) {
|
|
3155
3127
|
})( jQuery );
|
3156
3128
|
|
3157
3129
|
|
3130
|
+
(function( $, undefined ) {
|
3131
|
+
var props = {
|
3132
|
+
"animation": {},
|
3133
|
+
"transition": {}
|
3134
|
+
},
|
3135
|
+
testElement = document.createElement( "a" ),
|
3136
|
+
vendorPrefixes = [ "", "webkit-", "moz-", "o-" ];
|
3137
|
+
|
3138
|
+
$.each( [ "animation", "transition" ], function( i, test ) {
|
3139
|
+
|
3140
|
+
// Get correct name for test
|
3141
|
+
var testName = ( i === 0 ) ? test + "-" + "name" : test;
|
3142
|
+
|
3143
|
+
$.each( vendorPrefixes, function( j, prefix ) {
|
3144
|
+
if ( testElement.style[ $.camelCase( prefix + testName ) ] !== undefined ) {
|
3145
|
+
props[ test ][ "prefix" ] = prefix;
|
3146
|
+
return false;
|
3147
|
+
}
|
3148
|
+
});
|
3149
|
+
|
3150
|
+
// Set event and duration names for later use
|
3151
|
+
props[ test ][ "duration" ] =
|
3152
|
+
$.camelCase( props[ test ][ "prefix" ] + test + "-" + "duration" );
|
3153
|
+
props[ test ][ "event" ] =
|
3154
|
+
$.camelCase( props[ test ][ "prefix" ] + test + "-" + "end" );
|
3155
|
+
|
3156
|
+
// All lower case if not a vendor prop
|
3157
|
+
if ( props[ test ][ "prefix" ] === "" ) {
|
3158
|
+
props[ test ][ "duration" ] = props[ test ][ "duration" ].toLowerCase();
|
3159
|
+
props[ test ][ "event" ] = props[ test ][ "event" ].toLowerCase();
|
3160
|
+
}
|
3161
|
+
});
|
3162
|
+
|
3163
|
+
// If a valid prefix was found then the it is supported by the browser
|
3164
|
+
$.support.cssTransitions = ( props[ "transition" ][ "prefix" ] !== undefined );
|
3165
|
+
$.support.cssAnimations = ( props[ "animation" ][ "prefix" ] !== undefined );
|
3166
|
+
|
3167
|
+
// Remove the testElement
|
3168
|
+
$( testElement ).remove();
|
3169
|
+
|
3170
|
+
// Animation complete callback
|
3171
|
+
$.fn.animationComplete = function( callback, type, fallbackTime ) {
|
3172
|
+
var timer, duration,
|
3173
|
+
that = this,
|
3174
|
+
animationType = ( !type || type === "animation" ) ? "animation" : "transition";
|
3175
|
+
|
3176
|
+
// Make sure selected type is supported by browser
|
3177
|
+
if ( ( $.support.cssTransitions && animationType === "transition" ) ||
|
3178
|
+
( $.support.cssAnimations && animationType === "animation" ) ) {
|
3179
|
+
|
3180
|
+
// If a fallback time was not passed set one
|
3181
|
+
if ( fallbackTime === undefined ) {
|
3182
|
+
|
3183
|
+
// Make sure the was not bound to document before checking .css
|
3184
|
+
if ( $( this ).context !== document ) {
|
3185
|
+
|
3186
|
+
// Parse the durration since its in second multiple by 1000 for milliseconds
|
3187
|
+
// Multiply by 3 to make sure we give the animation plenty of time.
|
3188
|
+
duration = parseFloat(
|
3189
|
+
$( this ).css( props[ animationType ].duration )
|
3190
|
+
) * 3000;
|
3191
|
+
}
|
3192
|
+
|
3193
|
+
// If we could not read a duration use the default
|
3194
|
+
if ( duration === 0 || duration === undefined ) {
|
3195
|
+
duration = $.fn.animationComplete.default;
|
3196
|
+
}
|
3197
|
+
}
|
3198
|
+
|
3199
|
+
// Sets up the fallback if event never comes
|
3200
|
+
timer = setTimeout( function() {
|
3201
|
+
$( that ).off( props[ animationType ].event );
|
3202
|
+
callback.apply( that );
|
3203
|
+
}, duration );
|
3204
|
+
|
3205
|
+
// Bind the event
|
3206
|
+
return $( this ).one( props[ animationType ].event, function() {
|
3207
|
+
|
3208
|
+
// Clear the timer so we dont call callback twice
|
3209
|
+
clearTimeout( timer );
|
3210
|
+
callback.call( this, arguments );
|
3211
|
+
});
|
3212
|
+
} else {
|
3213
|
+
|
3214
|
+
// CSS animation / transitions not supported
|
3215
|
+
// Defer execution for consistency between webkit/non webkit
|
3216
|
+
setTimeout( $.proxy( callback, this ), 0 );
|
3217
|
+
return $( this );
|
3218
|
+
}
|
3219
|
+
};
|
3220
|
+
|
3221
|
+
// Allow default callback to be configured on mobileInit
|
3222
|
+
$.fn.animationComplete.default = 1000;
|
3223
|
+
})( jQuery );
|
3224
|
+
|
3158
3225
|
// This plugin is an experiment for abstracting away the touch and mouse
|
3159
3226
|
// events so that developers don't have to worry about which method of input
|
3160
3227
|
// the device their document is loaded on supports.
|
@@ -3683,10 +3750,14 @@ if ( eventCaptureSupported ) {
|
|
3683
3750
|
}
|
3684
3751
|
});
|
3685
3752
|
|
3686
|
-
function triggerCustomEvent( obj, eventType, event ) {
|
3753
|
+
function triggerCustomEvent( obj, eventType, event, bubble ) {
|
3687
3754
|
var originalType = event.type;
|
3688
3755
|
event.type = eventType;
|
3689
|
-
|
3756
|
+
if ( bubble ) {
|
3757
|
+
$.event.trigger( event, undefined, obj );
|
3758
|
+
} else {
|
3759
|
+
$.event.dispatch.call( obj, event );
|
3760
|
+
}
|
3690
3761
|
event.type = originalType;
|
3691
3762
|
}
|
3692
3763
|
|
@@ -3788,32 +3859,67 @@ if ( eventCaptureSupported ) {
|
|
3788
3859
|
}
|
3789
3860
|
};
|
3790
3861
|
|
3791
|
-
//
|
3862
|
+
// Also handles swipeleft, swiperight
|
3792
3863
|
$.event.special.swipe = {
|
3793
|
-
scrollSupressionThreshold: 30, // More than this horizontal displacement, and we will suppress scrolling.
|
3794
3864
|
|
3795
|
-
|
3865
|
+
// More than this horizontal displacement, and we will suppress scrolling.
|
3866
|
+
scrollSupressionThreshold: 30,
|
3867
|
+
|
3868
|
+
// More time than this, and it isn't a swipe.
|
3869
|
+
durationThreshold: 1000,
|
3870
|
+
|
3871
|
+
// Swipe horizontal displacement must be more than this.
|
3872
|
+
horizontalDistanceThreshold: 30,
|
3873
|
+
|
3874
|
+
// Swipe vertical displacement must be less than this.
|
3875
|
+
verticalDistanceThreshold: 30,
|
3876
|
+
|
3877
|
+
getLocation: function ( event ) {
|
3878
|
+
var winPageX = window.pageXOffset,
|
3879
|
+
winPageY = window.pageYOffset,
|
3880
|
+
x = event.clientX,
|
3881
|
+
y = event.clientY;
|
3882
|
+
|
3883
|
+
if ( event.pageY === 0 && Math.floor( y ) > Math.floor( event.pageY ) ||
|
3884
|
+
event.pageX === 0 && Math.floor( x ) > Math.floor( event.pageX ) ) {
|
3796
3885
|
|
3797
|
-
|
3886
|
+
// iOS4 clientX/clientY have the value that should have been
|
3887
|
+
// in pageX/pageY. While pageX/page/ have the value 0
|
3888
|
+
x = x - winPageX;
|
3889
|
+
y = y - winPageY;
|
3890
|
+
} else if ( y < ( event.pageY - winPageY) || x < ( event.pageX - winPageX ) ) {
|
3798
3891
|
|
3799
|
-
|
3892
|
+
// Some Android browsers have totally bogus values for clientX/Y
|
3893
|
+
// when scrolling/zooming a page. Detectable since clientX/clientY
|
3894
|
+
// should never be smaller than pageX/pageY minus page scroll
|
3895
|
+
x = event.pageX - winPageX;
|
3896
|
+
y = event.pageY - winPageY;
|
3897
|
+
}
|
3898
|
+
|
3899
|
+
return {
|
3900
|
+
x: x,
|
3901
|
+
y: y
|
3902
|
+
};
|
3903
|
+
},
|
3800
3904
|
|
3801
3905
|
start: function( event ) {
|
3802
3906
|
var data = event.originalEvent.touches ?
|
3803
|
-
event.originalEvent.touches[ 0 ] : event
|
3907
|
+
event.originalEvent.touches[ 0 ] : event,
|
3908
|
+
location = $.event.special.swipe.getLocation( data );
|
3804
3909
|
return {
|
3805
3910
|
time: ( new Date() ).getTime(),
|
3806
|
-
coords: [
|
3911
|
+
coords: [ location.x, location.y ],
|
3807
3912
|
origin: $( event.target )
|
3808
3913
|
};
|
3809
3914
|
},
|
3810
3915
|
|
3811
3916
|
stop: function( event ) {
|
3812
3917
|
var data = event.originalEvent.touches ?
|
3813
|
-
event.originalEvent.touches[ 0 ] : event
|
3918
|
+
event.originalEvent.touches[ 0 ] : event,
|
3919
|
+
location = $.event.special.swipe.getLocation( data );
|
3814
3920
|
return {
|
3815
3921
|
time: ( new Date() ).getTime(),
|
3816
|
-
coords: [
|
3922
|
+
coords: [ location.x, location.y ]
|
3817
3923
|
};
|
3818
3924
|
},
|
3819
3925
|
|
@@ -3823,25 +3929,47 @@ if ( eventCaptureSupported ) {
|
|
3823
3929
|
Math.abs( start.coords[ 1 ] - stop.coords[ 1 ] ) < $.event.special.swipe.verticalDistanceThreshold ) {
|
3824
3930
|
var direction = start.coords[0] > stop.coords[ 0 ] ? "swipeleft" : "swiperight";
|
3825
3931
|
|
3826
|
-
triggerCustomEvent( thisObject, "swipe", $.Event( "swipe", { target: origTarget, swipestart: start, swipestop: stop }) );
|
3827
|
-
triggerCustomEvent( thisObject, direction,$.Event( direction, { target: origTarget, swipestart: start, swipestop: stop } ) );
|
3932
|
+
triggerCustomEvent( thisObject, "swipe", $.Event( "swipe", { target: origTarget, swipestart: start, swipestop: stop }), true );
|
3933
|
+
triggerCustomEvent( thisObject, direction,$.Event( direction, { target: origTarget, swipestart: start, swipestop: stop } ), true );
|
3828
3934
|
return true;
|
3829
3935
|
}
|
3830
3936
|
return false;
|
3831
3937
|
|
3832
3938
|
},
|
3833
3939
|
|
3940
|
+
// This serves as a flag to ensure that at most one swipe event event is
|
3941
|
+
// in work at any given time
|
3942
|
+
eventInProgress: false,
|
3943
|
+
|
3834
3944
|
setup: function() {
|
3835
|
-
var
|
3836
|
-
|
3945
|
+
var events,
|
3946
|
+
thisObject = this,
|
3947
|
+
$this = $( thisObject ),
|
3948
|
+
context = {};
|
3949
|
+
|
3950
|
+
// Retrieve the events data for this element and add the swipe context
|
3951
|
+
events = $.data( this, "mobile-events" );
|
3952
|
+
if ( !events ) {
|
3953
|
+
events = { length: 0 };
|
3954
|
+
$.data( this, "mobile-events", events );
|
3955
|
+
}
|
3956
|
+
events.length++;
|
3957
|
+
events.swipe = context;
|
3958
|
+
|
3959
|
+
context.start = function( event ) {
|
3960
|
+
|
3961
|
+
// Bail if we're already working on a swipe event
|
3962
|
+
if ( $.event.special.swipe.eventInProgress ) {
|
3963
|
+
return;
|
3964
|
+
}
|
3965
|
+
$.event.special.swipe.eventInProgress = true;
|
3837
3966
|
|
3838
|
-
$this.bind( touchStartEvent, function( event ) {
|
3839
3967
|
var stop,
|
3840
3968
|
start = $.event.special.swipe.start( event ),
|
3841
3969
|
origTarget = event.target,
|
3842
3970
|
emitted = false;
|
3843
3971
|
|
3844
|
-
function
|
3972
|
+
context.move = function( event ) {
|
3845
3973
|
if ( !start ) {
|
3846
3974
|
return;
|
3847
3975
|
}
|
@@ -3849,23 +3977,57 @@ if ( eventCaptureSupported ) {
|
|
3849
3977
|
stop = $.event.special.swipe.stop( event );
|
3850
3978
|
if ( !emitted ) {
|
3851
3979
|
emitted = $.event.special.swipe.handleSwipe( start, stop, thisObject, origTarget );
|
3980
|
+
if ( emitted ) {
|
3981
|
+
|
3982
|
+
// Reset the context to make way for the next swipe event
|
3983
|
+
$.event.special.swipe.eventInProgress = false;
|
3984
|
+
}
|
3852
3985
|
}
|
3853
3986
|
// prevent scrolling
|
3854
3987
|
if ( Math.abs( start.coords[ 0 ] - stop.coords[ 0 ] ) > $.event.special.swipe.scrollSupressionThreshold ) {
|
3855
3988
|
event.preventDefault();
|
3856
3989
|
}
|
3857
|
-
}
|
3990
|
+
};
|
3858
3991
|
|
3859
|
-
|
3860
|
-
.one( touchStopEvent, function() {
|
3992
|
+
context.stop = function() {
|
3861
3993
|
emitted = true;
|
3862
|
-
|
3863
|
-
|
3864
|
-
|
3994
|
+
|
3995
|
+
// Reset the context to make way for the next swipe event
|
3996
|
+
$.event.special.swipe.eventInProgress = false;
|
3997
|
+
$document.off( touchMoveEvent, context.move );
|
3998
|
+
context.move = null;
|
3999
|
+
};
|
4000
|
+
|
4001
|
+
$document.on( touchMoveEvent, context.move )
|
4002
|
+
.one( touchStopEvent, context.stop );
|
4003
|
+
};
|
4004
|
+
$this.on( touchStartEvent, context.start );
|
3865
4005
|
},
|
3866
4006
|
|
3867
4007
|
teardown: function() {
|
3868
|
-
|
4008
|
+
var events, context;
|
4009
|
+
|
4010
|
+
events = $.data( this, "mobile-events" );
|
4011
|
+
if ( events ) {
|
4012
|
+
context = events.swipe;
|
4013
|
+
delete events.swipe;
|
4014
|
+
events.length--;
|
4015
|
+
if ( events.length === 0 ) {
|
4016
|
+
$.removeData( this, "mobile-events" );
|
4017
|
+
}
|
4018
|
+
}
|
4019
|
+
|
4020
|
+
if ( context ) {
|
4021
|
+
if ( context.start ) {
|
4022
|
+
$( this ).off( touchStartEvent, context.start );
|
4023
|
+
}
|
4024
|
+
if ( context.move ) {
|
4025
|
+
$document.off( touchMoveEvent, context.move );
|
4026
|
+
}
|
4027
|
+
if ( context.stop ) {
|
4028
|
+
$document.off( touchStopEvent, context.stop );
|
4029
|
+
}
|
4030
|
+
}
|
3869
4031
|
}
|
3870
4032
|
};
|
3871
4033
|
$.each({
|
@@ -4259,7 +4421,7 @@ $.widget( "mobile.page", {
|
|
4259
4421
|
|
4260
4422
|
_setOptions: function( o ) {
|
4261
4423
|
if ( o.theme !== undefined ) {
|
4262
|
-
this.element.removeClass( "ui-
|
4424
|
+
this.element.removeClass( "ui-page-theme-" + this.options.theme ).addClass( "ui-page-theme-" + o.theme );
|
4263
4425
|
}
|
4264
4426
|
|
4265
4427
|
if ( o.contentTheme !== undefined ) {
|
@@ -5537,7 +5699,7 @@ $.widget( "mobile.page", {
|
|
5537
5699
|
}
|
5538
5700
|
};
|
5539
5701
|
|
5540
|
-
//
|
5702
|
+
// Direct focus to the page title, or otherwise first focusable element
|
5541
5703
|
$.mobile.focusPage = function ( page ) {
|
5542
5704
|
var autofocus = page.find( "[autofocus]" ),
|
5543
5705
|
pageTitle = page.find( ".ui-title:eq(0)" );
|
@@ -5559,19 +5721,7 @@ $.widget( "mobile.page", {
|
|
5559
5721
|
return transition;
|
5560
5722
|
};
|
5561
5723
|
|
5562
|
-
|
5563
|
-
|
5564
|
-
//animation complete callback
|
5565
|
-
$.fn.animationComplete = function( callback ) {
|
5566
|
-
if ( $.support.cssTransitions ) {
|
5567
|
-
return $( this ).one( "webkitAnimationEnd animationend", callback );
|
5568
|
-
}
|
5569
|
-
else{
|
5570
|
-
// defer execution for consistency between webkit/non webkit
|
5571
|
-
setTimeout( callback, 0 );
|
5572
|
-
return $( this );
|
5573
|
-
}
|
5574
|
-
};
|
5724
|
+
// Exposed $.mobile methods
|
5575
5725
|
|
5576
5726
|
$.mobile.changePage = function( to, options ) {
|
5577
5727
|
$.mobile.pageContainer.pagecontainer( "change", to, options );
|
@@ -5990,17 +6140,15 @@ $.widget( "mobile.page", {
|
|
5990
6140
|
}
|
5991
6141
|
});
|
5992
6142
|
|
5993
|
-
if ( !none ) {
|
5994
|
-
this.$to.animationComplete( $.proxy(function() {
|
5995
|
-
this.doneIn();
|
5996
|
-
}, this ));
|
5997
|
-
}
|
5998
|
-
|
5999
6143
|
this.$to
|
6000
6144
|
.removeClass( this.toPreClass )
|
6001
6145
|
.addClass( this.name + " in " + reverseClass );
|
6002
6146
|
|
6003
|
-
if ( none ) {
|
6147
|
+
if ( !none ) {
|
6148
|
+
this.$to.animationComplete( $.proxy(function() {
|
6149
|
+
this.doneIn();
|
6150
|
+
}, this ));
|
6151
|
+
} else {
|
6004
6152
|
this.doneIn();
|
6005
6153
|
}
|
6006
6154
|
|
@@ -6369,7 +6517,6 @@ $.widget( "mobile.page", $.mobile.page, {
|
|
6369
6517
|
.attr( "data-" + $.mobile.ns + "rel", "back" )
|
6370
6518
|
.text( text || this.options.closeBtnText || "" )
|
6371
6519
|
.prependTo( dst );
|
6372
|
-
this._on( btn, { click: "close" } );
|
6373
6520
|
}
|
6374
6521
|
|
6375
6522
|
this._headerCloseButton = btn;
|
@@ -6538,7 +6685,12 @@ $.widget( "mobile.dialog", {
|
|
6538
6685
|
|
6539
6686
|
(function( $, undefined ) {
|
6540
6687
|
|
6541
|
-
var rInitialLetter = /([A-Z])/g
|
6688
|
+
var rInitialLetter = /([A-Z])/g,
|
6689
|
+
|
6690
|
+
// Construct iconpos class from iconpos value
|
6691
|
+
iconposClass = function( iconpos ) {
|
6692
|
+
return ( "ui-btn-icon-" + ( iconpos === null ? "left" : iconpos ) );
|
6693
|
+
};
|
6542
6694
|
|
6543
6695
|
$.widget( "mobile.collapsible", {
|
6544
6696
|
options: {
|
@@ -6561,14 +6713,15 @@ $.widget( "mobile.collapsible", {
|
|
6561
6713
|
var elem = this.element,
|
6562
6714
|
ui = {
|
6563
6715
|
accordion: elem
|
6564
|
-
.closest( ":jqmData(role='collapsible-set')" +
|
6565
|
-
|
6716
|
+
.closest( ":jqmData(role='collapsible-set')," +
|
6717
|
+
":jqmData(role='collapsibleset')" +
|
6718
|
+
( $.mobile.collapsibleset ? ", :mobile-collapsibleset" :
|
6719
|
+
"" ) )
|
6566
6720
|
.addClass( "ui-collapsible-set" )
|
6567
6721
|
};
|
6568
6722
|
|
6569
|
-
|
6570
|
-
|
6571
|
-
});
|
6723
|
+
this._ui = ui;
|
6724
|
+
this._renderedOptions = this._getOptions( this.options );
|
6572
6725
|
|
6573
6726
|
if ( this.options.enhanced ) {
|
6574
6727
|
ui.heading = $( ".ui-collapsible-heading", this.element[ 0 ] );
|
@@ -6632,7 +6785,7 @@ $.widget( "mobile.collapsible", {
|
|
6632
6785
|
|
6633
6786
|
_enhance: function( elem, ui ) {
|
6634
6787
|
var iconclass,
|
6635
|
-
opts = this.
|
6788
|
+
opts = this._renderedOptions,
|
6636
6789
|
contentThemeClass = this._themeClassFromOption( "ui-body-", opts.contentTheme );
|
6637
6790
|
|
6638
6791
|
elem.addClass( "ui-collapsible " +
|
@@ -6668,8 +6821,7 @@ $.widget( "mobile.collapsible", {
|
|
6668
6821
|
.first()
|
6669
6822
|
.addClass( "ui-btn " +
|
6670
6823
|
( iconclass ? iconclass + " " : "" ) +
|
6671
|
-
( iconclass ? (
|
6672
|
-
( opts.iconpos === "right" ? "right" : "left" ) ) +
|
6824
|
+
( iconclass ? iconposClass( opts.iconpos ) +
|
6673
6825
|
" " : "" ) +
|
6674
6826
|
this._themeClassFromOption( "ui-btn-", opts.theme ) + " " +
|
6675
6827
|
( opts.mini ? "ui-mini " : "" ) );
|
@@ -6683,19 +6835,14 @@ $.widget( "mobile.collapsible", {
|
|
6683
6835
|
},
|
6684
6836
|
|
6685
6837
|
refresh: function() {
|
6686
|
-
|
6687
|
-
|
6688
|
-
for ( key in $.mobile.collapsible.defaults ) {
|
6689
|
-
options[ key ] = this.options[ key ];
|
6690
|
-
}
|
6691
|
-
|
6692
|
-
this._setOptions( options );
|
6838
|
+
this._applyOptions( this.options );
|
6839
|
+
this._renderedOptions = this._getOptions( this.options );
|
6693
6840
|
},
|
6694
6841
|
|
6695
|
-
|
6842
|
+
_applyOptions: function( options ) {
|
6696
6843
|
var isCollapsed, newTheme, oldTheme, hasCorners,
|
6697
6844
|
elem = this.element,
|
6698
|
-
currentOpts = this.
|
6845
|
+
currentOpts = this._renderedOptions,
|
6699
6846
|
ui = this._ui,
|
6700
6847
|
anchor = ui.anchor,
|
6701
6848
|
status = ui.status,
|
@@ -6739,8 +6886,9 @@ $.widget( "mobile.collapsible", {
|
|
6739
6886
|
}
|
6740
6887
|
|
6741
6888
|
if ( opts.iconpos !== undefined ) {
|
6742
|
-
anchor
|
6743
|
-
|
6889
|
+
anchor
|
6890
|
+
.removeClass( iconposClass( currentOpts.iconpos ) )
|
6891
|
+
.addClass( iconposClass( opts.iconpos ) );
|
6744
6892
|
}
|
6745
6893
|
|
6746
6894
|
if ( opts.theme !== undefined ) {
|
@@ -6750,8 +6898,10 @@ $.widget( "mobile.collapsible", {
|
|
6750
6898
|
}
|
6751
6899
|
|
6752
6900
|
if ( opts.contentTheme !== undefined ) {
|
6753
|
-
oldTheme = this._themeClassFromOption( "ui-body-",
|
6754
|
-
|
6901
|
+
oldTheme = this._themeClassFromOption( "ui-body-",
|
6902
|
+
currentOpts.contentTheme );
|
6903
|
+
newTheme = this._themeClassFromOption( "ui-body-",
|
6904
|
+
opts.contentTheme );
|
6755
6905
|
ui.content.removeClass( oldTheme ).addClass( newTheme );
|
6756
6906
|
}
|
6757
6907
|
|
@@ -6771,12 +6921,16 @@ $.widget( "mobile.collapsible", {
|
|
6771
6921
|
if ( opts.mini !== undefined ) {
|
6772
6922
|
anchor.toggleClass( "ui-mini", opts.mini );
|
6773
6923
|
}
|
6924
|
+
},
|
6774
6925
|
|
6926
|
+
_setOptions: function( options ) {
|
6927
|
+
this._applyOptions( options );
|
6775
6928
|
this._super( options );
|
6929
|
+
this._renderedOptions = this._getOptions( this.options );
|
6776
6930
|
},
|
6777
6931
|
|
6778
6932
|
_handleExpandCollapse: function( isCollapse ) {
|
6779
|
-
var opts = this.
|
6933
|
+
var opts = this._renderedOptions,
|
6780
6934
|
ui = this._ui;
|
6781
6935
|
|
6782
6936
|
ui.status.text( isCollapse ? opts.expandCueText : opts.collapseCueText );
|
@@ -7542,7 +7696,7 @@ $.widget( "mobile.checkboxradio", $.extend( {
|
|
7542
7696
|
return $( "<div class='" +
|
7543
7697
|
( this.options.wrapperClass ? this.options.wrapperClass : "" ) +
|
7544
7698
|
" ui-" + this.inputtype +
|
7545
|
-
( this.options.disabled ? " ui-state-disabled" : "" ) + "' >" );
|
7699
|
+
( this.options.disabled ? " ui-state-disabled" : "" ) + "' ></div>" );
|
7546
7700
|
},
|
7547
7701
|
|
7548
7702
|
_handleInputFocus: function() {
|
@@ -8663,7 +8817,9 @@ $.widget( "mobile.slider", $.extend( {
|
|
8663
8817
|
_setDisabled: function( value ) {
|
8664
8818
|
value = !!value;
|
8665
8819
|
this.element.prop( "disabled", value );
|
8666
|
-
this.slider
|
8820
|
+
this.slider
|
8821
|
+
.toggleClass( "ui-state-disabled", value )
|
8822
|
+
.attr( "aria-disabled", value );
|
8667
8823
|
}
|
8668
8824
|
|
8669
8825
|
}, $.mobile.behaviors.formReset ) );
|
@@ -8724,6 +8880,7 @@ $.widget( "mobile.slider", $.mobile.slider, {
|
|
8724
8880
|
if ( value && !this._popup ) {
|
8725
8881
|
this._popup = getPopup()
|
8726
8882
|
.addClass( "ui-body-" + ( this.options.theme || "a" ) )
|
8883
|
+
.hide()
|
8727
8884
|
.insertBefore( this.element );
|
8728
8885
|
}
|
8729
8886
|
}
|
@@ -8812,6 +8969,16 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
8812
8969
|
|
8813
8970
|
this._handleFormReset();
|
8814
8971
|
|
8972
|
+
// Transfer tabindex to "on" element and make input unfocusable
|
8973
|
+
this._originalTabIndex = this.element.attr( "tabindex" );
|
8974
|
+
if ( this._originalTabIndex != null ) {
|
8975
|
+
this.on.attr( "tabindex", this._originalTabIndex );
|
8976
|
+
}
|
8977
|
+
this.element.attr( "tabindex", "-1" );
|
8978
|
+
this._on({
|
8979
|
+
"focus" : "_handleInputFocus"
|
8980
|
+
});
|
8981
|
+
|
8815
8982
|
if ( this.element.is( ":disabled" ) ) {
|
8816
8983
|
this._setOptions({
|
8817
8984
|
"disabled": true
|
@@ -8833,6 +9000,10 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
8833
9000
|
});
|
8834
9001
|
},
|
8835
9002
|
|
9003
|
+
_handleInputFocus: function() {
|
9004
|
+
this.on.focus();
|
9005
|
+
},
|
9006
|
+
|
8836
9007
|
widget: function() {
|
8837
9008
|
return this.flipswitch;
|
8838
9009
|
},
|
@@ -8862,7 +9033,11 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
8862
9033
|
options = this.options,
|
8863
9034
|
element = this.element,
|
8864
9035
|
theme = options.theme ? options.theme : "inherit",
|
8865
|
-
|
9036
|
+
|
9037
|
+
// The "on" button is an anchor so it's focusable
|
9038
|
+
on = $( "<a></a>", {
|
9039
|
+
"href": "#"
|
9040
|
+
}),
|
8866
9041
|
off = $( "<span></span>" ),
|
8867
9042
|
type = element.get( 0 ).tagName,
|
8868
9043
|
onText = ( type === "INPUT" ) ?
|
@@ -8972,6 +9147,11 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
8972
9147
|
if ( this.options.enhanced ) {
|
8973
9148
|
return;
|
8974
9149
|
}
|
9150
|
+
if ( this._originalTabIndex != null ) {
|
9151
|
+
this.element.attr( "tabindex", this._originalTabIndex );
|
9152
|
+
} else {
|
9153
|
+
this.element.removeAttr( "tabindex" );
|
9154
|
+
}
|
8975
9155
|
this.on.remove();
|
8976
9156
|
this.off.remove();
|
8977
9157
|
this.element.unwrap();
|
@@ -9314,7 +9494,8 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9314
9494
|
_setOptions: function( options ) {
|
9315
9495
|
this._super( options );
|
9316
9496
|
|
9317
|
-
if ( options.
|
9497
|
+
if ( options.clearBtn !== undefined &&
|
9498
|
+
!this.element.is( "textarea, :jqmData(type='range')" ) ) {
|
9318
9499
|
if ( options.clearBtn ) {
|
9319
9500
|
this._addClearBtn();
|
9320
9501
|
} else {
|
@@ -9323,7 +9504,8 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9323
9504
|
}
|
9324
9505
|
|
9325
9506
|
if ( options.clearBtnText !== undefined && this._clearBtn !== undefined ) {
|
9326
|
-
this._clearBtn.text( options.clearBtnText )
|
9507
|
+
this._clearBtn.text( options.clearBtnText )
|
9508
|
+
.attr("title", options.clearBtnText);
|
9327
9509
|
}
|
9328
9510
|
},
|
9329
9511
|
|
@@ -9336,8 +9518,9 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9336
9518
|
},
|
9337
9519
|
|
9338
9520
|
_destroyClear: function() {
|
9339
|
-
this.
|
9340
|
-
this._unbindClear()
|
9521
|
+
this.widget().removeClass( "ui-input-has-clear" );
|
9522
|
+
this._unbindClear();
|
9523
|
+
this._clearBtn.remove();
|
9341
9524
|
},
|
9342
9525
|
|
9343
9526
|
_destroy: function() {
|
@@ -9366,6 +9549,8 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9366
9549
|
},
|
9367
9550
|
|
9368
9551
|
_autogrow: function() {
|
9552
|
+
this.element.addClass( "ui-textinput-autogrow" );
|
9553
|
+
|
9369
9554
|
this._on({
|
9370
9555
|
"keyup": "_timeout",
|
9371
9556
|
"change": "_timeout",
|
@@ -9400,16 +9585,18 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9400
9585
|
if ( event.type !== "popupbeforeposition" ) {
|
9401
9586
|
this.element
|
9402
9587
|
.addClass( "ui-textinput-autogrow-resize" )
|
9403
|
-
.
|
9588
|
+
.animationComplete(
|
9404
9589
|
$.proxy( function() {
|
9405
9590
|
this.element.removeClass( "ui-textinput-autogrow-resize" );
|
9406
|
-
}, this )
|
9591
|
+
}, this ),
|
9592
|
+
"transition" );
|
9407
9593
|
}
|
9408
|
-
this.
|
9594
|
+
this._timeout();
|
9409
9595
|
}
|
9410
9596
|
},
|
9411
9597
|
|
9412
9598
|
_unbindAutogrow: function() {
|
9599
|
+
this.element.removeClass( "ui-textinput-autogrow" );
|
9413
9600
|
this._off( this.element, "keyup change input paste" );
|
9414
9601
|
this._off( this.document,
|
9415
9602
|
"pageshow popupbeforeposition updatelayout panelopen" );
|
@@ -9433,22 +9620,26 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9433
9620
|
},
|
9434
9621
|
|
9435
9622
|
_updateHeight: function() {
|
9436
|
-
|
9623
|
+
var paddingTop, paddingBottom, paddingHeight, scrollHeight, clientHeight,
|
9624
|
+
borderTop, borderBottom, borderHeight, height,
|
9625
|
+
scrollTop = this.window.scrollTop();
|
9437
9626
|
this.keyupTimeout = 0;
|
9438
9627
|
|
9439
|
-
|
9440
|
-
|
9441
|
-
|
9442
|
-
|
9443
|
-
|
9628
|
+
// IE8 textareas have the onpage property - others do not
|
9629
|
+
if ( !( "onpage" in this.element[ 0 ] ) ) {
|
9630
|
+
this.element.css({
|
9631
|
+
"height": 0,
|
9632
|
+
"min-height": 0,
|
9633
|
+
"max-height": 0
|
9634
|
+
});
|
9635
|
+
}
|
9444
9636
|
|
9445
|
-
|
9446
|
-
|
9447
|
-
|
9448
|
-
|
9449
|
-
|
9450
|
-
|
9451
|
-
height = scrollHeight + borderHeight + 15;
|
9637
|
+
scrollHeight = this.element[ 0 ].scrollHeight;
|
9638
|
+
clientHeight = this.element[ 0 ].clientHeight;
|
9639
|
+
borderTop = parseFloat( this.element.css( "border-top-width" ) );
|
9640
|
+
borderBottom = parseFloat( this.element.css( "border-bottom-width" ) );
|
9641
|
+
borderHeight = borderTop + borderBottom;
|
9642
|
+
height = scrollHeight + borderHeight + 15;
|
9452
9643
|
|
9453
9644
|
// Issue 6179: Padding is not included in scrollHeight and
|
9454
9645
|
// clientHeight by Firefox if no scrollbar is visible. Because
|
@@ -9469,6 +9660,8 @@ $.widget( "mobile.flipswitch", $.extend({
|
|
9469
9660
|
"min-height": "",
|
9470
9661
|
"max-height": ""
|
9471
9662
|
});
|
9663
|
+
|
9664
|
+
this.window.scrollTop( scrollTop );
|
9472
9665
|
},
|
9473
9666
|
|
9474
9667
|
refresh: function() {
|
@@ -9730,7 +9923,9 @@ $.widget( "mobile.selectmenu", $.extend( {
|
|
9730
9923
|
if ( text ) {
|
9731
9924
|
span.text( text );
|
9732
9925
|
} else {
|
9733
|
-
|
9926
|
+
|
9927
|
+
// Set the contents to which we write as   to be XHTML compliant - see gh-6699
|
9928
|
+
span.html( " " );
|
9734
9929
|
}
|
9735
9930
|
|
9736
9931
|
// TODO possibly aggregate multiple select option classes
|
@@ -10332,9 +10527,9 @@ $.widget( "mobile.popup", {
|
|
10332
10527
|
}
|
10333
10528
|
if ( this._fallbackTransition ) {
|
10334
10529
|
this._ui.container
|
10335
|
-
.animationComplete( $.proxy( args.prerequisites.container, "resolve" ) )
|
10336
10530
|
.addClass( args.containerClassToAdd )
|
10337
|
-
.removeClass( args.classToRemove )
|
10531
|
+
.removeClass( args.classToRemove )
|
10532
|
+
.animationComplete( $.proxy( args.prerequisites.container, "resolve" ) );
|
10338
10533
|
return;
|
10339
10534
|
}
|
10340
10535
|
}
|
@@ -10872,8 +11067,10 @@ $.widget( "mobile.selectmenu", $.mobile.selectmenu, {
|
|
10872
11067
|
},
|
10873
11068
|
|
10874
11069
|
build: function() {
|
10875
|
-
var selectId, popupId, dialogId, label, thisPage, isMultiple, menuId,
|
10876
|
-
|
11070
|
+
var selectId, popupId, dialogId, label, thisPage, isMultiple, menuId,
|
11071
|
+
themeAttr, overlayTheme, overlayThemeAttr, dividerThemeAttr,
|
11072
|
+
menuPage, listbox, list, header, headerTitle, menuPageContent,
|
11073
|
+
menuPageClose, headerClose, self,
|
10877
11074
|
o = this.options;
|
10878
11075
|
|
10879
11076
|
if ( o.nativeMenu ) {
|
@@ -10889,7 +11086,9 @@ $.widget( "mobile.selectmenu", $.mobile.selectmenu, {
|
|
10889
11086
|
isMultiple = this.element[ 0 ].multiple;
|
10890
11087
|
menuId = selectId + "-menu";
|
10891
11088
|
themeAttr = o.theme ? ( " data-" + $.mobile.ns + "theme='" + o.theme + "'" ) : "";
|
10892
|
-
|
11089
|
+
overlayTheme = o.overlayTheme || o.theme || null;
|
11090
|
+
overlayThemeAttr = overlayTheme ? ( " data-" + $.mobile.ns +
|
11091
|
+
"overlay-theme='" + overlayTheme + "'" ) : "";
|
10893
11092
|
dividerThemeAttr = ( o.dividerTheme && isMultiple ) ? ( " data-" + $.mobile.ns + "divider-theme='" + o.dividerTheme + "'" ) : "";
|
10894
11093
|
menuPage = $( "<div data-" + $.mobile.ns + "role='dialog' class='ui-selectmenu' id='" + dialogId + "'" + themeAttr + overlayThemeAttr + ">" +
|
10895
11094
|
"<div data-" + $.mobile.ns + "role='header'>" +
|
@@ -10897,10 +11096,10 @@ $.widget( "mobile.selectmenu", $.mobile.selectmenu, {
|
|
10897
11096
|
"</div>"+
|
10898
11097
|
"<div data-" + $.mobile.ns + "role='content'></div>"+
|
10899
11098
|
"</div>" );
|
10900
|
-
listbox = $( "<div id='" + popupId + "' class='ui-selectmenu'>" ).insertAfter( this.select ).popup({ theme: o.overlayTheme });
|
10901
|
-
list = $( "<ul class='ui-selectmenu-list' id='" + menuId + "' role='listbox' aria-labelledby='" + this.buttonId + "'" + themeAttr + dividerThemeAttr + ">" ).appendTo( listbox );
|
10902
|
-
header = $( "<div class='ui-header ui-bar-" + ( o.theme ? o.theme : "inherit" ) + "'>" ).prependTo( listbox );
|
10903
|
-
headerTitle = $( "<h1 class='ui-title'>" ).appendTo( header );
|
11099
|
+
listbox = $( "<div id='" + popupId + "' class='ui-selectmenu'></div>" ).insertAfter( this.select ).popup({ theme: o.overlayTheme });
|
11100
|
+
list = $( "<ul class='ui-selectmenu-list' id='" + menuId + "' role='listbox' aria-labelledby='" + this.buttonId + "'" + themeAttr + dividerThemeAttr + "></ul>" ).appendTo( listbox );
|
11101
|
+
header = $( "<div class='ui-header ui-bar-" + ( o.theme ? o.theme : "inherit" ) + "'></div>" ).prependTo( listbox );
|
11102
|
+
headerTitle = $( "<h1 class='ui-title'></h1>" ).appendTo( header );
|
10904
11103
|
|
10905
11104
|
if ( this.isMultiple ) {
|
10906
11105
|
headerClose = $( "<a>", {
|
@@ -11298,7 +11497,6 @@ $.widget( "mobile.selectmenu", $.mobile.selectmenu, {
|
|
11298
11497
|
|
11299
11498
|
(function( $, undefined ) {
|
11300
11499
|
|
11301
|
-
|
11302
11500
|
// General policy: Do not access data-* attributes except during enhancement.
|
11303
11501
|
// In all other cases we determine the state of the button exclusively from its
|
11304
11502
|
// className. That's why optionsToClasses expects a full complement of options,
|
@@ -11804,7 +12002,10 @@ $.widget( "mobile.controlgroup", $.extend( {
|
|
11804
12002
|
|
11805
12003
|
// Deprecated in 1.4. As from 1.5 button classes have to be present in the markup.
|
11806
12004
|
_btnMarkup: function() {
|
11807
|
-
this.element
|
12005
|
+
this.element
|
12006
|
+
.children( "a" )
|
12007
|
+
.filter( ":not([data-" + $.mobile.ns + "role='none'])" )
|
12008
|
+
.attr( "data-" + $.mobile.ns + "role", "button" );
|
11808
12009
|
this.element.trigger( "create" );
|
11809
12010
|
},
|
11810
12011
|
// Deprecated in 1.4. As from 1.5 ui-btn-left/right classes have to be present in the markup.
|
@@ -12229,22 +12430,17 @@ var ieHack = ( $.mobile.browser.oldIE && $.mobile.browser.oldIE <= 8 ),
|
|
12229
12430
|
uiTemplate = $(
|
12230
12431
|
"<div class='ui-popup-arrow-guide'></div>" +
|
12231
12432
|
"<div class='ui-popup-arrow-container" + ( ieHack ? " ie" : "" ) + "'>" +
|
12232
|
-
"<div class='ui-popup-arrow'>" +
|
12233
|
-
"<div class='ui-popup-arrow-background'></div>" +
|
12234
|
-
"</div>" +
|
12433
|
+
"<div class='ui-popup-arrow'></div>" +
|
12235
12434
|
"</div>"
|
12236
|
-
)
|
12237
|
-
// Needed for transforming coordinates from screen to arrow background
|
12238
|
-
txFactor = Math.sqrt( 2 ) / 2;
|
12435
|
+
);
|
12239
12436
|
|
12240
12437
|
function getArrow() {
|
12241
12438
|
var clone = uiTemplate.clone(),
|
12242
12439
|
gd = clone.eq( 0 ),
|
12243
12440
|
ct = clone.eq( 1 ),
|
12244
|
-
ar = ct.children()
|
12245
|
-
bg = ar.children();
|
12441
|
+
ar = ct.children();
|
12246
12442
|
|
12247
|
-
return { arEls: ct.add( gd ), gd: gd, ct: ct, ar: ar
|
12443
|
+
return { arEls: ct.add( gd ), gd: gd, ct: ct, ar: ar };
|
12248
12444
|
}
|
12249
12445
|
|
12250
12446
|
$.widget( "mobile.popup", $.mobile.popup, {
|
@@ -12271,7 +12467,6 @@ $.widget( "mobile.popup", $.mobile.popup, {
|
|
12271
12467
|
|
12272
12468
|
theme = this._themeClassFromOption( "ui-body-", opts.theme );
|
12273
12469
|
ar.ar.addClass( theme + ( opts.shadow ? " ui-overlay-shadow" : "" ) );
|
12274
|
-
ar.bg.addClass( theme );
|
12275
12470
|
ar.arEls.hide().appendTo( this.element );
|
12276
12471
|
|
12277
12472
|
return ar;
|
@@ -12353,7 +12548,7 @@ $.widget( "mobile.popup", $.mobile.popup, {
|
|
12353
12548
|
},
|
12354
12549
|
|
12355
12550
|
_placementCoords: function( desired ) {
|
12356
|
-
var state, best, params,
|
12551
|
+
var state, best, params, elOffset, bgRef,
|
12357
12552
|
optionValue = this.options.arrow,
|
12358
12553
|
ar = this._ui.arrow;
|
12359
12554
|
|
@@ -12402,12 +12597,6 @@ $.widget( "mobile.popup", $.mobile.popup, {
|
|
12402
12597
|
left: elOffset.left + state.contentBox.x,
|
12403
12598
|
top: elOffset.top + state.contentBox.y
|
12404
12599
|
};
|
12405
|
-
bgOffset = ar.bg
|
12406
|
-
.removeAttr( "style" )
|
12407
|
-
.css( ( "cx" === params[ best.dir ].dimKey ? "width" : "height" ), state.contentBox[ params[ best.dir ].dimKey ] )
|
12408
|
-
.offset();
|
12409
|
-
diff = { dx: bgRef.x.left - bgOffset.left, dy: bgRef.y.top - bgOffset.top };
|
12410
|
-
ar.bg.css( { left: txFactor * diff.dy + txFactor * diff.dx, top: txFactor * diff.dy - txFactor * diff.dx } );
|
12411
12600
|
}
|
12412
12601
|
|
12413
12602
|
return best.result;
|
@@ -12440,7 +12629,6 @@ $.widget( "mobile.popup", $.mobile.popup, {
|
|
12440
12629
|
oldTheme = this._themeClassFromOption( "ui-body-", oldTheme );
|
12441
12630
|
newTheme = this._themeClassFromOption( "ui-body-", opts.theme );
|
12442
12631
|
ar.ar.removeClass( oldTheme ).addClass( newTheme );
|
12443
|
-
ar.bg.removeClass( oldTheme ).addClass( newTheme );
|
12444
12632
|
}
|
12445
12633
|
|
12446
12634
|
if ( opts.shadow !== undefined ) {
|
@@ -12603,16 +12791,27 @@ $.widget( "mobile.panel", {
|
|
12603
12791
|
this.element.addClass( this._getPanelClasses() );
|
12604
12792
|
},
|
12605
12793
|
|
12606
|
-
|
12607
|
-
|
12608
|
-
|
12609
|
-
|
12610
|
-
e.preventDefault();
|
12611
|
-
self.close();
|
12794
|
+
_handleCloseClickAndEatEvent: function( event ) {
|
12795
|
+
if ( !event.isDefaultPrevented() ) {
|
12796
|
+
event.preventDefault();
|
12797
|
+
this.close();
|
12612
12798
|
return false;
|
12799
|
+
}
|
12800
|
+
},
|
12801
|
+
|
12802
|
+
_handleCloseClick: function( event ) {
|
12803
|
+
if ( !event.isDefaultPrevented() ) {
|
12804
|
+
this.close();
|
12805
|
+
}
|
12806
|
+
},
|
12807
|
+
|
12808
|
+
_bindCloseEvents: function() {
|
12809
|
+
this._on( this._closeLink, {
|
12810
|
+
"click": "_handleCloseClick"
|
12613
12811
|
});
|
12614
|
-
|
12615
|
-
|
12812
|
+
|
12813
|
+
this._on({
|
12814
|
+
"click a:jqmData(ajax='false')": "_handleCloseClick"
|
12616
12815
|
});
|
12617
12816
|
},
|
12618
12817
|
|
@@ -12755,7 +12954,7 @@ $.widget( "mobile.panel", {
|
|
12755
12954
|
}
|
12756
12955
|
|
12757
12956
|
if ( !immediate && $.support.cssTransform3d && !!o.animate ) {
|
12758
|
-
self.
|
12957
|
+
self.element.animationComplete( complete, "transition" );
|
12759
12958
|
} else {
|
12760
12959
|
setTimeout( complete, 0 );
|
12761
12960
|
}
|
@@ -12787,7 +12986,6 @@ $.widget( "mobile.panel", {
|
|
12787
12986
|
}
|
12788
12987
|
},
|
12789
12988
|
complete = function() {
|
12790
|
-
self.document.off( self._transitionEndEvents, complete );
|
12791
12989
|
|
12792
12990
|
if ( o.display !== "overlay" ) {
|
12793
12991
|
self._wrapper().addClass( o.classes.pageContentPrefix + "-open" );
|
@@ -12819,11 +13017,6 @@ $.widget( "mobile.panel", {
|
|
12819
13017
|
o = this.options,
|
12820
13018
|
|
12821
13019
|
_closePanel = function() {
|
12822
|
-
if ( !immediate && $.support.cssTransform3d && !!o.animate ) {
|
12823
|
-
self.document.on( self._transitionEndEvents, complete );
|
12824
|
-
} else {
|
12825
|
-
setTimeout( complete, 0 );
|
12826
|
-
}
|
12827
13020
|
|
12828
13021
|
self.element.removeClass( o.classes.panelOpen );
|
12829
13022
|
|
@@ -12832,13 +13025,17 @@ $.widget( "mobile.panel", {
|
|
12832
13025
|
self._fixedToolbars().removeClass( self._pageContentOpenClasses );
|
12833
13026
|
}
|
12834
13027
|
|
13028
|
+
if ( !immediate && $.support.cssTransform3d && !!o.animate ) {
|
13029
|
+
self.element.animationComplete( complete, "transition" );
|
13030
|
+
} else {
|
13031
|
+
setTimeout( complete, 0 );
|
13032
|
+
}
|
13033
|
+
|
12835
13034
|
if ( self._modal ) {
|
12836
13035
|
self._modal.removeClass( self._modalOpenClasses );
|
12837
13036
|
}
|
12838
13037
|
},
|
12839
13038
|
complete = function() {
|
12840
|
-
self.document.off( self._transitionEndEvents, complete );
|
12841
|
-
|
12842
13039
|
if ( o.theme && o.display !== "overlay" ) {
|
12843
13040
|
self._page().parent().removeClass( o.classes.pageContainer + "-themed " + o.classes.pageContainer + "-" + o.theme );
|
12844
13041
|
}
|
@@ -12877,8 +13074,6 @@ $.widget( "mobile.panel", {
|
|
12877
13074
|
this[ this._open ? "close" : "open" ]();
|
12878
13075
|
},
|
12879
13076
|
|
12880
|
-
_transitionEndEvents: "webkitTransitionEnd oTransitionEnd otransitionend transitionend msTransitionEnd",
|
12881
|
-
|
12882
13077
|
_destroy: function() {
|
12883
13078
|
var otherPanels,
|
12884
13079
|
o = this.options,
|
@@ -12912,10 +13107,6 @@ $.widget( "mobile.panel", {
|
|
12912
13107
|
|
12913
13108
|
this.document.off( "panelopen panelclose" );
|
12914
13109
|
|
12915
|
-
if ( this._open ) {
|
12916
|
-
this.document.off( this._transitionEndEvents );
|
12917
|
-
$.mobile.resetActivePageHeight();
|
12918
|
-
}
|
12919
13110
|
}
|
12920
13111
|
|
12921
13112
|
if ( this._open ) {
|
@@ -12930,10 +13121,7 @@ $.widget( "mobile.panel", {
|
|
12930
13121
|
.off( "panelbeforeopen" )
|
12931
13122
|
.off( "panelhide" )
|
12932
13123
|
.off( "keyup.panel" )
|
12933
|
-
.off( "updatelayout" )
|
12934
|
-
.off( this._transitionEndEvents );
|
12935
|
-
|
12936
|
-
this._closeLink.off( "click.panel" );
|
13124
|
+
.off( "updatelayout" );
|
12937
13125
|
|
12938
13126
|
if ( this._modal ) {
|
12939
13127
|
this._modal.remove();
|
@@ -13055,7 +13243,6 @@ $.widget( "mobile.table", $.mobile.table, {
|
|
13055
13243
|
if ( this.options.enhanced ) {
|
13056
13244
|
this._menu = $( this.document[ 0 ].getElementById( this._id() + "-popup" ) ).children().first();
|
13057
13245
|
this._addToggles( this._menu, true );
|
13058
|
-
this._bindToggles( this._menu );
|
13059
13246
|
} else {
|
13060
13247
|
this._menu = this._enhanceColToggle();
|
13061
13248
|
this.element.addClass( this.options.classes.columnToggleTable );
|
@@ -13078,13 +13265,8 @@ $.widget( "mobile.table", $.mobile.table, {
|
|
13078
13265
|
this._on( this.window, {
|
13079
13266
|
throttledresize: "_setToggleState"
|
13080
13267
|
});
|
13081
|
-
|
13082
|
-
|
13083
|
-
_bindToggles: function( menu ) {
|
13084
|
-
var inputs = menu.find( "input" );
|
13085
|
-
|
13086
|
-
this._on( inputs, {
|
13087
|
-
change: "_menuInputChange"
|
13268
|
+
this._on( this._menu, {
|
13269
|
+
"change input": "_menuInputChange"
|
13088
13270
|
});
|
13089
13271
|
},
|
13090
13272
|
|
@@ -13127,7 +13309,6 @@ $.widget( "mobile.table", $.mobile.table, {
|
|
13127
13309
|
// set bindings here
|
13128
13310
|
if ( !keep ) {
|
13129
13311
|
menu.controlgroup( "refresh" );
|
13130
|
-
this._bindToggles( menu );
|
13131
13312
|
}
|
13132
13313
|
},
|
13133
13314
|
|
@@ -13358,7 +13539,7 @@ $.widget( "mobile.filterable", {
|
|
13358
13539
|
}
|
13359
13540
|
|
13360
13541
|
this._timer = this._delay( function() {
|
13361
|
-
this._trigger( "beforefilter",
|
13542
|
+
this._trigger( "beforefilter", null, { input: search } );
|
13362
13543
|
|
13363
13544
|
// Change val as lastval for next execution
|
13364
13545
|
search[ 0 ].setAttribute( "data-" + $.mobile.ns + "lastval", val );
|
@@ -13413,6 +13594,10 @@ $.widget( "mobile.filterable", {
|
|
13413
13594
|
}
|
13414
13595
|
|
13415
13596
|
this._refreshChildWidget();
|
13597
|
+
|
13598
|
+
this._trigger( "filter", null, {
|
13599
|
+
items: filterItems
|
13600
|
+
});
|
13416
13601
|
},
|
13417
13602
|
|
13418
13603
|
// The Default implementation of _refreshChildWidget attempts to call
|
@@ -13558,6 +13743,16 @@ $.widget( "mobile.filterable", $.mobile.filterable, {
|
|
13558
13743
|
this._setWidget( this.element.data( "mobile-" + evt.type.substring( 0, evt.type.length - 6 ) ) );
|
13559
13744
|
},
|
13560
13745
|
|
13746
|
+
_trigger: function( type, event, data ) {
|
13747
|
+
if ( this._widget && this._widget.widgetFullName === "mobile-listview" &&
|
13748
|
+
type === "beforefilter" ) {
|
13749
|
+
|
13750
|
+
// Also trigger listviewbeforefilter if this widget is also a listview
|
13751
|
+
this._widget._trigger( "beforefilter", event, data );
|
13752
|
+
}
|
13753
|
+
this._super( type, event, data );
|
13754
|
+
},
|
13755
|
+
|
13561
13756
|
_setWidget: function( widget ) {
|
13562
13757
|
if ( !this._widget && widget ) {
|
13563
13758
|
this._widget = widget;
|
@@ -13567,7 +13762,7 @@ $.widget( "mobile.filterable", $.mobile.filterable, {
|
|
13567
13762
|
if ( !!this._widget ) {
|
13568
13763
|
this._syncTextInputOptions( this._widget.options );
|
13569
13764
|
if ( this._widget.widgetName === "listview" ) {
|
13570
|
-
this._widget.options.
|
13765
|
+
this._widget.options.hideDividers = true;
|
13571
13766
|
this._widget.element.listview( "refresh" );
|
13572
13767
|
}
|
13573
13768
|
}
|