public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; } }
public void OnCreate(MyPluginEngine.IApplication hook) { if (hook != null) { this.hk = hook; m_mapControl = this.hk.MapControl; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; pColumnChart = new ColumnTable(); pColumnChart.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; rasterReClass1 = new RasterReClass(hook.MapControl.Map); rasterReClass1.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; dbconnection = new DBConnection1(); dbconnection.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; aspect = new Aspect(hook.MapControl.Map); aspect.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; linetab = new LineTable(); linetab.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; pfrmGDP = new frmTEMP(); pfrmGDP.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; resample = new Resample1(); resample.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; pfrmFlood = new FrmZhuji(hk); pfrmFlood.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; pSituationAna = new SituationAna(); pSituationAna.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; //pfrmTable = new frmTable(); //pfrmTable.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; pfrmGDP = new frmGDP(); pfrmGDP.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; F2Raster = new FeatureToRaster1(); F2Raster.pMap = hk.MapControl.Map; F2Raster.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; spline = new Spline1(); spline.pMap = hk.MapControl.Map; spline.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; rastertopolygon = new RasterToPolygon1(); rastertopolygon.pMap = hk.MapControl.Map; rastertopolygon.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; this._PageLayoutControl = hk.PageLayoutControl as IPageLayoutControl; pfrmBiodiversity = new frmBiodiversity(_PageLayoutControl); pfrmBiodiversity.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; prj = new Project1(); prj.pMap = hk.MapControl.Map; prj.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; idw = new IDW1(); idw.pMap = hk.MapControl.Map; idw.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; kriging = new Kriging1(); kriging.pMap = hk.MapControl.Map; kriging.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; rastercalculator = new RasterCalculator1(); rastercalculator.pMap = hk.MapControl.Map; rastercalculator.Visible = false; } }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; this._PageLayoutControl = hk.PageLayoutControl as IPageLayoutControl; pfrmTerrain = new frmTerrain(_PageLayoutControl); pfrmTerrain.Visible = false; } }
/// <summary> /// Occurs when this tool is created /// </summary> /// <param name="hook">Instance of the application</param> public void OnCreate(MyPluginEngine.IApplication hook) { try { //m_hookHelper = new HookHelperClass(); this.hk = hook; } catch { this.hk = null; } // TODO: Add other initialization code }
public void OnCreate(IApplication hook) { if (hook != null) { this.hk = hook; _layerMenu = new ToolbarMenuClass(); _rightMenu1 = new PageRightBtnMenu(this.hk.PageLayoutControl); _rightMenu2 = new PageRightBtnMenu(this.hk.PageLayoutControl); _layerMenu.AddItem(_rightMenu1, 1, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.AddItem(_rightMenu2, 2, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.SetHook(this.hk.PageLayoutControl); } }
public MainGIS() { InitializeComponent(); //设置图层控件的同步控件 this.axTOCControl1.SetBuddyControl(this.axMapControl1.Object); //初始化公共变量 _mapControl = axMapControl1.Object as IMapControlDefault; _pageLayoutControl = axPageLayoutControl1.Object as IPageLayoutControlDefault; _tocControl = axTOCControl1.Object as ITOCControlDefault; _DataSet = new DataSet(); //初始化主框架 _App = new MyPluginEngine.Application(); _App.StatusBar = this.uiStatusBar; _App.MapControl = _mapControl; _App.PageLayoutControl = _pageLayoutControl; _App.TOCControl = _tocControl; _App.MainPlatfrom = this; _App.Caption = this.Text; _App.Visible = this.Visible; _App.CurrentTool = null; _App.MainDataSet = _DataSet; //让MapControl和PageLatoutControl保存同步 axTOCControl1.SetBuddyControl(_mapControl); m_controlsSynchronizer = new ControlsSynchronizer(_mapControl, _pageLayoutControl); //在同步是同时设置好与TOCControl和ToolBarControl的buddy m_controlsSynchronizer.AddFrameWorkControl(axTOCControl1.Object); m_controlsSynchronizer.AddFrameWorkControl(axToolbarControl1.Object); m_controlsSynchronizer.BindControls(true); //TOCControl的esriTOOControlItemMap被右键点击后弹出的快捷菜单 _mapMenu = new ToolbarMenuClass(); //通过自己的 MapMent进行添加功能,这里只有两个功能 _mapMenu.AddItem(new MapMenu(), 1, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _mapMenu.AddItem(new MapMenu(), 2, 1, false, esriCommandStyles.esriCommandStyleTextOnly); //使用 uid //IUID uid = new UIDClass(); //uid.Value = "esriControlCommands.ControlsMapFullExtent"; //_mapMenu.AddItem(uid, -1, -1, true, esriCommandStyles.esriCommandStyleIconAndText); _mapMenu.AddItem(new ControlsMapFindCommand(), -1, 2, true, esriCommandStyles.esriCommandStyleIconAndText); //使用 progid string progid = "esriControlCommands.ControlsMapViewMenu"; _mapMenu.AddItem(progid, -1, -1, false, esriCommandStyles.esriCommandStyleIconAndText); //使用内置 Command _mapMenu.AddItem(new ControlsAddDataCommand(), -1 , 2, true, esriCommandStyles.esriCommandStyleIconAndText); _mapMenu.SetHook(this._mapControl); //2015/7/17 //TOCControl的esriTOOControlItemLayer被右键点击后弹出的快捷菜单 _layerMenu = new ToolbarMenuClass(); // 分别为缩放至图层、删除图层、打开属性表 + _layerMenu.AddItem(new LayerMenu(this._mapControl), 1, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.AddItem(new LayerMenu(this._mapControl), 2, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.AddItem(new LayerMenu(this._mapControl), 3, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.SetHook(this._mapControl); }
public MainGIS() { InitializeComponent(); //设置图层控件的同步控件 //this.axTOCControl1.SetBuddyControl(this.axMapControl1.Object); //初始化公共变量 _mapControl = axMapControl1.Object as IMapControlDefault; _pageLayoutControl = axPageLayoutControl1.Object as IPageLayoutControlDefault; _tocControl = axTOCControl1.Object as ITOCControlDefault; _DataSet = new DataSet(); //初始化主框架 _App = new MyPluginEngine.Application(); _App.StatusBar = this.uiStatusBar; _App.MapControl = _mapControl; _App.PageLayoutControl = _pageLayoutControl; _App.TOCControl = _tocControl; _App.MainPlatfrom = this; _App.Caption = this.Text; _App.Visible = this.Visible; _App.CurrentTool = null; _App.MainDataSet = _DataSet; //让MapControl和PageLatoutControl保存同步 m_controlsSynchronizer = new ControlsSynchronizer(_mapControl, _pageLayoutControl); //在同步时同时设置好与TOCControl和ToolBarControl的buddy m_controlsSynchronizer.AddFrameWorkControl(axTOCControl1.Object); m_controlsSynchronizer.AddFrameWorkControl(axToolbarControl1.Object); m_controlsSynchronizer.BindControls(true); this._App.MainCtrlsSynchronizer = m_controlsSynchronizer; //TOCControl的esriTOOControlItemMap被右键点击后弹出的快捷菜单 _mapMenu = new ToolbarMenuClass(); //通过自己的 MapMent进行添加功能,这里只有两个功能 _mapMenu.AddItem(new MapMenu(), 1, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _mapMenu.AddItem(new MapMenu(), 2, 1, false, esriCommandStyles.esriCommandStyleTextOnly); //使用 uid //IUID uid = new UIDClass(); //uid.Value = "esriControlCommands.ControlsMapFullExtentCommand"; //_mapMenu.AddItem(uid, -1, -1, true, esriCommandStyles.esriCommandStyleIconAndText); _mapMenu.AddItem(new ControlsMapFindCommand(), -1, 2, true, esriCommandStyles.esriCommandStyleIconAndText); //使用 progid string progid = "esriControlCommands.ControlsMapViewMenu"; _mapMenu.AddItem(progid, -1, -1, false, esriCommandStyles.esriCommandStyleIconAndText); //使用内置 Command _mapMenu.AddItem(new ControlsAddDataCommand(), -1, 2, true, esriCommandStyles.esriCommandStyleIconAndText); _mapMenu.SetHook(this._mapControl); //2015/7/17 //TOCControl的esriTOOControlItemLayer被右键点击后弹出的快捷菜单 _layerMenu = new ToolbarMenuClass(); // 分别为缩放至图层、删除图层、打开属性表 符号选择器 //符号选择器 LayerMenu layerMenuSymbol = new LayerMenu(this._mapControl); layerMenuSymbol.SymbolChanged += new LayerMenu.SymbolChangedHandler(layerMenuSymbol_SymbolChanged); //layerMenuSymbol.SymbolChanged += new SymbolChangedHandler(layerMenuSymbol_SymbolChanged); _layerMenu.AddItem(layerMenuSymbol, 1, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.AddItem(new LayerMenu(this._mapControl), 2, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.AddItem(new LayerMenu(this._mapControl), 3, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.AddItem(new LayerMenu(this._mapControl), 4, 0, false, esriCommandStyles.esriCommandStyleTextOnly); _layerMenu.SetHook(this._mapControl); }