Show Preview
Show Cesium Code
Show Google Earth Code
For Google Earth Developers
All Google Earth examples
Additional Resources
Tutorials
Cesium Sandcastle
Reference Documentation
Relevant Cesium Source
Relevant Google Earth Source (
link
)
google.earth.addEventListener(placemark, 'click', function(event) { var text = 'Click:'; function addToMessage(append1, append2) { text += ' ' + append1 + ': ' + append2 + '\n'; } addToMessage('target type', event.getTarget().getType()); addToMessage('currentTarget type', event.getCurrentTarget().getType()); addToMessage('button', event.getButton()); addToMessage('clientX', event.getClientX()); addToMessage('clientY', event.getClientY()); addToMessage('screenX', event.getScreenX()); addToMessage('screenY', event.getScreenY()); addToMessage('latitude', event.getLatitude()); addToMessage('longitude', event.getLongitude()); addToMessage('altitude', event.getAltitude()); addToMessage('didHitGlobe', event.getDidHitGlobe()); addToMessage('altKey', event.getAltKey()); addToMessage('ctrlKey', event.getCtrlKey()); addToMessage('shiftKey', event.getShiftKey()); addToMessage('timeStamp', event.getTimeStamp()); // Prevent default balloon from popping up for marker placemarks event.preventDefault(); // wrap alerts in API callbacks and event handlers // in a setTimeout to prevent deadlock in some browsers setTimeout(function() { alert(text); }, 0); });