Ejemplo n.º 1
0
        //设置当前工具(选择元素)
        private void SetCurrentTool()
        {
            ICommand pSelect = new ControlsSelectToolClass();

            pSelect.OnCreate(m_pageLayoutControl.Object);
            m_pageLayoutControl.CurrentTool = pSelect as ITool;
        }
Ejemplo n.º 2
0
        private void btn_SelectElement_Click(object sender, EventArgs e)
        {
            ICommand cmd = new ControlsSelectToolClass();

            cmd.OnCreate(m_controlsSynchronizer.ActiveControl);
            m_controlsSynchronizer.ActiveControlCurrentTool = (ITool)cmd;
        }
Ejemplo n.º 3
0
        private void barButtonItem13_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ICommand pCommand = new ControlsSelectToolClass();
            ITool    pTool    = pCommand as ITool;

            switch (this.xtraTabControl1.SelectedTabPageIndex)
            {
            case 0:
                pCommand.OnCreate(this.mainMapControl.Object);
                this.mainMapControl.CurrentTool = pTool;
                break;

            case 1:
                pCommand.OnCreate(this.axPageLayoutControl.Object);
                this.axPageLayoutControl.CurrentTool = pTool;
                break;
            }
        }
Ejemplo n.º 4
0
        private void buttonItem23_Click(object sender, EventArgs e)
        {
            ICommand pCommand = null;

            pCommand = new ControlsSelectToolClass(); //选择要素
            pCommand.OnCreate(axMapControl2.Object);  //使得PageLayoutContro中对象可以编辑
            axMapControl2.CurrentTool = (ITool)pCommand;
            MapSelectFeature();
        }
Ejemplo n.º 5
0
        //选择元素
        public static void SelectElementTool(AxMapControl mapControl, AxPageLayoutControl pageLayoutControl)
        {
            ICommand pSelect1 = new ControlsSelectToolClass();

            pSelect1.OnCreate(mapControl.Object);
            mapControl.CurrentTool = pSelect1 as ITool;
            ICommand pSelect2 = new ControlsSelectToolClass();

            pSelect2.OnCreate(pageLayoutControl.Object);
            pageLayoutControl.CurrentTool = pSelect2 as ITool;
        }
Ejemplo n.º 6
0
        // 选择
        public static void Select(AxMapControl axMapControl)
        {
            if (axMapControl == null)
            {
                return;
            }
            ICommand pCommand;

            pCommand = new ControlsSelectToolClass();
            pCommand.OnCreate(axMapControl.Object);
            axMapControl.CurrentTool = (ITool)pCommand;
        }
 // 选择
 public static void Select(AxMapControl axMapControl)
 {
     if (axMapControl == null)
     {
         return;
     }
     ICommand pCommand;
     pCommand = new ControlsSelectToolClass();
     pCommand.OnCreate(axMapControl.Object);
     axMapControl.CurrentTool = (ITool)pCommand;
 }
Ejemplo n.º 8
0
 private void btnDrawSelectElement_Click(object sender, EventArgs e)
 {
     this.drawBarCheckOnClick(((DevComponents.DotNetBar.ButtonItem)sender).Name);
     ICommand pCommand = new ControlsSelectToolClass();
     ITool pTool = pCommand as ITool;
     switch (this.tabControl.SelectedTabIndex)
     {
         case 0:
             pCommand.OnCreate(this.mainMapControl.Object);
             this.mainMapControl.CurrentTool = pTool;
             break;
         case 1:
             pCommand.OnCreate(this.axPageLayoutControl.Object);
             this.axPageLayoutControl.CurrentTool = pTool;
             break;
     }
 }
Ejemplo n.º 9
0
 private void bubbleBtnSelectElement_Click(object sender, DevComponents.DotNetBar.ClickEventArgs e)
 {
     ICommand pCommand = new ControlsSelectToolClass();
     ITool pTool = pCommand as ITool;
     switch (this.tabControl.SelectedTabIndex)
     {
         case 0:
             pCommand.OnCreate(this.mainMapControl.Object);
             this.mainMapControl.CurrentTool = pTool;
             break;
         case 1:
             pCommand.OnCreate(this.axPageLayoutControl.Object);
             this.axPageLayoutControl.CurrentTool = pTool;
             break;
     }
 }
Ejemplo n.º 10
0
        private void btnPointer_Click(object sender, EventArgs e)
        {
            UncheckAllButtons(sender);

            var cmd = new ControlsSelectToolClass();
            cmd.OnCreate(axMapControl1.Object);
            axMapControl1.CurrentTool = (ITool)cmd;
        }