ActiveRecord integrations now using transactions respecting "use_transactions" config

Right now state_machine is somewhat abandoned it seems like, given the fact that it is last updated May 2013.

The bug: https://github.com/pluginaweek/state_machine/issues/264
The fix: https://github.com/pluginaweek/state_machine/issues/255 (included here).

@camilo, @jnormore for review?

(Sorry for the mail spam, created a PR against the wrong base repository in the beginning)