[gnome-maps/wip/routing2: 2/5] Update: RouteService



commit 6defcb703f60c957b898d882b6be8dae1a5d6fa7
Author: Mattias Bengtsson <mattias jc bengtsson gmail com>
Date:   Wed Jun 11 01:45:14 2014 +0200

    Update: RouteService
    
     - Make fetchRoute take GeocodePlace instead of a coordinate.
     - emit 'updated' instead of 'change'
    
    Squash with:
      876117b Add RouteService module
    
    https://bugzilla.gnome.org/show_bug.cgi?id=728695

 src/routeService.js |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/routeService.js b/src/routeService.js
index 0bcb129..747c294 100644
--- a/src/routeService.js
+++ b/src/routeService.js
@@ -53,9 +53,10 @@ const GraphHopper = new Lang.Class({
         this._route   = new Route.Route();
         this._query   = new RouteQuery.RouteQuery();
 
-        this.query.connect('change', (function() {
+        this.query.connect('updated', (function() {
             if(this.query.from && this.query.to) {
-                this.fetchRoute([this.query.from, this.query.to],
+                this.fetchRoute([this.query.from.location,
+                                 this.query.to.location],
                                 this.query.transportation);
             } else
                 this.route.reset();


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