public void DeleteSelection() { IEditableObject editable = widget.Selection as IEditableObject; if (editable == null) { editable = ObjectWrapper.Lookup(widget.Selection) as IEditableObject; } if (editable != null) { editable.Delete(); } }
void DoDelete(object obj, EventArgs args) { editable.Delete(); }