/// <summary> /// Show Properties dialog. Return true if list is changed /// </summary> /// <param name="parent"></param> /// <returns></returns> public bool ShowPropertiesDialog(BaseControls.ImageBox.ImageCtl parent) { if (SelectionCount < 1) { return(false); } GraphicsProperties properties = GetProperties(); PropertiesDialog dlg = new PropertiesDialog(); dlg.Properties = properties; CommandChangeState c = new CommandChangeState(this); if (dlg.ShowDialog(parent) != DialogResult.OK) { return(false); } if (ApplyProperties(properties)) { c.NewState(this); parent.AddCommandToHistory(c); } return(true); }
public DragDropManager(BaseControls.ImageBox.ImageCtl owner) { frmOwner = owner; // ensure that parent form allows dropping frmOwner.AllowDrop = true; // subscribe to parent form's drag-drop events frmOwner.DragEnter += OnDragEnter; frmOwner.DragDrop += OnDragDrop; }