public MeasureDistance(Map map, ElementsLayer elementsLayer, FeaturesLayer featuresLayer) { _map = map; _eLayer = elementsLayer; _fLayer = featuresLayer; _isInited = false; _distanceList = new List<TextBlock>(); _points = new Point2DCollection(); _distances = new List<double>(); }
public MeasureDistance(Map map, ElementsLayer elementsLayer, FeaturesLayer featuresLayer, bool isMeasure) { _map = map; _eLayer = elementsLayer; _fLayer = featuresLayer; _isInited = false; _distanceList = new List<Border>(); _points = new Point2DCollection(); _distances = new List<double>(); _isMeasure = isMeasure; }
public void InitializeComponent() { if (_contentLoaded) { return; } _contentLoaded = true; System.Windows.Application.LoadComponent(this, new System.Uri("/GettingStartedWP;component/MainPage.xaml", System.UriKind.Relative)); this.LayoutRoot = ((System.Windows.Controls.Grid)(this.FindName("LayoutRoot"))); this.TitlePanel = ((System.Windows.Controls.StackPanel)(this.FindName("TitlePanel"))); this.ContentPanel = ((System.Windows.Controls.Grid)(this.FindName("ContentPanel"))); this.MyMap = ((SuperMap.WindowsPhone.Mapping.Map)(this.FindName("MyMap"))); this.ZoomIn = ((System.Windows.Controls.Button)(this.FindName("ZoomIn"))); this.ZoomOut = ((System.Windows.Controls.Button)(this.FindName("ZoomOut"))); }
/// <summary>${ui_action_DrawLine_constructor_Map_D}</summary> /// <example> /// <code lang="CS"> /// DrawLine draw = new DrawLine(MyMap,Cursors.Stylus) /// </code> /// </example> /// <param name="map">${ui_action_DrawLine_constructor_Map_param_map}</param> public DrawLine(Map map) : base(map, "DrawLine") { if (map.Theme == null) { Stroke = new SolidColorBrush(Colors.Red); StrokeThickness = MagicNumber.ACTION_STYLE_DEFAULT_STROKETHICKNESS; Opacity = MagicNumber.ACTION_STYLE_DEFAULT_OPACITY; } else { this.Stroke = map.Theme.Stroke; this.StrokeThickness = map.Theme.StrokeThickness; this.Opacity = map.Theme.Opacity; } }
/// <summary>${ui_action_DrawRect_constructor_Map_D}</summary> /// <example> /// <code lang="CS"> /// DrawRectangle draw = new DrawRectangle(MyMap,Cursors.Stylus) /// </code> /// </example> /// <param name="map">${ui_action_DrawRect_constructor_Map_param_map}</param> public DrawRectangle(Map map ) : base(map , "DrawRectangle") { startPt = Point2D.Empty; if (map.Theme == null) { Stroke = new SolidColorBrush(Colors.Green); StrokeThickness = MagicNumber.ACTION_STYLE_DEFAULT_STROKETHICKNESS; Fill = new SolidColorBrush(Colors.Black); Opacity = MagicNumber.ACTION_STYLE_DEFAULT_OPACITY; } else { this.Stroke = map.Theme.Stroke; this.StrokeThickness = map.Theme.StrokeThickness; this.Fill = map.Theme.Fill; this.Opacity = map.Theme.Opacity; } }
/// <summary>${ui_action_Edit_constructor_D}</summary> /// <param name="map">${ui_action_Edit_constructor_param_map}</param> /// <param name="layer">${ui_action_Edit_constructor_param_layer}</param> public Edit(Map map , FeaturesLayer layer) { if (map != null && layer != null) { Name = "Edit"; Map = map; editLayer = layer; editLayer.MouseLeftButtonDown += editLayer_MouseLeftButtonDown; editLayer.MouseLeftButtonUp += editLayer_MouseLeftButtonUp; if (map.Theme == null) { SetDefaultStyle(); } else { HoverVertexStyle = map.Theme.HoverVertexStyle; SnapStyle = map.Theme.SnapStyle; HoverCenterStyle = map.Theme.HoverCenterStyle; hoverLineStyle = new PredefinedLineStyle() { Stroke = new SolidColorBrush(Colors.Transparent) , StrokeThickness = 10 };//Colors.Transparent } } }
public DrawPoint(Map map, ElementsLayer layer) { _map = map; _eLayer = layer; _pushpins = new List<Pushpin>(); }
/// <summary>${ui_action_Pan_constructor_Map_D}</summary> /// <example> /// <code lang="CS"> /// Pan panTo = new Pan(MyMap,Cursors.Hand) /// </code> /// </example> /// <param name="map">${ui_action_Pan_constructor_Map_param_map}</param> public Pan(Map map) : base(map, "Pan") { }
/// <summary>${ui_action_ZoomOut_constructor_Map_D}</summary> /// <example> /// <code lang="CS"> /// ZoomOut zoomMap = new ZoomOut(MyMap,Cursors.Arrow) /// </code> /// </example> /// <param name="map">${ui_action_ZoomOut_constructor_Map_param_map}</param> public ZoomOut(Map map) : base(map) { }
/// <summary>${ui_action_ZoomIn_constructor_Map_D}</summary> /// <example> /// <code lang="CS"> /// ZoomIn zoomInMap = new ZoomIn(MyMap,Cursors.Arrow) /// </code> /// </example> /// <overloads>${ui_action_ZoomIn_constructor_overloads}</overloads> /// <param name="map">${ui_action_ZoomIn_constructor_Map_param_map}</param> public ZoomIn(Map map) : base(map) { }
/// <summary>${ui_action_DrawPoint_constructor_Map_D}</summary> /// <example> /// <code lang="CS"> /// DrawPoint draw = new DrawPoint(MyMap,Cursors.Stylus) /// </code> /// </example> /// <param name="map">${ui_action_DrawPoint_constructor_Map_param_map}</param> public DrawPoint(Map map ) : base(map , "DrawPoint") { }
public DrawRectangle(Map map,ElementsLayer layer ) { }
/// <summary>${ui_action_MapAction_constructor_Map_D}</summary> /// <param name="map">${ui_action_MapAction_constructor_Map_param_map}</param> /// <param name="name">${ui_action_MapAction_constructor_Map_param_name}</param> protected MapAction(Map map, string name) { Name = name; Map = map; Map.Focus(); }