protected override void LoadToMapCore() { if (File.Exists(OutputPathFileName)) { var getLayersParameters = new GetLayersParameters(); getLayersParameters.LayerUris.Add(new Uri(OutputPathFileName)); var layers = GisEditor.LayerManager.GetLayers <ShapeFileFeatureLayer>(getLayersParameters); if (Application.Current != null) { Application.Current.Dispatcher.BeginInvoke(new Action(() => { GisEditor.ActiveMap.AddLayersBySettings(layers); GisEditor.UIManager.BeginRefreshPlugins(new RefreshArgs(this, RefreshArgsDescription.LoadToMapCoreDescription)); })); } else { GisEditor.ActiveMap.AddLayersBySettings(layers); GisEditor.UIManager.BeginRefreshPlugins(new RefreshArgs(this, RefreshArgsDescription.LoadToMapCoreDescription)); } } ShapeFileFeatureLayerExtension.RemoveShapeFiles(clippingLayerTempPath); }
protected override void LoadToMapCore() { if (File.Exists(OutputPathFileName)) { AddSimplifiedFileToMap(); } ShapeFileFeatureLayerExtension.RemoveShapeFiles(tempFilePath); }
protected override void LoadToMapCore() { if (File.Exists(OutputPathFileName)) { var getLayersParameters = new GetLayersParameters(); getLayersParameters.LayerUris.Add(new Uri(OutputPathFileName)); var layers = GisEditor.LayerManager.GetLayers <ShapeFileFeatureLayer>(getLayersParameters); GisEditor.ActiveMap.Dispatcher.BeginInvoke(new Action(() => { GisEditor.ActiveMap.AddLayersBySettings(layers); GisEditor.UIManager.BeginRefreshPlugins(new RefreshArgs(this, RefreshArgsDescription.LoadToMapCoreDescription)); })); } try { ShapeFileFeatureLayerExtension.RemoveShapeFiles(tempFilePath); } catch (Exception ex) { GisEditor.LoggerManager.Log(LoggerLevel.Error, ex.Message, ex); } }
protected override void LoadToMapCore() { ShapeFileFeatureLayerExtension.RemoveShapeFiles(tempFilePath); AddToMap(); }