added prefernce to show notifications on OSX client, fixed connect-disconnect forever bug, changed api a bit to allows disconnect() and connect()