Select to view content in your preferred language

Turning navigation off

1048
4
04-26-2011 08:46 AM
DeonaEvans
Emerging Contributor
I'm using the Flex Viewer and I want to be able to turn off navigation.  Right now it seems to default to be in Pan mode.  I don't want it to be in any mode.  I would like the cursor to change to just an arrow and you be able to click on some things on the map but not be in pan mode.
Tags (2)
0 Kudos
4 Replies
RobertScheitlin__GISP
MVP Emeritus
Deona,

    The Viewer defaults to Pan... In the MapManager.mxml you would have to remove the default of the switch in the changeNavigation function, for one. Also call
navTool.deactivate();
And possibly more...

p.s. Please post viewer questions to the viewer forum.

http://forums.arcgis.com/forums/111-ArcGIS-Viewer-for-Flex
0 Kudos
DeonaEvans
Emerging Contributor
I've tried that and "Pan" is still active.  I think this has to do with com.esri.ags.Tools.NavigationTool and that it may have a default of "Pan" no matter what.  When you look at the deactivate function it says "Deactivates the tool and reactivates default map navigation behavior."  Does anyone know what this "default map navigation behavior" is?  I've got a suspicion that it is "pan."  How do I put the map into a "no pan" type mode?
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Deona,

   I guess you will have to take it a step further than.

map.panEnabled = false;
   map.mapNavigationEnabled = false;
   map.rubberbandZoomEnabled = false;
0 Kudos
DeonaEvans
Emerging Contributor
Toggling panEnabled did the trick for me.  Thanks!
0 Kudos