Fix hover message drill icon
This commit is contained in:
@@ -107,18 +107,24 @@
|
|||||||
this.hash.items = [this.project.currProject.codename, this.options.type, this.options.id];
|
this.hash.items = [this.project.currProject.codename, this.options.type, this.options.id];
|
||||||
|
|
||||||
return this.map.panToBetweenPanels(this.relatedMarkerLatLng, this.focusZoomLevel, iAnimDuration).then(() => {
|
return this.map.panToBetweenPanels(this.relatedMarkerLatLng, this.focusZoomLevel, iAnimDuration).then(() => {
|
||||||
this.openMarkerPopup(false);
|
this.openMarkerPopup();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
openMarkerPopup(bMouseEvent=true) {
|
onMouseEnter() {
|
||||||
|
this.mouseOverDrill = true;
|
||||||
|
this.openMarkerPopup();
|
||||||
|
},
|
||||||
|
onMouseLeave() {
|
||||||
|
this.mouseOverDrill = false;
|
||||||
|
this.closeMarkerPopup();
|
||||||
|
},
|
||||||
|
openMarkerPopup() {
|
||||||
const oRelatedMarker = this.relatedMarker;
|
const oRelatedMarker = this.relatedMarker;
|
||||||
this.mouseOverDrill = bMouseEvent;
|
|
||||||
if(oRelatedMarker && this.map.isMarkerVisible(this.relatedMarkerLatLng)) {
|
if(oRelatedMarker && this.map.isMarkerVisible(this.relatedMarkerLatLng)) {
|
||||||
this.map.openMarkerPopup(oRelatedMarker.id, oRelatedMarker.type);
|
this.map.openMarkerPopup(oRelatedMarker.id, oRelatedMarker.type);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
closeMarkerPopup() {
|
closeMarkerPopup() {
|
||||||
this.mouseOverDrill = false;
|
|
||||||
if(!this.popupRequested) this.map.closePopup();
|
if(!this.popupRequested) this.map.closePopup();
|
||||||
this.popupRequested = false;
|
this.popupRequested = false;
|
||||||
},
|
},
|
||||||
@@ -146,10 +152,10 @@
|
|||||||
executeMainAction() {
|
executeMainAction() {
|
||||||
switch(this.options.type) {
|
switch(this.options.type) {
|
||||||
case 'message':
|
case 'message':
|
||||||
return this.openMarkerPopup(false);
|
return this.openMarkerPopup();
|
||||||
case 'media':
|
case 'media':
|
||||||
this.$refs.medialink.openMedia();
|
this.$refs.medialink.openMedia();
|
||||||
if(this.relatedMarker) return this.openMarkerPopup(false);
|
if(this.relatedMarker) return this.openMarkerPopup();
|
||||||
default:
|
default:
|
||||||
return Promise.resolve();
|
return Promise.resolve();
|
||||||
}
|
}
|
||||||
@@ -180,7 +186,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="body">
|
<div class="body">
|
||||||
<div v-if="options.type == 'message'" class="body-box">
|
<div v-if="options.type == 'message'" class="body-box">
|
||||||
<div class="drill" @click.prevent="panMapToMarker" @mouseenter="openMarkerPopup" @mouseleave="closeMarkerPopup">
|
<div class="drill" @click.prevent="panMapToMarker" @mouseenter="onMouseEnter" @mouseleave="onMouseLeave">
|
||||||
<span v-if="options.weather_icon && options.weather_icon!='unknown'" class="weather clickable" :title="lang.get('weather.'+options.weather_icon)">
|
<span v-if="options.weather_icon && options.weather_icon!='unknown'" class="weather clickable" :title="lang.get('weather.'+options.weather_icon)">
|
||||||
<spotIcon :icon="options.weather_icon" :text="Math.round(options.weather_temp)+'°C'" text-classes="temperature" />
|
<spotIcon :icon="options.weather_icon" :text="Math.round(options.weather_temp)+'°C'" text-classes="temperature" />
|
||||||
</span>
|
</span>
|
||||||
|
|||||||
Reference in New Issue
Block a user