Fix marker popup onopen binding
Fixing problems with marker binding/compilation
Cleaning up code