POST
|
No I haven't tried it yet in my app, but the ArcGIS for JS sandbox mentioned in the earlier post is using 3.14, and I observed the same double-click issue where the graphic is undefined.
... View more
07-28-2015
04:58 PM
|
0
|
0
|
648
|
POST
|
No, my application does not run under any compatibility mode (on purpose). However, that ArcGIS for JS sandbox apparently does. When in the sandbox, it says it is in IE 9 mode when I initially open developer tools (F12). The double-click event for a graphic works as expected as you observed. However when I switch the mode to Edge or 10, e.graphic is undefined.
... View more
07-28-2015
04:57 PM
|
0
|
0
|
648
|
POST
|
I am using ArcGIS for JavaScript v. 3.13. I am having two issues with click events in Internet Explorer 10 and 11 only (works great in Chrome). The first issue is that on the "dbl-click" event, e.graphic is always undefined when I click a graphic. However on the "mouse-down" event, e.graphic is present as expected. I define the events in normal dojo style: map.on("dbl-down", function (e) {
//e.graphic === undefined when graphic is clicked
});
map.on("mouse-down", function (e) {
//e.graphic !== undefined when graphic is clicked
}); The second issue is that click events like "dbl-click" and "mouse-down" cease to fire for the polygon currently being edited after I have switched the edit mode from EDIT_VERTICES to MOVE. The events do fire for other parts of the map or other graphics. My goal is to toggle between edit modes by double-clicking the graphic being edited. This works beautifully in Chrome. Here is my code: //Fires first time, does not fire for same graphic after edit mode is changed
map.on("dbl-click", function (e) {
if (editingEnabled) {
var state = editToolBar.getCurrentState();
var editingGraphic = state.graphic;
if (editingGraphic != null) {
if (editingGraphic.geometry.type === "polygon"
&& editingGraphic.geometry.contains(e.mapPoint)) {
if (state.tool == Edit.EDIT_VERTICES) {
editToolBar.activate(Edit.MOVE, editingGraphic);
} else if (state.tool == Edit.MOVE) {
editToolBar.activate(Edit.EDIT_VERTICES, editingGraphic);
}
}
}
}
});
//Don't zoom if double-clicking a graphic while editing
map.on("mouse-down", function (e) {
if (e.graphic !== undefined && editingEnabled) {
map.disableDoubleClickZoom();
} else {
map.enableDoubleClickZoom();
}
}); I would like to know if I am overlooking something or this is a bug with ArcGIS for JavaScript. I only noticed the issues in IE 10 and 11.
... View more
07-28-2015
07:56 AM
|
0
|
5
|
4634
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:25 AM
|