Clicking format buttons loses selection in non-IE

At some point along the way (before 1.0.0b6), we broke selection restoration after changing the node type via selection. If you change a paragraph into a header, your selection goes poof and you have to click back in to the header. We shouldn't make people do that.
`data-*` attributes are the more correct markers for this but we already have code for classes so for 1.0 it is well enough.