From d7a7c13b724033eabd0901e37db0b99f6ee578c8 Mon Sep 17 00:00:00 2001 From: Rich Date: Thu, 28 Aug 2014 02:42:02 +0000 Subject: [PATCH] Added code to display hour glass when copying and pasting items --- PROMS/Volian.Controls.Library/vlnTreeView.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/PROMS/Volian.Controls.Library/vlnTreeView.cs b/PROMS/Volian.Controls.Library/vlnTreeView.cs index 0fe12659..40d6ef41 100644 --- a/PROMS/Volian.Controls.Library/vlnTreeView.cs +++ b/PROMS/Volian.Controls.Library/vlnTreeView.cs @@ -1067,6 +1067,7 @@ namespace Volian.Controls.Library else { ItemInfo iiPasteHere = tn.VEObject as ItemInfo; + if (iiPasteHere == null) return; bool okToReplace = iiClipboard.ItemID != iiPasteHere.ItemID; if (iiPasteHere != null) { @@ -1467,13 +1468,15 @@ namespace Volian.Controls.Library ItemInfo iiPaste = tn.VEObject as ItemInfo; if (iiPaste == null) return; + this.Cursor = Cursors.WaitCursor; if (p.IndexOf("Before") > -1) PasteBeforeOrAfter(MenuSelections.StepBefore, tn, iiClipboard.ItemID); else if (p.IndexOf("After") > -1) PasteBeforeOrAfter(MenuSelections.StepAfter, tn, iiClipboard.ItemID); else if (p.IndexOf("Replace") > -1) PasteReplace(tn, iiClipboard.ItemID); - } + this.Cursor = Cursors.Default; + } private void PasteBeforeOrAfter(MenuSelections newtype, VETreeNode tn, int copyStartID) { // If paste-from step is open in the editor, use the OnPasteItemInfo to paste the step and add RTBItems