1
0
Fork 0
mirror of https://github.com/iNavFlight/inav-configurator.git synced 2025-07-23 16:25:19 +03:00

Make the attribution link in Missions tab open an external window

Otherwise it overrides the viewport of the configurator. The GPS
tab doesn't have this problem because it uses an intermediate
iframe to host the map.

Fixes #540
This commit is contained in:
Alberto García Hierro 2018-07-13 11:08:14 +01:00
parent 16c935bbe2
commit aa47f3eba2

View file

@ -339,6 +339,17 @@ TABS.mission_control.initialize = function (callback) {
})
});
// Set the attribute link to open on an external browser window, so
// it doesn't interfere with the configurator.
var interval;
interval = setInterval(function() {
var anchor = $('.ol-attribution a');
if (anchor.length) {
anchor.attr('target', '_blank');
clearInterval(interval);
}
}, 100);
map.on('click', function (evt) {
if (selectedMarker != null) {
try {