public ICommand CommandProxy(object objCommand)
        {
            if (objCommand is ESRI.ArcGIS.SystemUI.ICommandSubType)
                return null;

            if (objCommand is ESRI.ArcGIS.SystemUI.IToolControl)
            {
                objCommand = new EsriExProxy(objCommand as ESRI.ArcGIS.SystemUI.IToolControl);
            }
            else if (objCommand is ESRI.ArcGIS.SystemUI.ICommand)
            {
                objCommand = new EsriCommandProxy(objCommand as ESRI.ArcGIS.SystemUI.ICommand);
            }
            return objCommand as ICommand;
        }
Exemple #2
0
        public ICommand CommandProxy(object objCommand)
        {
            if (objCommand is ESRI.ArcGIS.SystemUI.ICommandSubType)
            {
                return(null);
            }

            if (objCommand is ESRI.ArcGIS.SystemUI.IToolControl)
            {
                objCommand = new EsriExProxy(objCommand as ESRI.ArcGIS.SystemUI.IToolControl);
            }
            else if (objCommand is ESRI.ArcGIS.SystemUI.ICommand)
            {
                objCommand = new EsriCommandProxy(objCommand as ESRI.ArcGIS.SystemUI.ICommand);
            }
            return(objCommand as ICommand);
        }