Fixed various compiler warnings.

Some of them have to do with type safety. I've had cases now where the difference between the double and floating point windows are actually visible...