Customer Service | Training | Contact Us
You are here: Home > User Forums > arcgis server forums > Thread Replies

ArcGIS Server Forums

ArcGIS API for JavaScript forum

polyline drawing change in JSAPI 1.5?   xiaoming qin Oct 09, 2009
Re: polyline drawing change in JSAPI 1.5?   Trent Tinker Oct 21, 2009
Re: polyline drawing change in JSAPI 1.5?   xiaoming qin Oct 22, 2009
Re: polyline drawing change in JSAPI 1.5?   Trent Tinker Nov 12, 2009
Report Inappropriate Content • Top • Print • Reply    
Subject polyline drawing change in JSAPI 1.5? 
Author xiaoming qin 
Date Oct 09, 2009 
Message Hi All,

In 1.4, the way to draw a polyline is 1)click on map 2)drag your mouse to next point and click 3)double-click at final point. When I change the reference to 1.5, the behavior seems to change to: 1)click on map 2) drag mouse to next point and click 3)click at final point first and then double-click

If I just double-click on the final point, the last segment of the polyline would be gone. It still kind of works, but causes quiet a bit confusing for the users.

I suspect it's more of an issue of DOJO 1.3.2, since I can't duplicate the behavior using ESRI's sample. Does anyone have this problem and have a clue?

thanks
xiaoming 
  Prince William County
xqin@pwcgov.org 
   
Report Inappropriate Content • Top • Print • Reply    
Subject Re: polyline drawing change in JSAPI 1.5? 
Author Trent Tinker 
Date Oct 21, 2009 
Message We have this same problem in one of our sites. There is a tool that selects features by a line. The last segment of the line is not included at v1.5. Consequently, we had to revert our site back to v1.4.

Keep me posted if you find a solution, and I'll do the same. 
  Trent Tinker
 
   
Report Inappropriate Content • Top • Print • Reply    
Subject Re: polyline drawing change in JSAPI 1.5? 
Author xiaoming qin 
Date Oct 22, 2009 
Message I have a workaround, although I don't know the deeper reason causing the problem.

In our case, we have multiple drawing toolbars present and we need to active/deactive those toolbars depending which one is selected.

The described behavior occurs when I do:
drawToolbar1.activate(esri.toolbars.Draw.POLYLINE);
drawToolbar2.deactivate();

It's gone if I reverse the order:
drawToolbar2.deactivate();
drawToolbar1.activate(esri.toolbars.Draw.POLYLINE);

Hope this helps.
xiaoming


 
  Prince William County
xqin@pwcgov.org 
   
Report Inappropriate Content • Top • Print • Reply    
Subject Re: polyline drawing change in JSAPI 1.5? 
Author Trent Tinker 
Date Nov 12, 2009 
Message Thanks xiaoming. Your work around did the trick.

Screen grabs of this issue can be seen here:
http://www.roktech.net/devblog/index.cfm/2009/11/12/ArcGIS-Server-JavaScript-API-version-15--Bug-with-Drawing-Toolbar-deactivation

 
  Trent Tinker