Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

red cross shows on the previous location until create a new elevation profile #9

Open
chen7012 opened this issue Aug 7, 2015 · 1 comment

Comments

@chen7012
Copy link

chen7012 commented Aug 7, 2015

Steps to reproduce:
1.click on the measure button
2.click one point, and double click on the map to set the end point for the measure.
3. waiting for the elevation profile to be created, then hover on the profile.
4, the red cross will show on the map.
5. single click on the map again to start the new measure, but the red cross is still showing on the previous location.

Is there a way to clear it?

@hli123
Copy link

hli123 commented Aug 14, 2015

I resolved the issue by adding a handler for "measure-stat" event. Here is the detail:

  1. added the line of code to _initMeasureTool: function () in Widget.js in the templete:

        this.onMeasureStart=this.measureTool.on("measure-start", lang.hitch(this, this._onMeasureStart));
    
  2. added the function _onMeasureStart in Wedget.js:

_onMeasureStart: function () {
this._displayChartLocation(-1);
},

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants