New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
jqmData("iscrollview") always null in jQm 1.3.0 #76
Comments
This is indeed a bit broken due to changes made in jQuery and jQuery Mobile. But there is a (bit off a) workaround: With this code I managed to get a simmiliar result with the old jqmData( "iscrollview" ) iscroll_view_obj = $( 'iscroll_view_target' ).iscrollview();
if( iscroll_view_obj[0] != undefined )
scrollObject = $( iscroll_view_obj[0] ).data( "mobileIscrollview" ); It doesnt really feel like a good sollution, but it works for me for now. |
I don't understand what |
Confirmed. I'll update the documentation. Nothing I can do about this in the widget, since the way JQM uses the Widget Factory has changed. I think you meant:
above, where If you want to write application code that will work with either JQM 1.3 or <1.3, you could do this: $scrollElement = $(iscroll_view_obj[0]);
scrollObject = $scrollElement.data("mobileIscrollview") || $scrollElement.jqmData("iscrollview"); Note that jqmData doesn't work to retrieve this with JQM 1.3. So, it is a change both in the naming convention and in the method used to access. |
With 'iscroll_view_target' I ment the element where the iscroll_view plugin was created on. So yeah that could be a class or an id or anything. (Sorry for the kinda slow response, not getting this in my email for some reason :) ) |
using jQm 1.2.0 is working fine, but when i tried to switch to jQm 1.3.0, encountering this issue with jqmData("iscrollview"), it is always returning null, already upgraded from 1.2.5 to 1.2.6 of this plugin, issue still persist. I think it has to update to work with jQm1.3.0 regarding this matter.
The text was updated successfully, but these errors were encountered: