Exemplo n.º 1
0
        public void DeselectAll()
        {
            SelectedPoint = new GISMapPoint();
            GISMapPoint Dummy = new GISMapPoint();

            UpdateColors(Dummy.pointrect);
        }
Exemplo n.º 2
0
 //used for plotting the points for drawing a polygon.
 public void AddPoint(Location MapPointLocation)
 {
     if (AddPolyPoint)
     {
         GISMapPoint GMPoint = new GISMapPoint();
         GMPoint.PointLocation = MapPointLocation;
         surfacewindow.MainMap.PointLayer.AddChild(GMPoint.pointrect, MapPointLocation);
         MapPoints.Add(GMPoint);
         GMPoint.pointrect.TouchDown += new EventHandler <TouchEventArgs>(Point_TouchDown);
     }
 }
Exemplo n.º 3
0
        public void Point_TouchMove(Location MapPointLocation)
        {
            surfacewindow.MainMap.PointLayer.Children.Remove(SelectedPoint.pointrect);
            GISMapPoint NewPoint = new GISMapPoint();

            NewPoint.PointLocation = MapPointLocation;
            MapPoints.RemoveAt(PointIndex);
            MapPoints.Insert(PointIndex, NewPoint);
            PointSelected = false;
            surfacewindow.MapPolygon.RemovePolygon();
            surfacewindow.MapPolygon.AddPolygon();
        }
Exemplo n.º 4
0
 public void UpdateColors(Rectangle pointrect)
 {
     for (int i = 0; i < MapPoints.Count; i++)
     {
         GISMapPoint test = MapPoints[i] as GISMapPoint;
         if (pointrect.Equals(test.pointrect) && pointrect != null)
         {
             test.pointrect.Stroke = new SolidColorBrush(Colors.Wheat);
             test.pointrect.Fill   = new SolidColorBrush(Colors.Blue);
         }
         else // not the selected polygon... reset it's color
         {
             test.pointrect.Stroke = new SolidColorBrush(Colors.Gold);
             test.pointrect.Fill   = new SolidColorBrush(Colors.Maroon);
         }
     }
 }
Exemplo n.º 5
0
 public void DeselectAll()
 {
     SelectedPoint = new GISMapPoint();
     GISMapPoint Dummy = new GISMapPoint();
     UpdateColors(Dummy.pointrect);
 }
Exemplo n.º 6
0
 //used for plotting the points for drawing a polygon.
 public void AddPoint(Location MapPointLocation)
 {
     if (AddPolyPoint)
     {
         GISMapPoint GMPoint = new GISMapPoint();
         GMPoint.PointLocation = MapPointLocation;
         surfacewindow.MainMap.PointLayer.AddChild(GMPoint.pointrect, MapPointLocation);
         MapPoints.Add(GMPoint);
         GMPoint.pointrect.TouchDown += new EventHandler<TouchEventArgs>(Point_TouchDown);
     }
 }
Exemplo n.º 7
0
 public void Point_TouchMove(Location MapPointLocation)
 {
     surfacewindow.MainMap.PointLayer.Children.Remove(SelectedPoint.pointrect);
     GISMapPoint NewPoint = new GISMapPoint();
     NewPoint.PointLocation = MapPointLocation;
     MapPoints.RemoveAt(PointIndex);
     MapPoints.Insert(PointIndex, NewPoint);
     PointSelected = false;
     surfacewindow.MapPolygon.RemovePolygon();
     surfacewindow.MapPolygon.AddPolygon();
 }