Dynamic page theme swatch don't work properly
Hello,
first of all I apologize for my bad english.
I'm trying to dinamically change the page theme with the function found in the jquery mobile API documentation.
The function is like that:
$('[data-role="page"]).page( 'option', 'theme', 'b' );
If i run this function several times with different swatch themes, it add the page css class theme for each swatch instead of switch it.
Example:
I load the page with default theme.
It add in the page class:
Then i execute:
- $('[data-role="page"]).page( 'option', 'theme', 'b' );
It add:
Then i execute:
- $('[data-role="page"]).page( 'option', 'theme', 'a' );
I don't know if this is the normal behavior (or happen only in my case) so I ask for clarification on this and in case this is the normal use, how to "emulate" a switch behavior ( JQuery mobile 1.4.5)
thanks