-1

I have a Fusion Table layer on my map. I want to make it so that when I click on the Fusion Table layer, this script fires.

My code so far:

gmap = new google.maps.Map(document.getElementById("map-canvas"));
google.maps.event.addListener(gmap,'click',function(e){
  console.log(e);
}); // DONE: google.maps.event.addListener

When I click a part of the map that has no Fusion Table layer on it, the script fires. But if I click a part of the Fusion Table layer, it doesn't.

What do I do?

Generic_User_ID
  • 1,067
  • 2
  • 13
  • 16

1 Answers1

0

You must either set the clickable-option of the FusionTablesLayer to false or also observe the click-event of the FusionTablesLayer

Dr.Molle
  • 116,463
  • 16
  • 195
  • 201