summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcus Lundblad <ml@dfupdate.se>2022-09-02 22:48:44 +0200
committerMarcus Lundblad <ml@dfupdate.se>2022-09-02 22:48:44 +0200
commit66daec2ada08924687afe9e022125ed4b68eb31e (patch)
treebbd9eab9c5d5fd0638ca7cc1319c215f4f12ba52
parent20c6a6a4bb599bfa123e07ab58e9f54ddeb34ea6 (diff)
downloadgnome-maps-wip/mlundblad/dont-delete-map-bubbles.tar.gz
mapMarker: Don't delete bubble reference when closing bubblewip/mlundblad/dont-delete-map-bubbles
This causes the bubble to be recreated. The old instance is still alive as it's parented by the map view.
-rw-r--r--src/mapMarker.js25
1 files changed, 0 insertions, 25 deletions
diff --git a/src/mapMarker.js b/src/mapMarker.js
index ecc7644d..91cd5688 100644
--- a/src/mapMarker.js
+++ b/src/mapMarker.js
@@ -217,35 +217,10 @@ export class MapMarker extends Shumate.Marker {
let goingToSignalId = this._mapView.connect('going-to', () => {
this.set_selected(false);
});
- /*
- let buttonPressSignalId =
- this._view.connect('button-press-event', () => {
- this.set_selected(false);
- });
- // Destroy the bubble when the marker is destroyed o removed from a layer
- let parentSetSignalId = this.connect('parent-set', () => {
- this.set_selected(false);
- });
- let dragMotionSignalId = this.connect('drag-motion', () => {
- this.set_selected(false);
- });
- let markerHiddenSignalId = this.connect('notify::visible', () => {
- if (!this.visible) {
- this.set_selected(false);
- }
- });
- */
Utils.once(this.bubble, 'closed', () => {
this._mapView.disconnect(markerSelectedSignalId);
this._mapView.disconnect(goingToSignalId);
- //this._view.disconnect(buttonPressSignalId);
- //this._view.disconnect(viewTouchEventSignalId);
- //this.disconnect(parentSetSignalId);
- //this.disconnect(dragMotionSignalId);
-
- //this._bubble.destroy();
- delete this._bubble;
});
}