scrollview - new option - innerHeight #1345
Description
When using jQueryMobile's scrollview, instead of requiring the HTML markup to include a <div class="view">, and requiring a CSS or style declaration to get its height correct, scrollview could include another option, for example...
<div data-scroll="y" data-scroll-innerheight="500">...</div>
which could parse in scrollview.js to:
var innerHeight = $this.jqmData("scroll-innerheight");
if (innerHeight)
opts.innerHeight = innerHeight;
Then in jquery.mobile.scrollview.js, when we call a new scrollview, you could add a bit to the _create function after $child has been created, to say...
if (options.innerHeight)
$child.css('height', options.innerHeight);
It seems like the inner height would be friendlier if it could be reduced to an option, but users could go either way. Declare the "data-scroll-innerheight" to automate it, or leave it out and define your own class="view" styles.
Obviously, this could also be used for an innerWidth option.
I have been using scrollview a LOT, and I think it's great. Thanks for the amazing work.
Activity
toddparker commentedon Sep 27, 2011
Added to the feature request wiki:
https://github.com/jquery/jquery-mobile/wiki/Feature-Requests