Change ControlState typedef to double, and change all related floats/doubles to use it.

Fixes an off by 1 issue related to double->float->double conversion, and eliminates numerous warnings.
Merge pull request #781 from RachelBryk/ControlState

Change ControlState typedef to double, and change all related floats/dou...