public MapControl() { InitializeComponent(); Loaded += new RoutedEventHandler(MapControl_Loaded); this.SizeChanged += new SizeChangedEventHandler(MapControl_SizeChanged); MouseMove += new MouseEventHandler(MapControl_MouseMove); MarkerSymbol.mapControl = this; cstInsideRequestIdentify = "mapcontrol_" + Guid.NewGuid(); MapToolFactory.Init(this); }
private void SetMapToolByCurrentType() { IMapCommand cmd = MapToolFactory.GetMapTool(_currentToolType); if (!(cmd is IMapTool)) { return; } if (_currentMapTool != null) { (_currentMapTool as IMapToolInternal).Deactive(); } _currentMapTool = cmd as IMapTool; if (_currentMapTool == null) { _currentToolType = enumMapTools.None; } else { (_currentMapTool as IMapToolInternal).Active(); } }
public IMapCommand FindSystemMapTool(enumMapTools maptooltype) { return(MapToolFactory.GetMapTool(maptooltype)); }