As the title states, on a given event (for me this happens to be upon opening a new google.maps.InfoWindow
I want to be able to close any other currently open info
I ran into the same problem and fixed it by creating a global info window.
var infowindow = new google.maps.InfoWindow();
Then I have a function to do the following on the click listener:
function getInfoWindowEvent(marker) {
infowindow.close()
infowindow.setContent("This is where my HTML content goes.");
infowindow.open(map, marker);
}
This achieves what I think you're looking for b/c there is now only one info window on the map and I just close it, reload the content and open it again for the given marker.