本文整理汇总了C#中IMap.AddMapObject方法的典型用法代码示例。如果您正苦于以下问题:C# IMap.AddMapObject方法的具体用法?C# IMap.AddMapObject怎么用?C# IMap.AddMapObject使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IMap
的用法示例。
在下文中一共展示了IMap.AddMapObject方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnFragmentInitializationCompleted
public void OnFragmentInitializationCompleted(InitError error)
{
if (error == InitError.None) {
map = mapFragment.Map;
double lat = 30.2652233534254;
double lon = -97.73815460962083;
var geoPolygon = MapFactory.CreateGeoPolygon (new JavaList<Nokia.Here.Common.IGeoCoordinate> {
MapFactory.CreateGeoCoordinate (30.2648461170005, -97.7381627734755),
MapFactory.CreateGeoCoordinate (30.2648355402574, -97.7381750192576),
MapFactory.CreateGeoCoordinate (30.2647791309417, -97.7379872505988),
MapFactory.CreateGeoCoordinate (30.2654525150319, -97.7377341711021),
MapFactory.CreateGeoCoordinate (30.2654807195004, -97.7377994819399),
MapFactory.CreateGeoCoordinate (30.2655089239607, -97.7377994819399),
MapFactory.CreateGeoCoordinate (30.2656428950368, -97.738346460207),
MapFactory.CreateGeoCoordinate (30.2650364981811, -97.7385709662122),
MapFactory.CreateGeoCoordinate (30.2650470749025, -97.7386199493406)
});
var mapPolyline = MapFactory.CreateMapPolygon (geoPolygon);
map.AddMapObject (mapPolyline);
map.SetCenter (MapFactory.CreateGeoCoordinate (lat, lon, 0.0), MapAnimation.None);
map.SetZoomLevel (18.0, MapAnimation.None);
map.MapScheme = MapScheme.SatelliteDay;
}
}