Committing what I have.

I don't remember exactly what I've done, but thought I'd commit these
changes that has been locally for the last 6 months. Not sure if it
works.