moved touchOverflowEnabled setting to global config, class is applied through page plugin. False by default. No longer dependent on fixed headers and footers.

This commit is contained in:
scottjehl 2011-12-26 16:30:00 +07:00
parent a00c05109b
commit f779416c8d
2 changed files with 8 additions and 0 deletions

View file

@ -37,6 +37,9 @@
// Minimum scroll distance that will be remembered when returning to a page
minScrollBack: 250,
// Enable touch-overflow scrolling for better transitions, in supporting browsers
touchOverflowEnabled: false,
// Set default dialog transition - 'none' for no transitions
defaultDialogTransition: "pop",

View file

@ -18,6 +18,11 @@ $.widget( "mobile.page", $.mobile.widget, {
this.element
.attr( "tabindex", "0" )
.addClass( "ui-page ui-body-" + this.options.theme );
// if touchOverflow scrolling is enabled, add class
if( $.support.touchOverflow && $.mobile.touchOverflowEnabled ){
this.element.addClass( "ui-mobile-touch-overflow" );
}
},
keepNativeSelector: function() {