Events don't need to be in a unique_ptr
Fix java CMakeLists
Refactor JTox cpp code