Implemented keyboard support on OSX.

OSX version now has feature parity with Windows.