jquery/jquery-mobile — Issue #3213: Link Buttons don't retheme when theme changed during click - missing refresh()?
Author: middenview
Created: 2011-12-03 17:21:25+00:00
State: open

Refresh isn't supported for link buttons.

Using the .buttonMarkup() for themes and/or icons results in a button with an increasing number of icons and an increasing size.

Needed a workaround like this to get rid of extra classes.

$("#PlotMenu-Cars [data-role='button']").bind("click", function(event)
{
var e = event.currentTarget;
$(this).removeClass("ui-btn-up-b");
$(this).removeClass("ui-btn-up-e");
$(this).removeClass("ui-btn-hover-b");
$(this).removeClass("ui-btn-hover-e");
$(this).attr("data-theme", filter ? "e" : "b");

});