[gnome-maps] mapBubble: Don't hard-code to non-transit mode



commit 10f69ecf592ae4e6db61ff4be62788f58dff6284
Author: Marcus Lundblad <ml update uu se>
Date:   Tue Jun 20 22:01:16 2017 +0200

    mapBubble: Don't hard-code to non-transit mode
    
    Setting non-transit here unconditionally results in a inconsitent
    state when the mode is set to transit.
    Also reset the appropriate object depending on routing mode.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=784013

 src/mapBubble.js |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)
---
diff --git a/src/mapBubble.js b/src/mapBubble.js
index 6dc6d0b..ea8cada 100644
--- a/src/mapBubble.js
+++ b/src/mapBubble.js
@@ -151,17 +151,15 @@ const MapBubble = new Lang.Class({
 
     _initRouteButton: function(button, routeFrom) {
         let query = Application.routeQuery;
-        let route = Application.routingDelegator.graphHopper.route;
         let from = query.points[0];
         let to = query.points[query.points.length - 1];
 
         button.visible = true;
 
         button.connect('clicked', (function() {
-            Application.routingDelegator.useTransit = false;
             query.freeze_notify();
             query.reset();
-            route.reset();
+            Application.routingDelegator.reset();
             if (routeFrom) {
                 from.place = this._place;
             } else {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]