This commit is contained in:
Kathy Ruffing 2010-09-27 12:43:35 +00:00
parent 0c246c22a5
commit 52fe4b6ddd
2 changed files with 9 additions and 2 deletions

View File

@ -1382,7 +1382,7 @@ namespace Volian.Controls.Library
default: // Need debug
break;
}
_MyStepPanel.SelectedStepRTB = newStepItem.MyStepRTB;//Update Screen
if (newStepItem != null) _MyStepPanel.SelectedStepRTB = newStepItem.MyStepRTB;//Update Screen
_MyStepPanel.MyStepTabPanel.MyDisplayTabControl.OnItemPaste(this, new vlnTreeItemInfoPasteEventArgs(newItemInfo, copyStartID, ItemInfo.EAddpingPart.Before, newItemInfo.MyContent.Type));
}

View File

@ -6,6 +6,7 @@ using System.Data;
using System.Text;
using System.Windows.Forms;
using System.IO;
using System.Text.RegularExpressions;
using VEPROMS.CSLA.Library;
namespace Volian.Controls.Library
@ -630,7 +631,13 @@ namespace Volian.Controls.Library
{
IDataObject myDO = Clipboard.GetDataObject();
if (myDO.GetDataPresent(DataFormats.Rtf))
_MyStepRTB.SelectedRtf = myDO.GetData(DataFormats.Rtf).ToString();
{
string tmpForLink = myDO.GetData(DataFormats.Rtf).ToString();
tmpForLink = Regex.Replace(tmpForLink, @"#Link:ReferencedObject:[0-9]+ ", @"#Link:ReferencedObject:<NewID> ");
tmpForLink = Regex.Replace(tmpForLink, @"#Link:Transition:([0-9]+) [0-9]+ ", @"#Link:Transition:$1 <NewID> ");
tmpForLink = Regex.Replace(tmpForLink, @"#Link:TransitionRange:([0-9]+) [0-9]+ ", @"#Link:TransitionRange:$1 <NewID> ");
_MyStepRTB.SelectedRtf = tmpForLink;
}
else if (myDO.GetDataPresent(DataFormats.Text))
_MyStepRTB.SelectedText = myDO.GetData(DataFormats.Text).ToString();
if (_MyStepRTB.SelectionLength == 0) _MyStepRTB.SelectionFont = _MyStepRTB.MyStyleFont.WindowsFont;