Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -1,2 +1,3 @@
@import url( "jquery.mobile.icons.css" );
@import url( "jquery.mobile.theme.css" );
@import url( "../../structure/jquery.mobile.structure.css" );
@@ -0,0 +1,3 @@
@import url( "jquery.mobile.icons.data.png.css" );
@import url( "jquery.mobile.theme.css" );
@import url( "../../structure/jquery.mobile.structure.css" );
@@ -0,0 +1,3 @@
@import url( "jquery.mobile.icons.data.svg.css" );
@import url( "jquery.mobile.theme.css" );
@import url( "../../structure/jquery.mobile.structure.css" );
@@ -0,0 +1,3 @@
@import url( "jquery.mobile.icons.fallback.css" );
@import url( "jquery.mobile.theme.css" );
@import url( "../../structure/jquery.mobile.structure.css" );

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

@@ -0,0 +1,356 @@
.ui-icon-action:after {
background-image: url(images/icons-png/action-white.png);
}
.ui-icon-arrow-d-l:after {
background-image: url(images/icons-png/arrow-d-l-white.png);
}
.ui-icon-arrow-d-r:after {
background-image: url(images/icons-png/arrow-d-r-white.png);
}
.ui-icon-arrow-d:after {
background-image: url(images/icons-png/arrow-d-white.png);
}
.ui-icon-arrow-l:after {
background-image: url(images/icons-png/arrow-l-white.png);
}
.ui-icon-arrow-r:after {
background-image: url(images/icons-png/arrow-r-white.png);
}
.ui-icon-arrow-u-l:after {
background-image: url(images/icons-png/arrow-u-l-white.png);
}
.ui-icon-arrow-u-r:after {
background-image: url(images/icons-png/arrow-u-r-white.png);
}
.ui-icon-arrow-u:after {
background-image: url(images/icons-png/arrow-u-white.png);
}
.ui-icon-audio:after {
background-image: url(images/icons-png/audio-white.png);
}
.ui-icon-calendar:after {
background-image: url(images/icons-png/calendar-white.png);
}
.ui-icon-camera:after {
background-image: url(images/icons-png/camera-white.png);
}
.ui-icon-carat-d:after {
background-image: url(images/icons-png/carat-d-white.png);
}
.ui-icon-carat-l:after {
background-image: url(images/icons-png/carat-l-white.png);
}
.ui-icon-carat-r:after {
background-image: url(images/icons-png/carat-r-white.png);
}
.ui-icon-carat-u:after {
background-image: url(images/icons-png/carat-u-white.png);
}
.ui-icon-check:after,
.ui-icon-checkbox-on:after {
background-image: url(images/icons-png/check-white.png);
}
.ui-icon-clock:after {
background-image: url(images/icons-png/clock-white.png);
}
.ui-icon-cloud:after {
background-image: url(images/icons-png/cloud-white.png);
}
.ui-icon-grid:after {
background-image: url(images/icons-png/grid-white.png);
}
.ui-icon-mail:after {
background-image: url(images/icons-png/mail-white.png);
}
.ui-icon-eye:after {
background-image: url(images/icons-png/eye-white.png);
}
.ui-icon-gear:after {
background-image: url(images/icons-png/gear-white.png);
}
.ui-icon-heart:after {
background-image: url(images/icons-png/heart-white.png);
}
.ui-icon-home:after {
background-image: url(images/icons-png/home-white.png);
}
.ui-icon-info:after {
background-image: url(images/icons-png/info-white.png);
}
.ui-icon-bullets:after {
background-image: url(images/icons-png/bullets-white.png);
}
.ui-icon-bars:after {
background-image: url(images/icons-png/bars-white.png);
}
.ui-icon-navigation:after {
background-image: url(images/icons-png/navigation-white.png);
}
.ui-icon-lock:after {
background-image: url(images/icons-png/lock-white.png);
}
.ui-icon-search:after {
background-image: url(images/icons-png/search-white.png);
}
.ui-icon-location:after {
background-image: url(images/icons-png/location-white.png);
}
.ui-icon-minus:after {
background-image: url(images/icons-png/minus-white.png);
}
.ui-icon-forbidden:after {
background-image: url(images/icons-png/forbidden-white.png);
}
.ui-icon-edit:after {
background-image: url(images/icons-png/edit-white.png);
}
.ui-icon-user:after {
background-image: url(images/icons-png/user-white.png);
}
.ui-icon-phone:after {
background-image: url(images/icons-png/phone-white.png);
}
.ui-icon-plus:after {
background-image: url(images/icons-png/plus-white.png);
}
.ui-icon-power:after {
background-image: url(images/icons-png/power-white.png);
}
.ui-icon-recycle:after {
background-image: url(images/icons-png/recycle-white.png);
}
.ui-icon-forward:after {
background-image: url(images/icons-png/forward-white.png);
}
.ui-icon-refresh:after {
background-image: url(images/icons-png/refresh-white.png);
}
.ui-icon-shop:after {
background-image: url(images/icons-png/shop-white.png);
}
.ui-icon-comment:after {
background-image: url(images/icons-png/comment-white.png);
}
.ui-icon-star:after {
background-image: url(images/icons-png/star-white.png);
}
.ui-icon-tag:after {
background-image: url(images/icons-png/tag-white.png);
}
.ui-icon-back:after {
background-image: url(images/icons-png/back-white.png);
}
.ui-icon-video:after {
background-image: url(images/icons-png/video-white.png);
}
.ui-icon-alert:after {
background-image: url(images/icons-png/alert-white.png);
}
.ui-icon-delete:after {
background-image: url(images/icons-png/delete-white.png);
}

/* Alt icons */
.ui-icon-alt.ui-icon-action:after,
.ui-icon-alt .ui-icon-action:after {
background-image: url(images/icons-png/action-black.png);
}
.ui-icon-alt.ui-icon-arrow-d:after,
.ui-icon-alt .ui-icon-arrow-d:after {
background-image: url(images/icons-png/arrow-d-black.png);
}
.ui-icon-alt.ui-icon-arrow-d-l:after,
.ui-icon-alt .ui-icon-arrow-d-l:after {
background-image: url(images/icons-png/arrow-d-l-black.png);
}
.ui-icon-alt.ui-icon-arrow-d-r:after,
.ui-icon-alt .ui-icon-arrow-d-r:after {
background-image: url(images/icons-png/arrow-d-r-black.png);
}
.ui-icon-alt.ui-icon-arrow-l:after,
.ui-icon-alt .ui-icon-arrow-l:after {
background-image: url(images/icons-png/arrow-l-black.png);
}
.ui-icon-alt.ui-icon-arrow-r:after,
.ui-icon-alt .ui-icon-arrow-r:after {
background-image: url(images/icons-png/arrow-r-black.png);
}
.ui-icon-alt.ui-icon-arrow-u:after,
.ui-icon-alt .ui-icon-arrow-u:after {
background-image: url(images/icons-png/arrow-u-black.png);
}
.ui-icon-alt.ui-icon-arrow-u-l:after,
.ui-icon-alt .ui-icon-arrow-u-l:after {
background-image: url(images/icons-png/arrow-u-l-black.png);
}
.ui-icon-alt.ui-icon-arrow-u-r:after,
.ui-icon-alt .ui-icon-arrow-u-r:after {
background-image: url(images/icons-png/arrow-u-r-black.png);
}
.ui-icon-alt.ui-icon-audio:after,
.ui-icon-alt .ui-icon-audio:after {
background-image: url(images/icons-png/audio-black.png);
}
.ui-icon-alt.ui-icon-calendar:after,
.ui-icon-alt .ui-icon-calendar:after {
background-image: url(images/icons-png/calendar-black.png);
}
.ui-icon-alt.ui-icon-camera:after,
.ui-icon-alt .ui-icon-camera:after {
background-image: url(images/icons-png/camera-black.png);
}
.ui-icon-alt.ui-icon-carat-d:after,
.ui-icon-alt .ui-icon-carat-d:after {
background-image: url(images/icons-png/carat-d-black.png);
}
.ui-icon-alt.ui-icon-carat-l:after,
.ui-icon-alt .ui-icon-carat-l:after {
background-image: url(images/icons-png/carat-l-black.png);
}
.ui-icon-alt.ui-icon-carat-r:after,
.ui-icon-alt .ui-icon-carat-r:after {
background-image: url(images/icons-png/carat-r-black.png);
}
.ui-icon-alt.ui-icon-carat-u:after,
.ui-icon-alt .ui-icon-carat-u:after {
background-image: url(images/icons-png/carat-u-black.png);
}
.ui-icon-alt.ui-icon-check:after,
.ui-icon-alt .ui-icon-check:after,
.ui-icon-alt.ui-icon-checkbox-on:after,
.ui-icon-alt .ui-icon-checkbox-on:after {
background-image: url(images/icons-png/check-black.png);
}
.ui-icon-alt.ui-icon-clock:after,
.ui-icon-alt .ui-icon-clock:after {
background-image: url(images/icons-png/clock-black.png);
}
.ui-icon-alt.ui-icon-cloud:after,
.ui-icon-alt .ui-icon-cloud:after {
background-image: url(images/icons-png/cloud-black.png);
}
.ui-icon-alt.ui-icon-grid:after,
.ui-icon-alt .ui-icon-grid:after {
background-image: url(images/icons-png/grid-black.png);
}
.ui-icon-alt.ui-icon-mail:after,
.ui-icon-alt .ui-icon-mail:after {
background-image: url(images/icons-png/mail-black.png);
}
.ui-icon-alt.ui-icon-eye:after,
.ui-icon-alt .ui-icon-eye:after {
background-image: url(images/icons-png/eye-black.png);
}
.ui-icon-alt.ui-icon-gear:after,
.ui-icon-alt .ui-icon-gear:after {
background-image: url(images/icons-png/gear-black.png);
}
.ui-icon-alt.ui-icon-heart:after,
.ui-icon-alt .ui-icon-heart:after {
background-image: url(images/icons-png/heart-black.png);
}
.ui-icon-alt.ui-icon-home:after,
.ui-icon-alt .ui-icon-home:after {
background-image: url(images/icons-png/home-black.png);
}
.ui-icon-alt.ui-icon-info:after,
.ui-icon-alt .ui-icon-info:after {
background-image: url(images/icons-png/info-black.png);
}
.ui-icon-alt.ui-icon-bars:after,
.ui-icon-alt .ui-icon-bars:after {
background-image: url(images/icons-png/bars-black.png);
}
.ui-icon-alt.ui-icon-bullets:after,
.ui-icon-alt .ui-icon-bullets:after {
background-image: url(images/icons-png/bullets-black.png);
}
.ui-icon-alt.ui-icon-navigation:after,
.ui-icon-alt .ui-icon-navigation:after {
background-image: url(images/icons-png/navigation-black.png);
}
.ui-icon-alt.ui-icon-lock:after,
.ui-icon-alt .ui-icon-lock:after {
background-image: url(images/icons-png/lock-black.png);
}
.ui-icon-alt.ui-icon-search:after,
.ui-icon-alt .ui-icon-search:after,
.ui-input-search:after {
background-image: url(images/icons-png/search-black.png);
}
.ui-icon-alt.ui-icon-location:after,
.ui-icon-alt .ui-icon-location:after {
background-image: url(images/icons-png/location-black.png);
}
.ui-icon-alt.ui-icon-minus:after,
.ui-icon-alt .ui-icon-minus:after {
background-image: url(images/icons-png/minus-black.png);
}
.ui-icon-alt.ui-icon-forbidden:after,
.ui-icon-alt .ui-icon-forbidden:after {
background-image: url(images/icons-png/forbidden-black.png);
}
.ui-icon-alt.ui-icon-edit:after,
.ui-icon-alt .ui-icon-edit:after {
background-image: url(images/icons-png/edit-black.png);
}
.ui-icon-alt.ui-icon-user:after,
.ui-icon-alt .ui-icon-user:after {
background-image: url(images/icons-png/user-black.png);
}
.ui-icon-alt.ui-icon-phone:after,
.ui-icon-alt .ui-icon-phone:after {
background-image: url(images/icons-png/phone-black.png);
}
.ui-icon-alt.ui-icon-plus:after,
.ui-icon-alt .ui-icon-plus:after {
background-image: url(images/icons-png/plus-black.png);
}
.ui-icon-alt.ui-icon-power:after,
.ui-icon-alt .ui-icon-power:after {
background-image: url(images/icons-png/power-black.png);
}
.ui-icon-alt.ui-icon-recycle:after,
.ui-icon-alt .ui-icon-recycle:after {
background-image: url(images/icons-png/recycle-black.png);
}
.ui-icon-alt.ui-icon-forward:after,
.ui-icon-alt .ui-icon-forward:after {
background-image: url(images/icons-png/forward-black.png);
}
.ui-icon-alt.ui-icon-refresh:after,
.ui-icon-alt .ui-icon-refresh:after {
background-image: url(images/icons-png/refresh-black.png);
}
.ui-icon-alt.ui-icon-shop:after,
.ui-icon-alt .ui-icon-shop:after {
background-image: url(images/icons-png/shop-black.png);
}
.ui-icon-alt.ui-icon-comment:after,
.ui-icon-alt .ui-icon-comment:after {
background-image: url(images/icons-png/comment-black.png);
}
.ui-icon-alt.ui-icon-star:after,
.ui-icon-alt .ui-icon-star:after {
background-image: url(images/icons-png/star-black.png);
}
.ui-icon-alt.ui-icon-tag:after,
.ui-icon-alt .ui-icon-tag:after {
background-image: url(images/icons-png/tag-black.png);
}
.ui-icon-alt.ui-icon-back:after,
.ui-icon-alt .ui-icon-back:after {
background-image: url(images/icons-png/back-black.png);
}
.ui-icon-alt.ui-icon-video:after,
.ui-icon-alt .ui-icon-video:after {
background-image: url(images/icons-png/video-black.png);
}
.ui-icon-alt.ui-icon-alert:after,
.ui-icon-alt .ui-icon-alert:after {
background-image: url(images/icons-png/alert-black.png);
}
.ui-icon-alt.ui-icon-delete:after,
.ui-icon-alt .ui-icon-delete:after {
background-image: url(images/icons-png/delete-black.png);
}

Large diffs are not rendered by default.

@@ -59,7 +59,7 @@
<li data-role="list-divider">Theming</li>
<li><a href="test/theming/" data-ajax="false">Theme inheritance</a></li>
<li data-role="list-divider">Icons</li>
<li><a href="test/icons/font-icons.php" data-ajax="false">Font icons</a></li>
<li><a href="test/icons/index.html" data-ajax="false">Grunticon - SVG icons with fallback</a></li>
</ul>

</div><!-- /content -->

This file was deleted.

This file was deleted.

Deleted file not rendered
Binary file not shown.
Deleted file not rendered
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,6 @@
<!-- Unicode CSS Loader: place this in the head of your page -->
<script>
/* grunticon Stylesheet Loader | https://github.com/filamentgroup/grunticon | (c) 2012 Scott Jehl, Filament Group, Inc. | MIT license. */
window.grunticon=function(e){if(e&&3===e.length){var t=window,n=!!t.document.createElementNS&&!!t.document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,A=function(A){var o=t.document.createElement("link"),r=t.document.getElementsByTagName("script")[0];o.rel="stylesheet",o.href=e[A&&n?0:A?1:2],r.parentNode.insertBefore(o,r)},o=new t.Image;o.onerror=function(){A(!1)},o.onload=function(){A(1===o.width&&1===o.height)},o.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw=="}};
grunticon( [ "/path/to/jquery.mobile.css", "/path/to/jquery.mobile.data.png.css", "/path/to/jquery.mobile.fallback.css" ] );</script>
<noscript><link href="/path/to/jquery.mobile.fallback.css" rel="stylesheet"></noscript>
@@ -0,0 +1,220 @@
<!doctype HTML>
<html>
<head>
<title>Icons</title>
<link rel="shortcut icon" href="../../favicon.ico">
<script>
/* grunticon Stylesheet Loader | https://github.com/filamentgroup/grunticon | (c) 2012 Scott Jehl, Filament Group, Inc. | MIT license. */
window.grunticon=function(e){if(e&&3===e.length){var t=window,n=!!t.document.createElementNS&&!!t.document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,A=function(A){var o=t.document.createElement("link"),r=t.document.getElementsByTagName("script")[0];o.rel="stylesheet",o.href=e[A&&n?0:A?1:2],r.parentNode.insertBefore(o,r)},o=new t.Image;o.onerror=function(){A(!1)},o.onload=function(){A(1===o.width&&1===o.height)},o.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw=="}};
grunticon( [ "../../../css/themes/default/jquery.mobile.css", "../../../css/themes/default/jquery.mobile.data.png.css", "../../../css/themes/default/jquery.mobile.fallback.css" ] );
</script>
<noscript><link href="../../../css/themes/default/jquery.mobile.fallback.css" rel="stylesheet"></noscript>
<script src="../../../js/jquery.js"></script>
<script src="../../../js/"></script>
<script>
$( document ).on( "pagecreate", function() {
$( "#settings input" ).on( "change", function( event ) {
if ( event.target.id === "opt-mini" ) {
if ( $( "#opt-mini" ).prop( "checked" ) ) {
$( "#test" ).addClass( "ui-mini" );
} else {
$( "#test" ).removeClass( "ui-mini" );
}
}
if ( event.target.id === "opt-inline" ) {
if ( $( "#opt-inline" ).prop( "checked" ) ) {
$( "#test button" ).addClass( "ui-btn-inline" );
} else {
$( "#test button" ).removeClass( "ui-btn-inline" );
}
}
if ( event.target.id === "opt-notext" ) {
if ( $( "#opt-notext" ).prop( "checked" ) ) {
$( "#test button" ).button( "option", "iconpos", "notext" );
} else {
$( "#test button" ).button( "option", "iconpos", "left" );
}
$( "#test button" ).button( "refresh" );
}
if ( event.target.id === "opt-alt" ) {
if ( $( "#opt-alt" ).prop( "checked" ) ) {
$( "#test" ).addClass( "ui-icon-alt" );
} else {
$( "#test" ).removeClass( "ui-icon-alt" );
}
}
if ( event.target.id === "opt-nodisc" ) {
if ( $( "#opt-nodisc" ).prop( "checked" ) ) {
$( "#test" ).addClass( "ui-icon-nodisc" );
} else {
$( "#test" ).removeClass( "ui-icon-nodisc" );
}
}
if ( event.target.id === "opt-iconshadow" ) {
if ( $( "#opt-iconshadow" ).prop( "checked" ) ) {
$( "#test" ).addClass( "ui-shadow-icon" );
} else {
$( "#test" ).removeClass( "ui-shadow-icon" );
}
}
if ( event.target.name === "theme" ) {
var themeClass = $( "#theme-setting input:checked" ).attr( "id" );

$( "#icon-page" ).removeClass( "ui-page-theme-a ui-page-theme-b" ).addClass( themeClass );
}
});
});
</script>
</head>
<body>

<div data-role="page" id="icon-page">
<div data-role="header">
<h1>Icons</h1>
</div>
<div data-role="content">

<form id="settings" class="ui-mini">
<div data-role="fieldcontain">
<fieldset data-role="controlgroup" data-type="horizontal" id="theme-setting">
<legend>Theme:</legend>
<label for="ui-page-theme-a">A</label>
<input type="radio" name="theme" id="ui-page-theme-a" checked>
<label for="ui-page-theme-b">B</label>
<input type="radio" name="theme" id="ui-page-theme-b">
</fieldset>
</div>
<div data-role="fieldcontain">
<fieldset data-role="controlgroup" data-type="horizontal">
<legend>Style:</legend>
<label for="opt-mini">Mini</label>
<input type="checkbox" name="opt-mini" id="opt-mini">
<label for="opt-inline">Inline</label>
<input type="checkbox" name="opt-inline" id="opt-inline">
<label for="opt-notext">Icon-only</label>
<input type="checkbox" name="opt-notext" id="opt-notext">
<label for="opt-alt">Alt (black)</label>
<input type="checkbox" name="opt-alt" id="opt-alt">
<label for="opt-nodisc">No disc</label>
<input type="checkbox" name="opt-nodisc" id="opt-nodisc">
<label for="opt-iconshadow">Icon shadow</label>
<input type="checkbox" name="opt-iconshadow" id="opt-iconshadow">
</fieldset>
</div>
</form>

<div id="test">
<form>
<button data-icon="action">action</button>
<button data-icon="arrow-d-l">arrow-d-l</button>
<button data-icon="arrow-d-r">arrow-d-r</button>
<button data-icon="arrow-d">arrow-d</button>
<button data-icon="arrow-l">arrow-l</button>
<button data-icon="arrow-r">arrow-r</button>
<button data-icon="arrow-u-l">arrow-u-l</button>
<button data-icon="arrow-u-r">arrow-u-r</button>
<button data-icon="arrow-u">arrow-u</button>
<button data-icon="audio">audio</button>
<button data-icon="calendar">calendar</button>
<button data-icon="camera">camera</button>
<button data-icon="carat-d">carat-d</button>
<button data-icon="carat-l">carat-l</button>
<button data-icon="carat-r">carat-r</button>
<button data-icon="carat-u">carat-u</button>
<button data-icon="check">check</button>
<button data-icon="clock">clock</button>
<button data-icon="cloud">cloud</button>
<button data-icon="grid">grid</button>
<button data-icon="mail">mail</button>
<button data-icon="eye">eye</button>
<button data-icon="gear">gear</button>
<button data-icon="heart">heart</button>
<button data-icon="home">home</button>
<button data-icon="info">info</button>
<button data-icon="bullets">bullets</button>
<button data-icon="bars">bars</button>
<button data-icon="navigation">navigation</button>
<button data-icon="lock">lock</button>
<button data-icon="search">search</button>
<button data-icon="location">location</button>
<button data-icon="minus">minus</button>
<button data-icon="forbidden">forbidden</button>
<button data-icon="edit">edit</button>
<button data-icon="user">user</button>
<button data-icon="phone">phone</button>
<button data-icon="plus">plus</button>
<button data-icon="power">power</button>
<button data-icon="recycle">recycle</button>
<button data-icon="forward">forward</button>
<button data-icon="refresh">refresh</button>
<button data-icon="shop">shop</button>
<button data-icon="comment">comment</button>
<button data-icon="star">star</button>
<button data-icon="tag">tag</button>
<button data-icon="back">back</button>
<button data-icon="video">video</button>
<button data-icon="alert">alert</button>
<button data-icon="delete">delete</button>

<div data-role="fieldcontain">
<fieldset data-role="controlgroup">
<legend>Checkbox:</legend>
<label for="checkbox-v-1a">One</label>
<input type="checkbox" name="checkbox-v-1a" id="checkbox-v-1a">
<label for="checkbox-v-1b">Two</label>
<input type="checkbox" name="checkbox-v-1b" id="checkbox-v-1b">
<label for="checkbox-v-1c">Three</label>
<input type="checkbox" name="checkbox-v-1c" id="checkbox-v-1c">
</fieldset>
</div>

<div data-role="fieldcontain"><fieldset data-role="controlgroup"><legend>Radio:</legend>
<label for="radio-choice-v-1a">One</label>
<input type="radio" name="radio-choice-v-1" id="radio-choice-v-1a" value="one" checked="checked">
<label for="radio-choice-v-1b">Two</label>
<input type="radio" name="radio-choice-v-1" id="radio-choice-v-1b" value="two">
<label for="radio-choice-v-1c">Three</label>
<input type="radio" name="radio-choice-v-1" id="radio-choice-v-1c" value="three">
</fieldset>
</div>

<div data-role="fieldcontain">
<label for="select-custom">Multiple select:</label>
<select name="select-custom" id="select-custom" multiple="multiple" data-native-menu="false">
<option>Choose options</option>
<option value="1">The 1st Option</option>
<option value="2" selected="selected">The 2nd Option</option>
<option value="3">The 3rd Option</option>
<option value="4" selected="selected">The 4th Option</option>
</select>
</div>

<div data-role="fieldcontain">
<label for="search-1">Search:</label>
<input type="search" name="search-1" id="search-1" value="">
</div>
</form>

<div data-role="collapsible">
<h4>Collapsibe</h4>
<p>I'm the collapsible content.</p>
</div>

<ul data-role="listview" data-inset="true">
<li><a href="#">List item</a></li>
<li><a href="#">List item</a></li>
<li><a href="#">List item</a></li>
</ul>

<a href="#popup" data-rel="popup" data-role="button">Popup</a>
<div data-role="popup" id="popup" style="max-width:280px">
<a href="#" data-rel="back" data-role="button" data-icon="delete" data-iconpos="notext" class="ui-btn-right">Close</a>
<p>I have a close button at the top right corner with simple HTML markup.</p>
</div>
</div>

</div>
</div>

</body>
</html>
@@ -13,10 +13,10 @@
$( "#theme-selector input" ).on( "change", function( event ) {
var themeClass = $( "#theme-selector input:checked" ).attr( "id" );
$( "#testpage" ).removeClass( "ui-page-theme-a ui-page-theme-b ui-page-theme-c" ).addClass( "ui-page-theme-" + themeClass );
$( "#ui-body-test" ).removeClass( "ui-body-a ui-body-b ui-body-c" ).addClass( "ui-body-" + themeClass );
$( "#ui-bar-test, #ui-bar-form" ).removeClass( "ui-bar-a ui-bar-b ui-bar-c" ).addClass( "ui-bar-" + themeClass );
$( ".ui-collapsible-content" ).removeClass( "ui-body-a ui-body-b ui-body-c" ).addClass( "ui-body-" + themeClass );
$( "#testpage" ).removeClass( "ui-page-theme-a ui-page-theme-b" ).addClass( "ui-page-theme-" + themeClass );
$( "#ui-body-test" ).removeClass( "ui-body-a ui-body-b" ).addClass( "ui-body-" + themeClass );
$( "#ui-bar-test, #ui-bar-form" ).removeClass( "ui-bar-a ui-bar-b" ).addClass( "ui-bar-" + themeClass );
$( ".ui-collapsible-content" ).removeClass( "ui-body-a ui-body-b" ).addClass( "ui-body-" + themeClass );
$( ".theme" ).text( themeClass );
});
$( "#opt-shadow input" ).on( "change", function( event ) {
@@ -26,6 +26,15 @@
$( "#testpage" ).addClass( "noshadow" );
}
});
$( "#opt-navbars input" ).on( "change", function( event ) {
if ( $( "#show" ).prop( "checked" ) ) {
$( "#testpage .ui-navbar" ).show();
$( "#testpage .ui-footer h4" ).hide();
} else if ( $( "#hide" ).prop( "checked" ) ) {
$( "#testpage .ui-navbar" ).hide();
$( "#testpage .ui-footer h4" ).show();
}
});
});
</script>
<style>
@@ -43,6 +52,13 @@
<h1>Theme inheritance</h1>
<a href="../../" data-role="button" data-rel="back" data-icon="back" data-iconpos="notext">Back</a>
<a href="#" data-role="button" data-icon="gear">Button</a>
<div data-role="navbar">
<ul>
<li><a href="#" class="ui-btn-active ui-state-persist">Menu item 1</a></li>
<li><a href="#">Menu item 1</a></li>
<li><a href="#">Menu item 1</a></li>
</ul>
</div>
</div><!-- /header -->
<div data-role="content">
@@ -55,8 +71,6 @@
<input type="radio" name="theme" id="a" checked>
<label for="b">B</label>
<input type="radio" name="theme" id="b">
<label for="c">C</label>
<input type="radio" name="theme" id="c">
</fieldset>
</div>
<div data-role="fieldcontain" id="opt-shadow">
@@ -68,6 +82,15 @@
<input type="radio" name="shadow" id="off">
</fieldset>
</div>
<div data-role="fieldcontain" id="opt-navbars">
<fieldset data-role="controlgroup" data-type="horizontal">
<legend>Navbars:</legend>
<label for="show">Show</label>
<input type="radio" name="navbars" id="show" checked>
<label for="hide">Hide</label>
<input type="radio" name="navbars" id="hide">
</fieldset>
</div>
</form>
<div id="ui-body-test" class="ui-body ui-body-a ui-corner-all" style="margin-bottom:1em;">
@@ -237,6 +260,17 @@
</div>
</div><!-- /content -->
<div data-role="footer" data-position="fixed">
<div data-role="navbar">
<ul>
<li><a href="#">Menu item 1</a></li>
<li><a href="#" class="ui-btn-active ui-state-persist">Menu item 1</a></li>
<li><a href="#">Menu item 1</a></li>
</ul>
</div>
<h4 style="display:none;">Footer</h4>
</div>
</div><!-- /page -->
</body>
@@ -55,7 +55,7 @@
<div data-demo-html="true">
<form>
<label for="textarea-1">Textarea:</label>
<textarea cols="40" rows="8" name="textarea-1" id="textarea-1"></textarea>
<textarea name="textarea-1" id="textarea-1"></textarea>
</form>
</div><!-- /demo-html -->

@@ -205,7 +205,7 @@ define( [ "jquery", "../jquery.mobile.vmouse", "../jquery.mobile.support.touch"

$this.bind( touchMoveEvent, moveHandler )
.one( touchStopEvent, function() {
emitted = false;
emitted = true;
});
});
},
@@ -18,6 +18,7 @@
'events/throttledresize.js',
'events/orientationchange.js',
'jquery.hashchange.js',
'jquery.ui.core.js',
'jquery.mobile.defaults.js',
'jquery.mobile.helpers.js',
'jquery.mobile.data.js',
@@ -62,6 +63,8 @@
'widgets/forms/slider.tooltip.js',
'widgets/forms/rangeslider.js',
'widgets/forms/textinput.js',
'widgets/forms/clearButton.js',
'widgets/forms/autogrow.js',
'widgets/forms/select.js',
'widgets/forms/select.custom.js',
'jquery.mobile.buttonMarkup.js',
@@ -18,12 +18,17 @@ define( [ "jquery", "./jquery.mobile.core", "./jquery.mobile.registry" ], functi

// Map classes to buttonMarkup boolean options - used in classNameToOptions()
var reverseBoolOptionMap = {
"ui-shadow" : "shadow",
"ui-corner-all" : "corners",
"ui-btn-inline" : "inline",
"ui-shadow-icon" : "iconshadow", /* TODO: Remove in 1.5 */
"ui-mini" : "mini"
};
"ui-shadow" : "shadow",
"ui-corner-all" : "corners",
"ui-btn-inline" : "inline",
"ui-shadow-icon" : "iconshadow", /* TODO: Remove in 1.5 */
"ui-mini" : "mini"
},
getAttrFixed = function() {
var ret = $.mobile.getAttribute.apply( this, arguments );

return ( ret == null ? undefined : ret );
};

// optionsToClasses:
// @options: A complete set of options to convert to class names.
@@ -238,8 +243,7 @@ $.fn.buttonMarkup.defaults = {
// without having to write it inline and may be moved into the enhancer in the
// future.
function enhanceWithButtonMarkup( idx, el ) {
var classes,
getAttrFixed = $.mobile.getAttribute;
var classes;

classes = optionsToClasses( $.extend( {},
$.fn.buttonMarkup.defaults, {
@@ -11,6 +11,7 @@ define( [ "jquery", "./jquery.mobile.ns", "json!../package.json" ], function( jQ
var nsNormalizeDict = {},
// Monkey-patching Sizzle to filter the :jqmData selector
oldFind = $.find,
rbrace = /(?:\{[\s\S]*\}|\[[\s\S]*\])$/,
jqmDataRE = /:jqmData\(([^)]*)\)/g;

$.extend($.mobile, {
@@ -22,17 +23,27 @@ define( [ "jquery", "./jquery.mobile.ns", "json!../package.json" ], function( jQ
// Retrieve an attribute from an element and perform some massaging of the value

getAttribute: function( e, key, dns ) {
var value;
var data;

if ( dns ) {
key = "data-" + $.mobile.ns + key;
}

value = e.getAttribute( key );

return value === "true" ? true :
value === "false" ? false :
value === null ? undefined : value;
data = e.getAttribute( key );

// Copied from core's src/data.js:dataAttr()
// Convert from a string to a proper data type
try {
data = data === "true" ? true :
data === "false" ? false :
data === "null" ? null :
// Only convert to a number if it doesn't change the string
+data + "" === data ? +data :
rbrace.test( data ) ? JSON.parse( data ) :
data;
} catch( err ) {}

return data;
},

// Expose our cache for testing purposes.
@@ -5,7 +5,7 @@
//>>css.structure: ../css/structure/jquery.mobile.core.css
//>>css.theme: ../css/themes/default/jquery.mobile.theme.css

define( [ "jquery", "./jquery.mobile.ns", "json!../package.json" ], function( jQuery ) {
define( [ "jquery", "./jquery.mobile.ns", "./jquery.ui.core", "json!../package.json" ], function( jQuery ) {
//>>excludeEnd("jqmBuildExclude");
(function( $, window, undefined ) {

@@ -16,24 +16,7 @@ define( [ "jquery", "./jquery.mobile.ns", "json!../package.json" ], function( jQ
document: $( document ),

//TODO: Remove once we pull in UI Core
keyCode: {
BACKSPACE: 8,
COMMA: 188,
DELETE: 46,
DOWN: 40,
END: 35,
ENTER: 13,
ESCAPE: 27,
HOME: 36,
LEFT: 37,
PAGE_DOWN: 34,
PAGE_UP: 33,
PERIOD: 190,
RIGHT: 39,
SPACE: 32,
TAB: 9,
UP: 38
},
keyCode: $.ui.keyCode,

// Place to store various widget extensions
behaviors: {},
@@ -189,27 +172,8 @@ define( [ "jquery", "./jquery.mobile.ns", "json!../package.json" ], function( jQ
$.find.matchesSelector = function( node, expr ) {
return $.find( expr, null, null, [ node ] ).length > 0;
};
//Needed for ui widgets
//TODO: Remove once ui core is pulled in
var uuid = 0,
runiqueId = /^ui-id-\d+$/;
$.fn.extend({
uniqueId: function() {
return this.each(function() {
if ( !this.id ) {
this.id = "ui-id-" + (++uuid);
}
});
},
removeUniqueId: function() {
return this.each(function() {
if ( runiqueId.test( this.id ) ) {
$( this ).removeAttr( "id" );
}
});
}
});

})( jQuery, this );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
});
//>>excludeEnd("jqmBuildExclude");
//>>excludeEnd("jqmBuildExclude");
@@ -6,6 +6,7 @@

define([
"jquery",
"./jquery.ui.core",
"./jquery.mobile.defaults",
"./jquery.mobile.helpers",
"./jquery.mobile.data",
@@ -78,7 +79,10 @@ define([
$.mobile.firstPage = $pages.first();

// define page container
$.mobile.pageContainer = $.mobile.firstPage.parent().addClass( "ui-mobile-viewport" );
$.mobile.pageContainer = $.mobile.firstPage
.parent()
.addClass( "ui-mobile-viewport" )
.content();

// initialize navigation events now, after mobileinit has occurred and the page container
// has been created but before the rest of the library is alerted to that fact
@@ -140,6 +144,9 @@ define([
// then check what the scroll top is. Android will report 0... others 1
// note that this initial scroll won't hide the address bar. It's just for the check.
$(function() {
//Run inlineSVG support test
$.support.inlineSVG();

window.scrollTo( 0, 1 );

// if defaultHomeScroll hasn't been set yet, see if scrollTop is 1

Large diffs are not rendered by default.

@@ -61,6 +61,27 @@ function validStyle( prop, value, check_vend ) {
return !!ret;
}

// inline SVG support test
function inlineSVG() {
// Thanks Modernizr & Erik Dahlstrom
var w = window,
svg = !!w.document.createElementNS && !!w.document.createElementNS("http://www.w3.org/2000/svg", "svg").createSVGRect && !!document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#Image", "1.1"),
support = function( data ) {
if ( !( data && svg ) ) {
$( "html" ).addClass( "ui-nosvg" );
}
},
img = new w.Image();

img.onerror = function() {
support( false );
};
img.onload = function() {
support( img.width === 1 && img.height === 1 );
};
img.src = "data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==";
}

function transform3dTest() {
var mqProp = "transform-3d",
// Because the `translate3d` test below throws false positives in Android:
@@ -212,7 +233,8 @@ $.extend( $.support, {

dynamicBaseTag: baseTagTest(),
cssPointerEvents: cssPointerEventsTest(),
boundingRect: boundingRect()
boundingRect: boundingRect(),
inlineSVG: inlineSVG
});

fakeBody.remove();
@@ -259,7 +281,7 @@ if ( nokiaLTE7_3 ) {

// For ruling out shadows via css
if ( !$.support.boxShadow ) {
$( "html" ).addClass( "ui-mobile-nosupport-boxshadow" );
$( "html" ).addClass( "ui-noboxshadow" );
}

})( jQuery );
@@ -20,7 +20,7 @@ $.extend( $.Widget.prototype, {
return "-" + c.toLowerCase();
}), true );

if ( value !== undefined ) {
if ( value != null ) {
options[ option ] = value;
}
});
@@ -0,0 +1,293 @@
/*!
* jQuery UI Core @VERSION
* http://jqueryui.com
*
* Copyright 2013 jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*
* http://api.jqueryui.com/category/ui-core/
*/
(function( $, undefined ) {

var uuid = 0,
runiqueId = /^ui-id-\d+$/;

// $.ui might exist from components with no dependencies, e.g., $.ui.position
$.ui = $.ui || {};

$.extend( $.ui, {
version: "@VERSION",

keyCode: {
BACKSPACE: 8,
COMMA: 188,
DELETE: 46,
DOWN: 40,
END: 35,
ENTER: 13,
ESCAPE: 27,
HOME: 36,
LEFT: 37,
PAGE_DOWN: 34,
PAGE_UP: 33,
PERIOD: 190,
RIGHT: 39,
SPACE: 32,
TAB: 9,
UP: 38
}
});

// plugins
$.fn.extend({
focus: (function( orig ) {
return function( delay, fn ) {
return typeof delay === "number" ?
this.each(function() {
var elem = this;
setTimeout(function() {
$( elem ).focus();
if ( fn ) {
fn.call( elem );
}
}, delay );
}) :
orig.apply( this, arguments );
};
})( $.fn.focus ),

scrollParent: function() {
var scrollParent;
if (($.ui.ie && (/(static|relative)/).test(this.css("position"))) || (/absolute/).test(this.css("position"))) {
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"));
}).eq(0);
} else {
scrollParent = this.parents().filter(function() {
return (/(auto|scroll)/).test($.css(this,"overflow")+$.css(this,"overflow-y")+$.css(this,"overflow-x"));
}).eq(0);
}

return ( /fixed/ ).test( this.css( "position") ) || !scrollParent.length ? $( this[ 0 ].ownerDocument || document ) : scrollParent;
},

uniqueId: function() {
return this.each(function() {
if ( !this.id ) {
this.id = "ui-id-" + (++uuid);
}
});
},

removeUniqueId: function() {
return this.each(function() {
if ( runiqueId.test( this.id ) ) {
$( this ).removeAttr( "id" );
}
});
}
});

// selectors
function focusable( element, isTabIndexNotNaN ) {
var map, mapName, img,
nodeName = element.nodeName.toLowerCase();
if ( "area" === nodeName ) {
map = element.parentNode;
mapName = map.name;
if ( !element.href || !mapName || map.nodeName.toLowerCase() !== "map" ) {
return false;
}
img = $( "img[usemap=#" + mapName + "]" )[0];
return !!img && visible( img );
}
return ( /input|select|textarea|button|object/.test( nodeName ) ?
!element.disabled :
"a" === nodeName ?
element.href || isTabIndexNotNaN :
isTabIndexNotNaN) &&
// the element and all of its ancestors must be visible
visible( element );
}

function visible( element ) {
return $.expr.filters.visible( element ) &&
!$( element ).parents().addBack().filter(function() {
return $.css( this, "visibility" ) === "hidden";
}).length;
}

$.extend( $.expr[ ":" ], {
data: $.expr.createPseudo ?
$.expr.createPseudo(function( dataName ) {
return function( elem ) {
return !!$.data( elem, dataName );
};
}) :
// support: jQuery <1.8
function( elem, i, match ) {
return !!$.data( elem, match[ 3 ] );
},

focusable: function( element ) {
return focusable( element, !isNaN( $.attr( element, "tabindex" ) ) );
},

tabbable: function( element ) {
var tabIndex = $.attr( element, "tabindex" ),
isTabIndexNaN = isNaN( tabIndex );
return ( isTabIndexNaN || tabIndex >= 0 ) && focusable( element, !isTabIndexNaN );
}
});

// support: jQuery <1.8
if ( !$( "<a>" ).outerWidth( 1 ).jquery ) {
$.each( [ "Width", "Height" ], function( i, name ) {
var side = name === "Width" ? [ "Left", "Right" ] : [ "Top", "Bottom" ],
type = name.toLowerCase(),
orig = {
innerWidth: $.fn.innerWidth,
innerHeight: $.fn.innerHeight,
outerWidth: $.fn.outerWidth,
outerHeight: $.fn.outerHeight
};

function reduce( elem, size, border, margin ) {
$.each( side, function() {
size -= parseFloat( $.css( elem, "padding" + this ) ) || 0;
if ( border ) {
size -= parseFloat( $.css( elem, "border" + this + "Width" ) ) || 0;
}
if ( margin ) {
size -= parseFloat( $.css( elem, "margin" + this ) ) || 0;
}
});
return size;
}

$.fn[ "inner" + name ] = function( size ) {
if ( size === undefined ) {
return orig[ "inner" + name ].call( this );
}

return this.each(function() {
$( this ).css( type, reduce( this, size ) + "px" );
});
};

$.fn[ "outer" + name] = function( size, margin ) {
if ( typeof size !== "number" ) {
return orig[ "outer" + name ].call( this, size );
}

return this.each(function() {
$( this).css( type, reduce( this, size, true, margin ) + "px" );
});
};
});
}

// support: jQuery <1.8
if ( !$.fn.addBack ) {
$.fn.addBack = function( selector ) {
return this.add( selector == null ?
this.prevObject : this.prevObject.filter( selector )
);
};
}

// support: jQuery 1.6.1, 1.6.2 (http://bugs.jquery.com/ticket/9413)
if ( $( "<a>" ).data( "a-b", "a" ).removeData( "a-b" ).data( "a-b" ) ) {
$.fn.removeData = (function( removeData ) {
return function( key ) {
if ( arguments.length ) {
return removeData.call( this, $.camelCase( key ) );
} else {
return removeData.call( this );
}
};
})( $.fn.removeData );
}





// deprecated
$.ui.ie = !!/msie [\w.]+/.exec( navigator.userAgent.toLowerCase() );

$.support.selectstart = "onselectstart" in document.createElement( "div" );
$.fn.extend({
disableSelection: function() {
return this.bind( ( $.support.selectstart ? "selectstart" : "mousedown" ) +
".ui-disableSelection", function( event ) {
event.preventDefault();
});
},

enableSelection: function() {
return this.unbind( ".ui-disableSelection" );
},

zIndex: function( zIndex ) {
if ( zIndex !== undefined ) {
return this.css( "zIndex", zIndex );
}

if ( this.length ) {
var elem = $( this[ 0 ] ), position, value;
while ( elem.length && elem[ 0 ] !== document ) {
// Ignore z-index if position is set to a value where z-index is ignored by the browser
// This makes behavior of this function consistent across browsers
// WebKit always returns auto if the element is positioned
position = elem.css( "position" );
if ( position === "absolute" || position === "relative" || position === "fixed" ) {
// IE returns 0 when zIndex is not specified
// other browsers return a string
// we ignore the case of nested elements with an explicit value of 0
// <div style="z-index: -10;"><div style="z-index: 0;"></div></div>
value = parseInt( elem.css( "zIndex" ), 10 );
if ( !isNaN( value ) && value !== 0 ) {
return value;
}
}
elem = elem.parent();
}
}

return 0;
}
});

// $.ui.plugin is deprecated. Use $.widget() extensions instead.
$.ui.plugin = {
add: function( module, option, set ) {
var i,
proto = $.ui[ module ].prototype;
for ( i in set ) {
proto.plugins[ i ] = proto.plugins[ i ] || [];
proto.plugins[ i ].push( [ option, set[ i ] ] );
}
},
call: function( instance, name, args, allowDisconnected ) {
var i,
set = instance.plugins[ name ];

if ( !set ) {
return;
}

if ( !allowDisconnected && ( !instance.element[ 0 ].parentNode || instance.element[ 0 ].parentNode.nodeType === 11 ) ) {
return;
}

for ( i = 0; i < set.length; i++ ) {
if ( instance.options[ set[ i ][ 0 ] ] ) {
set[ i ][ 1 ].apply( instance.element, args );
}
}
}
};

})( jQuery );
@@ -11,6 +11,13 @@ requirejs.config({
"jquery.ui.widget": {
deps: [ "jquery" ],
exports: "$.widget"
},
"widgets/jquery.ui.tabs": {
deps: [ "jquery.ui.widget" ]
},
"widgets/jquery.ui.core": {
deps: [ "jquery" ],
exports: [ "$.ui" ]
}
}
});
@@ -15,19 +15,12 @@ define( ["jquery", "../jquery.mobile.core", "./serial", "./concurrent"], functio

//transition handler dictionary for 3rd party transitions
$.mobile.transitionHandlers = {
"default": $.mobile.defaultTransitionHandler,
"sequential": function( name, reverse, to, from ) {
return (new $.mobile.SerialTransition( name, reverse, to, from )).transition();
},

"simultaneous": function( name, reverse, to, from ) {
return (new $.mobile.ConcurrentTransition( name, reverse, to, from )).transition();
}
"sequential": $.mobile.SerialTransition,
"simultaneous": $.mobile.ConcurrentTransition
};

// Make our transition handler the public default.
$.mobile.defaultTransitionHandler = $.mobile.transitionHandlers.sequential;
$.mobile.transitionHandlers["default"] = $.mobile.defaultTransitionHandler;

$.mobile.transitionFallbacks = {};

@@ -98,7 +98,9 @@ define( [ "jquery",
// Set to page height
this.$to.height( screenHeight + this.toScroll );

this.scrollPage();
if ( !none ) {
this.scrollPage();
}
});

if ( !none ) {
@@ -0,0 +1,86 @@
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
//>>description: Enhances and consistently styles text inputs.
//>>label: Textarea Autosize
//>>group: Forms
//>>css.structure: ../css/structure/jquery.mobile.forms.textinput.css
//>>css.theme: ../css/themes/default/jquery.mobile.theme.css

define( [ "jquery", "../../jquery.mobile.core", "../../jquery.mobile.widget", "../../jquery.mobile.degradeInputs", "../../jquery.mobile.zoom", "../../jquery.mobile.registry","./textinput" ], function( jQuery ) {
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {

$.widget( "mobile.textinput", $.mobile.textinput, {
options: {
autogrow:true,
keyupTimeoutBuffer: 100
},

_create: function(){
this._super();

if( this.options.autogrow && this.isTextarea ) {
this._autogrow();
}
},

_autogrow: function() {
this._on({
"keyup": "_timeout",
"change": "_timeout",
"input": "_timeout",
"paste": "_timeout",
});

// Issue 509: the browser is not providing scrollHeight properly until the styles load
if ( $.trim( this.element.val() ) ) {
// bind to the window load to make sure the height is calculated based on BOTH
// the DOM and CSS
// binding to pagechange here ensures that for pages loaded via
// ajax the height is recalculated without user input
this._on( true, $.mobile.window, {
"load": "_timeout",
"pagechange": "_timeout"
});
}
},

_unbindAutogrow: function() {
this._off( this.element, "keyup change input paste" );
this._off( $.mobile.window, "load pagechange" );
},

keyupTimeout:null,

_timeout: function(){
clearTimeout( this.keyupTimeout );
this.keyupTimeout = this._delay( "_updateHeight", this.options.keyupTimeoutBuffer );
},

_updateHeight:function(){

this.element.css({
height: "auto"
}).css({
height: this.element[0].scrollHeight + 15 + "px"
});

},

_setOptions: function( options ){

this._super( options );

if( options.autogrow !== undefined && this.isTextarea ){
if( options.autogrow ){
this._autogrow();
} else {
this._unbindAutogrow();
}
}
}

});
})( jQuery );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
});
//>>excludeEnd("jqmBuildExclude");
@@ -0,0 +1,129 @@
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
//>>description: Add the ability to have a clear button
//>>label: Text Input Clear Button
//>>group: Forms
//>>css.structure: ../css/structure/jquery.mobile.forms.textinput.css
//>>css.theme: ../css/themes/default/jquery.mobile.theme.css

define( [ "jquery", "../../jquery.mobile.core", "../../jquery.mobile.widget", "../../jquery.mobile.degradeInputs", "../../jquery.mobile.zoom", "../../jquery.mobile.registry" ], function( jQuery ) {
//>>excludeEnd("jqmBuildExclude");
(function( $, undefined ) {

$.widget( "mobile.textinput", $.mobile.textinput, {
options: {
clearBtn: false,
clearBtnText: "clear text"
},

_create: function(){
this._super();

if( !!this.options.clearBtn || this.isSearch ){
this._addClearBtn();
}
},

clearButton: function(){

return $( "<a href='#' class='ui-input-clear ui-btn ui-icon-delete ui-btn-icon-notext ui-corner-all" +
"' title='" + this.options.clearBtnText + "'>" + this.options.clearBtnText + "</a>" );

},

_clearBtnClick: function( event ){
this.element.val( "" )
.focus()
.trigger( "change" );

this._clearBtn.addClass( "ui-input-clear-hidden" );
event.preventDefault();
},

_addClearBtn: function(){

if( !this.options.enhanced ) {
this._enhanceClear();
}

$.extend( this, {
_clearBtn: this.widget().find("a.ui-input-clear")
});

this._bindClearEvents();

this._toggleClear();

},

_enhanceClear: function() {

this.clearButton().appendTo( this.widget() );
this.widget().addClass( "ui-input-has-clear" );

},

_bindClearEvents: function() {

this._on( this._clearBtn, {
"click": "_clearBtnClick"
});

this._on({
"keyup": "_toggleClear",
"change": "_toggleClear",
"input": "_toggleClear",
"focus": "_toggleClear",
"blur": "_toggleClear",
"cut": "_toggleClear",
"paste": "_toggleClear"

});

},

_unbindClear: function() {
this._off( this._clearBtn, "click");
this._off( this.element, "keyup change input focus blur cut paste" );
},

_setOptions:function( options ) {
this._super( options );

if( options.clearbtn !== undefined && !this.element.is( "textarea, :jqmData(type='range')" ) ) {
if( options.clearBtn ){
this._addClearBtn();
} else {
this._destroyClear();
}
}

if( options.clearBtnText !== undefined && this._clearBtn !== undefined ) {
this._clearBtn.text( options.clearBtnText );
}
},

_toggleClear: function() {
this._delay( "_toggleClearClass", 0 );
},

_toggleClearClass: function(){
this._clearBtn.toggleClass( "ui-input-clear-hidden", !this.element.val() );
},

_destroyClear: function() {
this.element.removeClass( "ui-input-has-clear" );
this._unbindClear()._clearBtn.remove();
},

_destroy: function() {
this._super();
this._destroyClear();
}

});


})( jQuery );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
});
//>>excludeEnd("jqmBuildExclude");
@@ -117,7 +117,7 @@ $.widget( "mobile.selectmenu", $.mobile.selectmenu, {
// of a dialog sized custom select
//
// doing this here provides for the back button on the custom select dialog
$.mobile._bindPageRemove.call( this.thisPage );
this.thisPage.page( "bindRemove" );
},

_handleHeaderCloseClick: function() {
@@ -545,4 +545,4 @@ $.mobile._enhancer.add( "mobile.selectmenu", { dependencies: [ "mobile.popup" ]
})( jQuery );
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
});
//>>excludeEnd("jqmBuildExclude");
//>>excludeEnd("jqmBuildExclude");
@@ -13,7 +13,7 @@ $.widget( "mobile.selectmenu", $.extend( {
options: {
theme: null,
disabled: false,
icon: "arrow-d",
icon: "carat-d",
iconpos: "right",
inline: false,
corners: true,
@@ -16,170 +16,143 @@ $.widget( "mobile.textinput", {
mini: false,
// This option defaults to true on iOS devices.
preventFocusZoom: /iPhone|iPad|iPod/.test( navigator.platform ) && navigator.userAgent.indexOf( "AppleWebKit" ) > -1,
clearBtn: false,
clearBtnText: "clear text",
disabled: false
wrapperClass: "",
enhanced: false
},

_create: function() {

var self = this,
input = this.element,
o = this.options,
var o = this.options,
themeclass = " ui-body-" + ( o.theme ? o.theme : "inherit" ),
cornerclass = o.corners ? " ui-corner-all" : "",
miniclass = o.mini ? " ui-mini" : "",
isSearch = input.is( "[type='search'], :jqmData(type='search')" ),
isTextarea = input[ 0 ].tagName === "TEXTAREA",
focusedEl,
classes,
clearbtn,
clearBtnText = o.clearBtnText,
clearBtnBlacklist = input.is( "textarea, :jqmData(type='range')" ),
inputNeedsClearBtn = !!o.clearBtn && !clearBtnBlacklist,
inputNeedsWrap = input.is( "input" ) && !input.is( ":jqmData(type='range')" ),
extraLineHeight = 15,
keyupTimeoutBuffer = 100,
keyupTimeout;

function toggleClear() {
setTimeout( function() {
clearbtn.toggleClass( "ui-input-clear-hidden", !input.val() );
}, 0 );
isSearch = this.element.is( "[type='search'], :jqmData(type='search')" ),
isTextarea = this.element[ 0 ].tagName === "TEXTAREA",
inputNeedsWrap = ((this.element.is( "input" ) || this.element.is( "[data-" + ( $.mobile.ns || "" ) + "type='search']" ) )&& !this.element.is( "[data-" + ( $.mobile.ns || "" ) + "type='range']" ));

$.extend( this, {
themeclass: themeclass,
cornerclass: cornerclass,
miniclass: miniclass,
isSearch: isSearch,
isTextarea: isTextarea,
inputNeedsWrap: inputNeedsWrap
});

this._autoCorrect();

if( this.element[0].disabled ){
this.options.disabled = true;
}

if( !o.enhanced ) {
this._enhance();
}

this._on( {
"focus": "_handleFocus",
"blur": "_handleBlur"
});

},

refresh: function(){
this.setOptions({
"disabled" : this.element.is(":disabled")
});
},

_enhance: function(){

if( this.isTextarea ) {
this.element.addClass( "ui-input-text" );
}

focusedEl = isTextarea ? input.addClass( "ui-input-text" + themeclass ) : input;
if( this.element.is( "textarea, [data-" + ( $.mobile.ns || "" ) + "type='range']" ) ){
this.element.addClass( "ui-shadow-inset" );
this._setOptions( this.options );
}

//"search" and "text" input widgets
if ( this.inputNeedsWrap ) {
this.element.wrap( this._wrap() );
}

},

widget: function(){
return ( this.inputNeedsWrap ) ? this.element.parent(): this.element;
},

_wrap: function(){
return $( "<div class='" + ( this.isSearch ? "ui-input-search" : "ui-input-text" ) + " ui-body-" + (( this.options.theme === null ) ? "inherit": this.options.theme ) + ( this.options.corners ? " ui-corner-all": "" ) + ( this.options.mini ? " ui-mini": "" ) + ( this.options.disabled ? " ui-disabled ": "" ) + " ui-shadow-inset'></div>" );
},

_autoCorrect: function(){
// XXX: Temporary workaround for issue 785 (Apple bug 8910589).
// Turn off autocorrect and autocomplete on non-iOS 5 devices
// since the popup they use can't be dismissed by the user. Note
// that we test for the presence of the feature by looking for
// the autocorrect property on the input element. We currently
// have no test for iOS 5 or newer so we're temporarily using
// the touchOverflow support flag for jQM 1.0. Yes, I feel dirty. - jblas
if ( typeof input[0].autocorrect !== "undefined" && !$.support.touchOverflow ) {
if ( typeof this.element[0].autocorrect !== "undefined" && !$.support.touchOverflow ) {
// Set the attribute instead of the property just in case there
// is code that attempts to make modifications via HTML.
input[0].setAttribute( "autocorrect", "off" );
input[0].setAttribute( "autocomplete", "off" );
this.element[0].setAttribute( "autocorrect", "off" );
this.element[0].setAttribute( "autocomplete", "off" );
}
},

//"search" and "text" input widgets
if ( isSearch || inputNeedsWrap ) {
classes = isSearch ? "ui-input-search" : "ui-input-text";
_handleBlur: function() {
this.element.removeClass( $.mobile.focusClass );
if ( this.options.preventFocusZoom ) {
$.mobile.zoom.enable( true );
}
},

focusedEl = input.wrap( "<div class='" + classes + themeclass + miniclass + cornerclass + " ui-shadow-inset'></div>" ).parent();
_handleFocus: function() {
// In many situations, iOS will zoom into the input upon tap, this prevents that from happening
if ( this.options.preventFocusZoom ) {
$.mobile.zoom.disable( true );
}
this.element.addClass( $.mobile.focusClass );
},

_setOptions: function ( options ) {
var themeclass;

if( inputNeedsClearBtn || isSearch ) {
clearbtn = $( "<a href='#' class='ui-input-clear' title='" + clearBtnText + "'>" + clearBtnText + "</a>" )
.bind( "click", function( event ) {
input
.val( "" )
.focus()
.trigger( "change" );
clearbtn.addClass( "ui-input-clear-hidden" );
event.preventDefault();
})
.appendTo( focusedEl )
.addClass(
"ui-btn ui-icon-delete ui-btn-icon-notext" +
" ui-corner-all ui-shadow " +
( o.theme ? "ui-btn-" + o.theme : "" ) +
( o.mini ? "ui-mini" : "" ) );

if ( !isSearch ) {
focusedEl.addClass( "ui-input-has-clear" );
}

toggleClear();

input.bind( "paste cut keyup input focus change blur", toggleClear );
} else if ( !inputNeedsWrap && !isSearch ) {
input.addClass( "ui-shadow-inset" + themeclass + miniclass + cornerclass );
}
this._super( options );

input.focus(function() {
// In many situations, iOS will zoom into the input upon tap, this prevents that from happening
if ( o.preventFocusZoom ) {
$.mobile.zoom.disable( true );
}
focusedEl.addClass( $.mobile.focusClass );
})
.blur(function() {
focusedEl.removeClass( $.mobile.focusClass );
if ( o.preventFocusZoom ) {
$.mobile.zoom.enable( true );
}
});

// Autogrow
if ( isTextarea ) {
this._keyup = function() {
var scrollHeight = input[ 0 ].scrollHeight,
clientHeight = input[ 0 ].clientHeight,
paddingTop, paddingBottom, paddingHeight;


if ( clientHeight < scrollHeight ) {
paddingTop = parseFloat( input.css( "padding-top" ) );
paddingBottom = parseFloat( input.css( "padding-bottom" ) );
paddingHeight = paddingTop + paddingBottom;

input.height( scrollHeight - paddingHeight + extraLineHeight );
}
};

input.on( "keyup change input paste", function() {
clearTimeout( keyupTimeout );
keyupTimeout = setTimeout( self._keyup, keyupTimeoutBuffer );
});

// binding to pagechange here ensures that for pages loaded via
// ajax the height is recalculated without user input
this._on( true, $.mobile.document, { "pagechange": "_keyup" });

// Issue 509: the browser is not providing scrollHeight properly until the styles load
if ( $.trim( input.val() ) ) {
// bind to the window load to make sure the height is calculated based on BOTH
// the DOM and CSS
this._on( true, $.mobile.window, {"load": "_keyup"});
}
if( options.theme !== undefined ) {
themeclass = "ui-body-" + (( options.theme === null ) ? "inherit": options.theme );
this.widget().removeClass( this.themeclass ).addClass( themeclass );
this.themeclass = themeclass;
}
if ( input.attr( "disabled" ) ) {
this.disable();

if( options.corners !== undefined ) {
this.widget().removeClass( "ui-corner-all" ).addClass( options.corners ? "ui-corner-all": "" );
}
},

disable: function() {
var $el,
isSearch = this.element.is( "[type='search'], :jqmData(type='search')" ),
inputNeedsWrap = this.element.is( "input" ) && !this.element.is( ":jqmData(type='range')" ),
parentNeedsDisabled = this.element.attr( "disabled", true ) && ( inputNeedsWrap || isSearch );
if( options.mini !== undefined ) {
this.widget().removeClass( "ui-mini" ).addClass( options.mini ? "ui-mini": "" );
}

if ( parentNeedsDisabled ) {
$el = this.element.parent();
} else {
$el = this.element;
if( options.disabled !== undefined ) {
this.element.prop( "disabled", !!options.disabled );
this.widget().toggleClass( "ui-disabled", !!options.disabled );
}
$el.addClass( "ui-disabled" );
return this._setOption( "disabled", true );
},

enable: function() {
var $el,
isSearch = this.element.is( "[type='search'], :jqmData(type='search')" ),
inputNeedsWrap = this.element.is( "input" ) && !this.element.is( ":jqmData(type='range')" ),
parentNeedsEnabled = this.element.attr( "disabled", false ) && ( inputNeedsWrap || isSearch );
},

if ( parentNeedsEnabled ) {
$el = this.element.parent();
} else {
$el = this.element;
_destroy: function() {
if( this.options.enhanced ){
return;
}
if( this.inputNeedsWrap ){
this.element.unwrap();
}
$el.removeClass( "ui-disabled" );
return this._setOption( "disabled", false );
this.element.removeClass( "ui-input-text " + this.themeclass + " ui-corner-all ui-mini ui-disabled" );
}
});

@@ -17,8 +17,8 @@ $.widget( "mobile.listview", $.extend( {
theme: null,
countTheme: null,
dividerTheme: null,
icon: "arrow-r",
splitIcon: "arrow-r",
icon: "carat-r",
splitIcon: "carat-r",
splitTheme: null,
corners: true,
shadow: true,
@@ -195,7 +195,8 @@ $.widget( "mobile.listview", $.extend( {
this._addFirstLastClasses( li, this._getVisibles( li, create ), create );
// autodividers binds to this to redraw dividers after the listview refresh
this._trigger( "afterrefresh" );
}}, $.mobile.behaviors.addFirstLastClasses ) );
}
}, $.mobile.behaviors.addFirstLastClasses ) );

$.mobile.listview.initSelector = ":jqmData(role='listview')";

@@ -30,6 +30,10 @@ $.widget( "mobile.page", {
return false;
}

if ( this.options.role ) {
this.element.attr( "data-" + $.mobile.ns + "role", this.options.role );
}

this.element
.attr( "tabindex", "0" )
.addClass( "ui-page ui-page-theme-" + this.options.theme );
@@ -54,6 +58,27 @@ $.widget( "mobile.page", {
$.mobile._enhancer.enhance( this.element[ 0 ] );
},

bindRemove: function( callback ) {
var page = this.element;

// when dom caching is not enabled or the page is embedded bind to remove the page on hide
if ( !page.data( "mobile-page" ).options.domCache &&
page.is( ":jqmData(external-page='true')" ) ) {

// TODO use _on - that is, sort out why it doesn't work in this case
page.bind( "pagehide.remove", callback || function(/* e */) {
var $this = $( this ),
prEvent = new $.Event( "pageremove" );

$this.trigger( prEvent );

if ( !prEvent.isDefaultPrevented() ) {
$this.removeWithDependents();
}
});
}
},

_setOptions: function( o ) {
if( o.theme !== undefined ) {
this.element.removeClass( "ui-body-" + this.options.theme ).addClass( "ui-body-" + o.theme );
@@ -52,7 +52,7 @@ $.widget( "mobile.panel", {
page = $el.closest( ":jqmData(role='page')" ),
_getPageTheme = function() {
var $theme = $.data( page[0], "mobile-page" ).options.theme,
$pageThemeClass = "ui-body-" + $theme;
$pageThemeClass = "ui-page-theme-" + $theme;
return $pageThemeClass;
},
_getPanelInner = function() {
@@ -299,7 +299,7 @@ $.widget( "mobile.panel", {
if ( self.options.theme && self.options.display !== "overlay" ) {
self._page
.removeClass( self._pageTheme )
.addClass( "ui-body-" + self.options.theme );
.addClass( "ui-page-theme-" + self.options.theme );
}

self.element.removeClass( o.classes.panelClosed ).addClass( o.classes.panelOpen );
@@ -376,7 +376,7 @@ $.widget( "mobile.panel", {
},
complete = function() {
if ( self.options.theme && self.options.display !== "overlay" ) {
self._page.removeClass( "ui-body-" + self.options.theme ).addClass( self._pageTheme );
self._page.removeClass( "ui-page-theme-" + self.options.theme ).addClass( self._pageTheme );
// reset fix for IE7 min-height bug
self._wrapper.css( "min-height", "" );
}
@@ -430,7 +430,7 @@ $.widget( "mobile.panel", {
this._page.jqmRemoveData( "panel" );
this._page.removeClass( classes.pagePanelOpen );
if ( theme ) {
this._page.removeClass( "ui-body-" + theme ).addClass( this._pageTheme );
this._page.removeClass( "ui-page-theme-" + theme ).addClass( this._pageTheme );
}
$.mobile.resetActivePageHeight();
}
@@ -440,7 +440,7 @@ $.widget( "mobile.panel", {
this._page.jqmRemoveData( "panel" );
this._page.removeClass( classes.pagePanelOpen );
if ( theme ) {
this._page.removeClass( "ui-body-" + theme ).addClass( this._pageTheme );
this._page.removeClass( "ui-page-theme-" + theme ).addClass( this._pageTheme );
}
}

@@ -456,11 +456,7 @@ $.widget( "mobile.popup", {
_calculateFinalLocation: function( desired, clampInfo ) {
var ret,
rc = clampInfo.rc,
menuSize = clampInfo.menuSize,
// fix for $.mobile.document.height() bug in core 1.7.2.
docEl = document.documentElement,
docBody = document.body,
docHeight = Math.max( docEl.clientHeight, docBody.scrollHeight, docBody.offsetHeight, docEl.scrollHeight, docEl.offsetHeight );
menuSize = clampInfo.menuSize;


// Center the menu over the desired coordinates, while not going outside
@@ -476,7 +472,7 @@ $.widget( "mobile.popup", {
// If the height of the menu is smaller than the height of the document
// align the bottom with the bottom of the document

ret.y -= Math.min( ret.y, Math.max( 0, ret.y + menuSize.cy - docHeight ) );
ret.y -= Math.min( ret.y, Math.max( 0, ret.y + menuSize.cy - $.mobile.document.height() ) );

return { left: ret.x, top: ret.y };
},