since updated mapviewer from version Ver22.214.171.124_B121012 to Ver126.96.36.199.1_B130812 I have a problem dragging FOIs. I still use oraclemaps v1 api.
This is the way I used to accomplish the FOI dragging:
That workflow works fine since updating mapviewer. What fails in the new release is the dragging mentioned in step 4). When the user tries to drag the foi the mouse cursor changes to “not-allowed” style and the foi is not moved. But when the user releases the mouse button the foi can be moved around the map since the user clicks into the map once again.
I realized a couple of changes in oraclemaps.js in the code responsible for the mouse drag behaviour. Now I’m wondering if there is a bug or whether the upper way isn’t appropriate to accomplish the requirement. Does anybody have instructions how to realize dragging of MVFOI objects?
There is no MOUSE_UP event with our FOI object. After you register your MOUSE_DOWN with your FOI that has been added to the map, you may refer to the below sample code to make your FOI draggable on the map, the below code can also be run with IE9.
var mouseLoc = mapview.getMouseLocation();
thanks for reply!
Yes, your solution works. In fact my implementation is like the way you are describing it. I just
mixed up the registration target of the MOUSE_UP listener in my upper workflow description. I've build a small sample where the foi dragging works in IE9. I think there are some kind of site effects in my more complex application causing this faulty behavior. I will try to reproduce the error in that sample page...
For the sake of completeness:
I finally found what was causing the error: In the HTML-<head> section there was an meta-tag like this:
<meta http-equiv="X-UA-Compatible" content="IE=8; charset=utf-8;" />
I change it to
<meta http-equiv="X-UA-Compatible" content="IE=9; charset=utf-8;" />
I've no idea why but that does the trick.