Hi, I have a problem with a jqm app, it seems a jqm bug with Google Chrome. I've made a concept proof with just a bit of code here:
As you can see, at the pageinit event, it just declares a sample object "foo" and instances it, after that, it redirects to a dialog page "#page2"
The problem is that, though the code redirects to #page2, it finally ends at #page1.
There are three "solutions" by now:
1. wrap the changePage in a setTimeout function ( really ugly )
2. not instanciate the class!
If I comment this code:
$foo=new foo();
$foo.name="bar";
the app ends in #page2. Correct, but of course, in the real app I need my class.
3. redirect to a normal page instead of a dialog
If I change:
$.mobile.changePage("#page2",{role:'dialog'] )
by
$.mobile.changePage("#page2")
it works
So, my best option by now is the third one, but it would involve to me a css small nightmare which I'd like to avoid.
Can anyone tell me why this weird behaviour? Seems a jqm bug to me.
Thanks in advance, Diego.