年度变更建库软件5.0版本
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
2.0 KiB

6 months ago
using ESRI.ArcGIS.Carto;
using ESRI.ArcGIS.Controls;
using KGIS.Framework.AE.ExtensionMethod;
using KGIS.Framework.Commands;
using KGIS.Framework.Maps;
using KGIS.Framework.Utils;
using KGIS.Framework.Utils.Helper;
using KGIS.Plugin.LayerProperty.Interface;
using KGIS.Plugin.LayerProperty.View;
using System;
namespace KGIS.Plugin.LayerProperty.Commands
{
class CmdLayerStyleSet : BaseMapMenuCommand
{
public override void OnClick()
{
try
{
//KGIS.Framework.Common.Utils.LicenseManager.License();
object layer = m_hookHelper.GetCustomProperty();
// UCLayerStyleSet layerStyleSet = new UCLayerStyleSet(layer as ILayer,m_hookHelper);
// layerStyleSet.WindowStartupLocation = System.Windows.WindowStartupLocation.CenterScreen;
// layerStyleSet.Width = 700;
// layerStyleSet.Height = 180;
// layerStyleSet.ShowInMainForm(false);
// if (m_hookHelper.ActiveView != null)
// {
// //调用此函数使TOC能够被update
// m_hookHelper.ActiveView.ContentsChanged();
// m_hookHelper.ActiveView.PartialRefresh(esriViewDrawPhase.esriViewBackground | esriViewDrawPhase.esriViewForeground |
//esriViewDrawPhase.esriViewGeography | esriViewDrawPhase.esriViewGeoSelection |
//esriViewDrawPhase.esriViewGraphics | esriViewDrawPhase.esriViewGraphicSelection, null, m_hookHelper.ActiveView.Extent);
// }
}
catch (Exception ex)
{
LogAPI.Debug("加载图层样式界面时发生异常,异常信息如下:");
LogAPI.Debug(ex);
LogAPI.Debug("异常信息结束。");
}
}
public override void OnCreate(object Hook)
{
if (m_hookHelper == null)
{
m_hookHelper = new HookHelper();
m_hookHelper.Hook = Hook;
}
}
}
}