Animation of objects on information layer

3 posts, 0 answers
  1. FieldTRAKS
    FieldTRAKS avatar
    25 posts
    Member since:
    Apr 2009

    Posted 30 Mar 2011 Link to this post

    I have just begun porting our code from our old map viewer to your control. Is there anyway to disable the weird animation that happens whenever I use the zoom controls on the map. My polygons align nicely but as soon as you zoom they fly out to the edge and then settle back to where they should be. This is really undesirable for my users. The polygons should stay aligned at all times even through a zoom. I have never encountered anything like this in a GIS viewer before.

    ...here is some sample code on how I am add the polygon


                LocationCollection points = new LocationCollection();



                points.Add(new Location(45.133, -75.7396));

                points.Add(new Location(45.1336, -75.738 ));
                points.Add(new Location(45.1338, -75.7375));
                points.Add(new Location(45.1336, -75.7373));
                points.Add(new Location(45.1321, -75.7367 ));
                points.Add(new Location(45.1315, -75.7382));
                points.Add(new Location(45.133, -75.7396));
                points.Add(new Location(45.133, -75.7396 ));
                points.Add(new Location(45.1334, -75.7355));
                points.Add(new Location(45.1333, -75.7355));
                points.Add(new Location(45.1325, -75.7358));
                points.Add(new Location(45.1349, -75.7297));
                points.Add(new Location(45.1365, -75.7308));
                points.Add(new Location(45.135, -75.7345));
                points.Add(new Location(45.1348, -75.7346));
                points.Add(new Location(45.1349, -75.7349 ));
                points.Add(new Location(45.1347, -75.7354));


                points.Add(new Location(45.1334,-75.7355 ));
                //// Inner polygon
                //points.Add(new Location(41.9, -121.9));
                //points.Add(new Location(41.9, -121.6));
                //points.Add(new Location(41.6, -121.6));
                //points.Add(new Location(41.6, -121.9));
                //points.Add(new Location(41.9, -121.9));

                MapPolygon polygon = new MapPolygon()
                {
                    Fill = new SolidColorBrush(Colors.Red),
                    Points = points
                };
                map.Items.Add(new InformationLayer());
                ((InformationLayer)map.Items[0]).Items.Add(polygon);

  2. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 01 Apr 2011 Link to this post

    Hi Matt Fraser,

    I'm sorry, but we aren't able to reproduce the problem. I've added your code to a quite simple RadMap application and all things work just fine. The polygons stay aligned. The behavior you've described looks similar to the probelm which was reported few times for the 2010.Q3 release (before SP1). But it was fixed a long time ago. Could you, please, check that you definetely use lates release (Q1 2011) of the Telerik DLLs in your project? If it is so, could you, please send small solution which we can use to reproduce the problem?

    Greetings,
    Andrey Murzov
    the Telerik team
  3. DevCraft banner
  4. FieldTRAKS
    FieldTRAKS avatar
    25 posts
    Member since:
    Apr 2009

    Posted 01 Apr 2011 Link to this post

    I actually figured it out myself....I needed to set the following property on the map viewer

    UseSpringAnimations="False"

    Then that irritating bouncing of the polygons stops.
Back to Top