Permalink
Browse files

Merge branch 'master' into 1.0-stable

  • Loading branch information...
2 parents de9d20e + 504582e commit 2c5de9b70989ecb2ab4b03a2d5ba29c4e3b4866b @johnbender johnbender committed Dec 13, 2011
Showing with 776 additions and 290 deletions.
  1. +24 −14 Makefile
  2. +11 −0 css/structure/jquery.mobile.core.css
  3. +1 −0 docs/_assets/css/jqm-docs.css
  4. +55 −8 docs/_assets/js/jqm-docs.js
  5. +2 −2 docs/about/features.html
  6. +1 −1 docs/about/platforms.html
  7. +4 −0 docs/api/data-attributes.html
  8. +18 −18 docs/api/events.html
  9. +2 −2 docs/api/globalconfig.html
  10. +3 −2 docs/forms/selects/index.html
  11. +29 −29 docs/forms/slider/index.html
  12. +1 −1 docs/forms/textinputs/index.html
  13. +7 −6 docs/lists/docs-lists.html
  14. +2 −1 docs/lists/index.html
  15. +1 −0 docs/lists/lists-all-full.html
  16. +2 −1 docs/lists/lists-count.html
  17. +1 −0 docs/lists/lists-divider.html
  18. +1 −0 docs/lists/lists-formatting.html
  19. +1 −0 docs/lists/lists-forms-inset.html
  20. +1 −0 docs/lists/lists-forms.html
  21. +1 −0 docs/lists/lists-icons.html
  22. +1 −0 docs/lists/lists-inset.html
  23. +1 −0 docs/lists/lists-nested.html
  24. +1 −0 docs/lists/lists-ol.html
  25. +1 −0 docs/lists/lists-performance.html
  26. +1 −0 docs/lists/lists-readonly-inset.html
  27. +1 −0 docs/lists/lists-readonly.html
  28. +96 −0 docs/lists/lists-search-filtertext.html
  29. +1 −0 docs/lists/lists-search-inset.html
  30. +1 −0 docs/lists/lists-search-with-dividers.html
  31. +1 −0 docs/lists/lists-search.html
  32. +2 −1 docs/lists/lists-split.html
  33. +1 −0 docs/lists/lists-themes.html
  34. +1 −0 docs/lists/lists-thumbnails.html
  35. +1 −0 docs/lists/lists-ul.html
  36. +1 −1 docs/pages/dynamic-samples/animals.html
  37. +1 −1 docs/pages/dynamic-samples/category.php
  38. +1 −1 docs/pages/dynamic-samples/colors.html
  39. +1 −1 docs/pages/dynamic-samples/index.html
  40. +1 −1 docs/pages/dynamic-samples/sample-reuse-page-external.html
  41. +14 −14 docs/pages/dynamic-samples/sample-reuse-page.html
  42. +1 −1 docs/pages/dynamic-samples/vehicles.html
  43. +34 −34 docs/pages/page-dynamic.html
  44. +1 −1 docs/pages/phonegap.html
  45. +12 −1 docs/pages/touchoverflow.html
  46. +1 −1 index.html
  47. +1 −0 js/index.php
  48. +4 −6 js/jquery.mobile.buttonMarkup.js
  49. +4 −48 js/jquery.mobile.collapsible.js
  50. +82 −0 js/jquery.mobile.collapsibleSet.js
  51. +15 −2 js/jquery.mobile.core.js
  52. +1 −1 js/jquery.mobile.degradeInputs.js
  53. +1 −1 js/jquery.mobile.dialog.js
  54. +4 −8 js/jquery.mobile.fixHeaderFooter.js
  55. +1 −1 js/jquery.mobile.forms.checkboxradio.js
  56. +1 −1 js/jquery.mobile.forms.select.custom.js
  57. +29 −21 js/jquery.mobile.forms.slider.js
  58. +4 −4 js/jquery.mobile.forms.textinput.js
  59. +0 −2 js/jquery.mobile.hashchange.js
  60. +0 −9 js/jquery.mobile.intro.js
  61. +3 −5 js/jquery.mobile.listview.filter.js
  62. +4 −2 js/jquery.mobile.navbar.js
  63. +3 −3 js/jquery.mobile.navigation.js
  64. +1 −1 js/jquery.mobile.page.sections.js
  65. +3 −1 js/jquery.mobile.support.js
  66. +1 −1 js/jquery.mobile.widget.js
  67. +2 −2 tests/speed/stats/perf.js
  68. +29 −1 tests/speed/stats/startup.js
  69. +14 −0 tests/unit/core/core.js
  70. +8 −0 tests/unit/core/index.html
  71. +35 −21 tests/unit/degradeInputs/degradeInputs.js
  72. +9 −2 tests/unit/degradeInputs/index.html
  73. +33 −0 tests/unit/navbar/index.html
  74. +18 −0 tests/unit/navbar/navbar_core.js
  75. +10 −0 tests/unit/slider/index.html
  76. +27 −0 tests/unit/slider/slider_core.js
  77. +8 −2 tests/unit/slider/slider_events.js
  78. +73 −0 tools/config-props.html
  79. +1 −1 tools/log-page-events.html
  80. +1 −1 tools/page-change-time.html
View
@@ -15,6 +15,7 @@ JSFILES = js/jquery.ui.widget.js \
js/jquery.mobile.dialog.js \
js/jquery.mobile.page.sections.js \
js/jquery.mobile.collapsible.js \
+ js/jquery.mobile.collapsibleSet.js \
js/jquery.mobile.fieldContain.js \
js/jquery.mobile.grid.js \
js/jquery.mobile.navbar.js \
@@ -58,8 +59,10 @@ CSSTHEMEFILES = css/themes/${THEME}/jquery.mobile.theme.css
# Helper Variables
# The command to replace the @VERSION in the files with the actual version
VER = sed "s/v@VERSION/$$(git log -1 --format=format:"Git Build: SHA1: %H <> Date: %cd")/"
-VER_MIN = "/*! jQuery Mobile v${VER_OFFICIAL} jquerymobile.com | jquery.org/license */"
+VER_MIN = "/*! jQuery Mobile v$$(git log -1 --format=format:"Git Build: SHA1: %H <> Date: %cd") jquerymobile.com | jquery.org/license */"
VER_OFFICIAL = $(shell cat version.txt)
+deploy: VER = sed "s/v@VERSION/${VER_OFFICIAL}/"
+deploy: VER_MIN = "/*! jQuery Mobile v${VER_OFFICIAL} jquerymobile.com | jquery.org/license */"
# The output folder for the finished files
OUTPUT = compiled
@@ -86,13 +89,13 @@ all: init css js zip notify
# Build and minify the CSS files
css: init
# Build the CSS file with the theme included
- @@cat js/jquery.mobile.intro.js | ${VER} > ${OUTPUT}/${NAME}.css
+ @@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${NAME}.css
@@cat ${CSSTHEMEFILES} ${CSSFILES} >> ${OUTPUT}/${NAME}.css
# ..... and then minify it
@@echo ${VER_MIN} > ${OUTPUT}/${NAME}.min.css
@@java -jar build/yuicompressor-2.4.6.jar --type css ${OUTPUT}/${NAME}.css >> ${OUTPUT}/${NAME}.min.css
# Build the CSS Structure-only file
- @@cat js/jquery.mobile.intro.js | ${VER} > ${OUTPUT}/${STRUCTURE}.css
+ @@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${STRUCTURE}.css
@@cat ${CSSFILES} >> ${OUTPUT}/${STRUCTURE}.css
# ..... and then minify it
@@echo ${VER_MIN} > ${OUTPUT}/${STRUCTURE}.min.css
@@ -106,15 +109,15 @@ css: init
docs: init css js
# Create the Demos/Docs/Tests/Tools
@@mkdir -p tmp/${NAME}
- @@cp -r index.html docs experiments external js/jquery.js tests tmp/${NAME}/
+ @@cp -R index.html docs experiments external js/jquery.js tests css/themes/${THEME}/images tmp/${NAME}/
@@cp ${OUTPUT}/${NAME}.min.css ${OUTPUT}/${NAME}.min.js tmp/${NAME}/
# ... Update the JavaScript and CSS paths
@@find tmp/${NAME} -type f \
\( -name '*.html' -o -name '*.php' \) \
-exec perl -pi -e \
's|js/"|${NAME}.min.js"|g;s|css/themes/default/|${NAME}.min.css|g;s|js/jquery.js"|jquery.js"|g' {} \;
# ... Move and zip up the the whole folder
- @@zip -rq ${OUTPUT}/${NAME}.docs.zip tmp/${NAME}
+ @@cd tmp; zip -rq ../${OUTPUT}/${NAME}.docs.zip ${NAME}
@@mv tmp/${NAME} ${OUTPUT}/demos
# Finish by removing the temporary files
@@rm -rf tmp
@@ -134,11 +137,16 @@ init:
# Build and minify the JS files
js: init
# Build the JavaScript file
- @@cat js/jquery.mobile.intro.js | ${VER} > ${OUTPUT}/${NAME}.js
+ @@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${NAME}.js
@@cat ${JSFILES} >> ${OUTPUT}/${NAME}.js
# ..... and then minify it
@@echo ${VER_MIN} > ${OUTPUT}/${NAME}.min.js
- @@java -jar build/google-compiler-20111003.jar --js ${OUTPUT}/${NAME}.js --warning_level QUIET >> ${OUTPUT}/${NAME}.min.js
+ @@java -XX:ReservedCodeCacheSize=64m \
+ -jar build/google-compiler-20111003.jar \
+ --js ${OUTPUT}/${NAME}.js \
+ --js_output_file ${OUTPUT}/${NAME}.tmp.js
+ @@cat ${OUTPUT}/${NAME}.tmp.js >> ${OUTPUT}/${NAME}.min.js
+ @@rm ${OUTPUT}/${NAME}.tmp.js
# -------------------------------------------------
@@ -149,11 +157,13 @@ notify: init
# Zip up the jQm files without docs
-zip: init css js
+zip: init css js
# Packaging up the files into a zip archive
@@mkdir tmp
- @@cp -r ${OUTPUT} tmp/${NAME}
- @@zip -rq ${OUTPUT}/${NAME}.zip tmp/${NAME}/
+ @@cp -R ${OUTPUT} tmp/${NAME}
+ # ... And remove the Zipped docs so they aren't included twice (for deploy scripts)
+ @@rm -rf tmp/${NAME}/${NAME}.docs.zip
+ @@cd tmp; zip -rq ../${OUTPUT}/${NAME}.zip ${NAME}
@@rm -rf tmp
# -------------------------------------------------
@@ -169,15 +179,15 @@ zip: init css js
# -------------------------------------------------
# Push the latest git version to the CDN. This is done on a post commit hook
-latest: init js css zip
+latest: init css js zip
# Time to put these on the CDN
@@scp -qr ${OUTPUT}/* jqadmin@code.origin.jquery.com:/var/www/html/code.jquery.com/mobile/latest/
# Do some cleanup to wrap it up
@@rm -rf ${OUTPUT}
# -------------------------------------------------
# Build the nightly backups. This is done on a server cronjob
-nightlies: init js css zip docs
+nightlies: init css js docs zip
# Time to put these on the CDN
@@mkdir -p tmp/nightlies
@@mv ${OUTPUT} tmp/nightlies/$$(date "+%Y%m%d")
@@ -188,10 +198,10 @@ nightlies: init js css zip docs
# Deploy a finished release. This is manually done.
-deploy: init js css docs zip
+deploy: init css js docs zip
# Deploying all the files to the CDN
@@mkdir tmp
- @@cp -r ${OUTPUT} tmp/${VER_OFFICIAL}
+ @@cp -R ${OUTPUT} tmp/${VER_OFFICIAL}
@@scp -qr tmp/* jqadmin@code.origin.jquery.com:/var/www/html/code.jquery.com/mobile/
@@rm -rf tmp/${VER_OFFICIAL}
@@mv ${OUTPUT}/demos tmp/${VER_OFFICIAL}
@@ -29,6 +29,8 @@ div.ui-mobile-viewport { overflow-x: hidden; }
.ui-mobile-touch-overflow.ui-native-fixed .ui-content {
overflow: auto;
height: 100%;
+ left: 0;
+ right: 0;
-webkit-overflow-scrolling: touch;
-moz-overflow-scrolling: touch;
-o-overflow-scrolling: touch;
@@ -43,6 +45,15 @@ div.ui-mobile-viewport { overflow-x: hidden; }
.ui-page.ui-mobile-pre-transition {
display: block;
}
+.ui-mobile-touch-overflow.ui-native-fixed .ui-content .ui-listview {
+ margin-top: 0;
+}
+.ui-mobile-touch-overflow.ui-native-fixed .ui-content .ui-listview-inset {
+ margin-top: 1em;
+}
+.ui-mobile-touch-overflow.ui-native-fixed .ui-header .ui-btn {
+ z-index: 10;
+}
/* loading screen */
.ui-loading .ui-mobile-viewport { overflow: hidden !important; }
@@ -14,6 +14,7 @@ body { background: #dddddd; }
h2 { margin:1.2em 0 .4em 0; }
p code { font-size:1.2em; font-weight:bold; }
+h4 code {font-size:1.2em; font-weight:bold; }
dt { font-weight: bold; margin: 2em 0 .5em; }
dt code, dd code { font-size:1.3em; line-height:150%; }
@@ -1,16 +1,16 @@
//set up the theme switcher on the homepage
$('div').live('pagecreate',function(event){
- if( !$(this).is('.ui-dialog')){
+ if( !$(this).is('.ui-dialog')){
var appendEl = $(this).find('.ui-footer:last');
-
+
if( !appendEl.length ){
appendEl = $(this).find('.ui-content');
}
-
+
if( appendEl.is("[data-position]") ){
return;
}
-
+
$('<a href="#themeswitcher" data-'+ $.mobile.ns +'rel="dialog" data-'+ $.mobile.ns +'transition="pop">Switch theme</a>')
.buttonMarkup({
'icon':'gear',
@@ -23,21 +23,21 @@ $('div').live('pagecreate',function(event){
.bind( "vclick", function(){
$.themeswitcher();
});
- }
+ }
});
//collapse page navs after use
$(function(){
$('body').delegate('.content-secondary .ui-collapsible-content', 'click', function(){
- $(this).trigger("collapse")
+ $(this).trigger("collapse");
});
});
function setDefaultTransition(){
var winwidth = $( window ).width(),
trans ="slide";
-
+
if( winwidth >= 1000 ){
trans = "none";
}
@@ -52,4 +52,51 @@ function setDefaultTransition(){
$(function(){
setDefaultTransition();
$( window ).bind( "throttledresize", setDefaultTransition );
-});
+});
+
+
+// Turn off AJAX for local file browsing
+if ( location.protocol.substr(0,4) === 'file' ||
+ location.protocol.substr(0,11) === '*-extension' ||
+ location.protocol.substr(0,6) === 'widget' ) {
+
+ // Start with links with only the trailing slash and that aren't external links
+ var fixLinks = function() {
+ $( "a[href$='/'], a[href='.'], a[href='..']" ).not( "[rel='external']" ).each( function() {
+ this.href = $( this ).attr( "href" ).replace( /\/$/, "" ) + "/index.html";
+ });
+ };
+
+ // fix the links for the initial page
+ $(fixLinks);
+
+ // fix the links for subsequent ajax page loads
+ $(document).bind( 'pagecreate', fixLinks );
+
+ // Check to see if ajax can be used. This does a quick ajax request and blocks the page until its done
+ $.ajax({
+ url: '.',
+ async: false,
+ isLocal: true
+ }).error(function() {
+ // Ajax doesn't work so turn it off
+ $( document ).bind( "mobileinit", function() {
+ $.mobile.ajaxEnabled = false;
+
+ var message = $( '<div>' , {
+ 'class': "ui-footer ui-bar-e",
+ style: "overflow: auto; padding:10px 15px;",
+ 'data-ajax-warning': true
+ });
+
+ message
+ .append( "<h3>Note: Navigation may not work if viewed locally</h3>" )
+ .append( "<p>The AJAX-based navigation used throughout the jQuery Mobile docs may need to be viewed on a web server to work in certain browsers. If you see an error message when you click a link, try a different browser or <a href='https://github.com/jquery/jquery-mobile/wiki/Downloadable-Docs-Help'>view help</a>.</p>" );
+
+ $( document ).bind( "pagecreate", function( event ) {
+ $( event.target ).append( message );
+ });
+ });
+ });
+}
+
View
@@ -29,15 +29,15 @@
<li><strong>Built on jQuery core</strong> for familiar and consistent jQuery syntax and minimal learning curve and leverages jQuery UI code and patterns.</li>
<li><strong>Compatible with all major mobile, tablet, e-reader & desktop platforms</strong> - iOS, Android, Blackberry, Palm WebOS, Nokia/Symbian, Windows Phone 7, MeeGo, Opera Mobile/Mini, Firefox Mobile, Kindle, Nook, and all modern browsers with graded levels of support.</li>
<li><strong>Lightweight size</strong> and minimal image dependencies for speed.</li>
- <li><strong>Modular architecture</strong> for creating custom builds that are optimized to only the features needed for a particular application</li>
+ <li><strong>Modular architecture</strong> for creating custom builds that are optimized to only include the features needed for a particular application</li>
<li><strong>HTML5 Markup-driven configuration</strong> of pages and behavior for fast development and minimal required scripting.</li>
<li><strong>Progressive enhancement</strong> approach brings core content and functionality to all mobile, tablet and desktop platforms and a rich, installed application-like experience on newer mobile platforms.</li>
<li><strong>Responsive design</strong> techniques and tools allow the same underlying codebase to automatically scale from smartphone to desktop-sized screens</li>
<li><strong>Powerful Ajax-powered navigation system</strong> to enable animated page transitions while maintaining back button, bookmarking and and clean URLs though pushState. </li>
<li><strong>Accessibility</strong> features such as WAI-ARIA are also included to ensure that the pages work for screen readers (e.g. VoiceOver in iOS) and other assistive technologies.</li>
<li><strong>Touch and mouse event support</strong> streamline the process of supporting touch, mouse, and cursor focus-based user input methods with a simple API. </li>
<li><strong>Unified UI widgets</strong> for common controls enhance native controls with touch-optimized, themable controls that are platform-agnostic and easy to use.</li>
- <li><strong>Powerful theming framework</strong> and ThemeRoller application make highly-branded experiences easy to build.</li>
+ <li><strong>Powerful theming framework</strong> and the <a href="http://www.jquerymobile.com/themeroller" rel="external">ThemeRoller</a> application make highly-branded experiences easy to build.</li>
</ul>
@@ -41,7 +41,7 @@ <h3 style="display: block; font-size: 15px !important; font-weight: normal; back
<li><strong>Palm WebOS (1.4-2.0)</strong> - Tested on the Palm Pixi (1.4), Pre (1.4), Pre 2 (2.0)</li>
<li><strong>Palm WebOS 3.0 </strong> - Tested on HP TouchPad</li>
<li><strong>Firebox Mobile (Beta)</strong> - Tested on Android 2.2</li>
- <li><strong>Opera Mobile 11.0</strong>: Tested on the iPhone 3GS and 4 (5.0/6.0), Android 2.2 (5.0/6.0)</li>
+ <li><strong>Opera Mobile 11.0</strong>: Tested on Android 2.2</li>
<li><strong>Meego 1.2</strong> - Tested on Nokia 950 and N9</li>
<li><strong>Kindle 3 and Fire</strong>: Tested on the built-in WebKit browser for each</li>
<li><strong>Chrome <strong>Desktop </strong>11-15</strong> - Tested on OS X 10.6.7 and Windows 7</li>
@@ -291,6 +291,10 @@
<p>LI within a listview</p>
<table>
<tr>
+ <th>data-filtertext</th>
+ <td>string (filter by this value instead of inner text)</td>
+ </tr>
+ <tr>
<th>data-icon</th>
<td>home | delete | plus | arrow-u | arrow-d | check | gear | grid | star | custom | arrow-r | arrow-l | minus | refresh | forward | back | alert | info | search</td>
</tr>
Oops, something went wrong.

0 comments on commit 2c5de9b

Please sign in to comment.