private void View_DrawingDeleting(object sender, DrawingEventArgs e) { HistoryMemento memento = new HistoryMementoDeleteDrawing(frameServer.Metadata, e.ManagerId, e.Drawing.Id, e.Drawing.Name); frameServer.Metadata.DeleteDrawing(e.ManagerId, e.Drawing.Id); historyStack.PushNewCommand(memento); }
private void View_DrawingDeleting(object sender, DrawingEventArgs e) { // Temporary function. This code should be done by metadata manipulator. HistoryMemento memento = new HistoryMementoDeleteDrawing(frameServer.Metadata, e.ManagerId, e.Drawing.Id, e.Drawing.ToolDisplayName); frameServer.Metadata.DeleteDrawing(e.ManagerId, e.Drawing.Id); historyStack.PushNewCommand(memento); }
private void LabelAdded(object sender, DrawingEventArgs e) { //AbstractDrawing drawing, int keyframeIndex) DrawingText label = e.Drawing as DrawingText; if (label == null) { return; } label.ContainerScreen = view; view.Controls.Add(label.EditBox); label.EditBox.BringToFront(); label.EditBox.Focus(); }
private void View_DrawingAdding(object sender, DrawingEventArgs e) { AddDrawingWithMemento(e.ManagerId, e.Drawing); }