I think this is a current problem with the new 1.3.0 version.
E.g.: in my case, I have a data-role="button" to change its theme when a event happens.
What do I do?
----------------------
var state = 1;
var theme = 'c', themeOnProfile = 'e';
var oState = state ? theme : themeOnProfile,
nState = state ? themeOnProfile : theme,
cssRemove = 'ui-btn-hover-' + oState + ' ui-btn-up-' + oState,
cssAdd = 'ui-btn-hover-' + nState + ' ui-btn-up-' + nState;
$t.removeClass( cssRemove ).addClass( cssAdd ).attr('data-theme', nState ).buttonMarkup('refresh');
----------------------------
My original theme is 'c', when the even happens I want to be 'e'.
Besides the buttonMarkup('refresh'), I remove the older theme classes and add the newer theme ones.
In that way, I get the effect that I actually want.
Hope this is useful for you.
As far as I can tell, this is an error since the classes should removed/added automatically by the widget. What do you think?
Regards