Implement osx driver and fix ui.