Try this code.
http://jsbin.com/onidu3/5/edit
This will check all buttons in a buttonset. You could easily modify it to check only one box.
Because button basically rewrites the checkbox into a stylized label that is interacted apon by css classes you need to work with the label and the input tag instead of just the input tag.
- $this
- .addClass("ui-state-active")
- .attr("aria-pressed", "true")
- .prev().attr("checked", "true");
So here we set the right class onto the label. Change the aria-pressed attribute to true. And then set the original input element which is now hidden and semantically right before the label to checked.