Inheritance: PropertyControlBase
コード例 #1
0
        public void ToolChanged()
        {
            _currentPrimitive = null;
            RemoveAllProperties();

            PropertyControlBase propertyControl = null;

            switch (_selectedTool)
            {
            case TpTool.FreeLine:
                propertyControl = new FreeLinePropertyControl();
                break;

            case TpTool.Line:
                propertyControl = new LinePropertyControl();
                break;

            case TpTool.TextBox:
                propertyControl = new DecoratedTextBoxPropertyControl();
                break;

            case TpTool.Box:
                propertyControl = new BoxPropertyControl();
                break;
            }

            AddProperties(propertyControl);
            UpdatePropertiesView();
            Focus();
        }
コード例 #2
0
		public void ToolChanged()
		{
			_currentPrimitive = null;
			RemoveAllProperties();

			PropertyControlBase propertyControl = null;

			switch (_selectedTool)
			{
				case TpTool.FreeLine:
					propertyControl = new FreeLinePropertyControl();
					break;
				case TpTool.Line:
					propertyControl = new LinePropertyControl();
					break;
				case TpTool.TextBox:
					propertyControl = new DecoratedTextBoxPropertyControl();
					break;
				case TpTool.Box:
					propertyControl = new BoxPropertyControl();
					break;
			}

			AddProperties(propertyControl);
			UpdatePropertiesView();
			Focus();
		}