public override Control ShowControl(Rectangle valueRect, PropertyEnumerator propEnum) { // if (propEnum.Property.Value.IsReadOnly(propEnum)) // return null; PropInPlaceUITypeEditor inPlaceCtrl; if (mInPlaceCtrl == null) { inPlaceCtrl = new PropInPlaceUITypeEditor(_editor, true); inPlaceCtrl.Visible = false; inPlaceCtrl.Parent = mParentWnd; mInPlaceCtrl = inPlaceCtrl; } else inPlaceCtrl = (PropInPlaceUITypeEditor)mInPlaceCtrl; NotifyInPlaceControlCreated(propEnum); /* if (propEnum.Property.Value.HasMultipleValues) inPlaceCtrl.Text = ""; else inPlaceCtrl.Text = propEnum.Property.Value.DisplayString; */ inPlaceCtrl.OwnerPropertyEnumerator = propEnum; inPlaceCtrl.Font = propEnum.Property.Value.Font; MoveControl(valueRect, propEnum); return base.ShowControl(valueRect, propEnum); }
public DropDownForm(PropInPlaceUITypeEditor inPlaceCtrl, bool resizable) { FormBorderStyle = FormBorderStyle.None; ShowInTaskbar = false; KeyPreview = true; StartPosition = FormStartPosition.Manual; _inPlaceCtrl = inPlaceCtrl; _inPlaceCtrl.SetDropDownContainer(this); _resizable = resizable; Win32Calls.SetWindowLong(Handle, -8, (int)inPlaceCtrl.Parent.Handle); IntPtr handle = (IntPtr)Win32Calls.GetWindowLong(Handle, -8); Control ancestorControl = Control.FromHandle(handle); }
public EditorService(PropInPlaceUITypeEditor inPlaceCtrl) { _inPlaceCtrl = inPlaceCtrl; }