I have a Bing Map control and I want to animate the location of the output drawn on the map.
Ideally, I would like to write code like this:
var sb = new Storyboard();
var duration = DurationHelper.FromTimeSpan(System.TimeSpan.FromMilliseconds(1000));
sb.Duration = duration;
LocationAnimation ani = new LocationAnimation();
ani.To = new Location(33.3, 11.1);
ani.Duration = duration;
sb.Children.Add(ani);
Storyboard.SetTarget(ani, myPin);
Storyboard.SetTargetProperty(ani, "MapLayer.Position");
Resources.Add("moveMyPin", sb);
sb.Begin();
Of course, there is no class in the structure LocationAnimation. There are a couple of similar ones: it PointAnimationworks with a type Point, but it DoubleAnimationworks with individual values double.
I suggested that I should implement the Timeline-derived class , but the documentation I have found so far does not help in this regard, and I do not know where to start.
How to animate a property for which there is no * Animation class ready? Did I miss something?
Update . I think I can do something like
StoryBoard.SetTargetProperty(aniX, "(MapLayer.Position).Latitude")
StoryBoard.SetTargetProperty(aniY, "(MapLayer.Position).Longitude")
, , " TargetProperty (MapLayer.Position).Latitude ".
, : ?
. , "SetTargetProperty", (. ). ?
3: , RenderTransform . , . :
RepositionThemeAnimation, , . : -, lat/lng , ( , ). -, / . , . , , .RepositionThemeTransition /. , . lat/lng ( MapLayer.SetPosition). . ( ) . , , .