Change RTF token \line to \pard\line so that text displays properly.
Pause timer to refresh the treeview while items are being added.
This commit is contained in:
parent
c159a9889f
commit
f02cce2ced
@ -312,6 +312,8 @@ namespace VEPROMS.CSLA.Library
|
|||||||
// save portion of this code for an explanation.
|
// save portion of this code for an explanation.
|
||||||
text = text.Replace(@"\~", @"\u160?");
|
text = text.Replace(@"\~", @"\u160?");
|
||||||
text = text.Replace("\r\n", @"\line "); // replace a \r\n with a \line instead of a \par
|
text = text.Replace("\r\n", @"\line "); // replace a \r\n with a \line instead of a \par
|
||||||
|
text = text.Replace(@"\line", @"\pard\line");
|
||||||
|
text = text.Replace(@"\pard\pard\line", @"\pard\line");
|
||||||
//if (text.IndexOf(@"\line") > -1)
|
//if (text.IndexOf(@"\line") > -1)
|
||||||
// MessageBox.Show("Found rtf line");
|
// MessageBox.Show("Found rtf line");
|
||||||
//text = text.Replace(@"\line", @"\par"); // we don't want to replace the \line part of bug fix B2015-140
|
//text = text.Replace(@"\line", @"\par"); // we don't want to replace the \line part of bug fix B2015-140
|
||||||
|
@ -548,6 +548,16 @@ namespace Volian.Controls.Library
|
|||||||
{
|
{
|
||||||
if (SectionShouldClose != null) SectionShouldClose(sender, args);
|
if (SectionShouldClose != null) SectionShouldClose(sender, args);
|
||||||
}
|
}
|
||||||
|
public event vlnTreeViewSectionInfoEvent PauseRefresh;
|
||||||
|
private void OnPauseRefresh(object sender, vlnTreeSectionInfoEventArgs args)
|
||||||
|
{
|
||||||
|
if (PauseRefresh != null) PauseRefresh(sender, args);
|
||||||
|
}
|
||||||
|
public event vlnTreeViewSectionInfoEvent UnPauseRefresh;
|
||||||
|
private void OnUnPauseRefresh(object sender, vlnTreeSectionInfoEventArgs args)
|
||||||
|
{
|
||||||
|
if (UnPauseRefresh != null) UnPauseRefresh(sender, args);
|
||||||
|
}
|
||||||
public event WordSectionDeletedEvent WordSectionDeleted;
|
public event WordSectionDeletedEvent WordSectionDeleted;
|
||||||
internal void OnWordSectionDeleted(object sender, WordSectionEventArgs args)
|
internal void OnWordSectionDeleted(object sender, WordSectionEventArgs args)
|
||||||
{
|
{
|
||||||
@ -2090,6 +2100,7 @@ namespace Volian.Controls.Library
|
|||||||
{
|
{
|
||||||
VETreeNode tn = null;
|
VETreeNode tn = null;
|
||||||
if (SelectedNode == null) return;
|
if (SelectedNode == null) return;
|
||||||
|
OnPauseRefresh(this, null);
|
||||||
SetLastValues((VETreeNode)SelectedNode);
|
SetLastValues((VETreeNode)SelectedNode);
|
||||||
|
|
||||||
#region InsertFolderOrDocVersion
|
#region InsertFolderOrDocVersion
|
||||||
@ -2226,6 +2237,7 @@ namespace Volian.Controls.Library
|
|||||||
if (!MySessionInfo.CanCheckOutItem(_LastProcedureInfo.ItemID, CheckOutType.Procedure, ref message))
|
if (!MySessionInfo.CanCheckOutItem(_LastProcedureInfo.ItemID, CheckOutType.Procedure, ref message))
|
||||||
{
|
{
|
||||||
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||||
|
OnUnPauseRefresh(this, null);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
int s1 = -1;
|
int s1 = -1;
|
||||||
@ -2332,6 +2344,7 @@ namespace Volian.Controls.Library
|
|||||||
if (!MySessionInfo.CanCheckOutItem(_LastSectionInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message))
|
if (!MySessionInfo.CanCheckOutItem(_LastSectionInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message))
|
||||||
{
|
{
|
||||||
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||||
|
OnUnPauseRefresh(this, null);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
int tvindex = SelectedNode.Index;
|
int tvindex = SelectedNode.Index;
|
||||||
@ -2373,6 +2386,7 @@ namespace Volian.Controls.Library
|
|||||||
if (!MySessionInfo.CanCheckOutItem(_LastSectionInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message))
|
if (!MySessionInfo.CanCheckOutItem(_LastSectionInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message))
|
||||||
{
|
{
|
||||||
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||||
|
OnUnPauseRefresh(this, null);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
tn = InsertChildStep((VETreeNode)SelectedNode);
|
tn = InsertChildStep((VETreeNode)SelectedNode);
|
||||||
@ -2383,6 +2397,7 @@ namespace Volian.Controls.Library
|
|||||||
if (!MySessionInfo.CanCheckOutItem(_LastStepInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message))
|
if (!MySessionInfo.CanCheckOutItem(_LastStepInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message))
|
||||||
{
|
{
|
||||||
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
MessageBox.Show(this, message, "Item Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||||
|
OnUnPauseRefresh(this, null);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
tn = InsertBeforeOrAfter(newtype, (VETreeNode)SelectedNode);
|
tn = InsertBeforeOrAfter(newtype, (VETreeNode)SelectedNode);
|
||||||
@ -2396,6 +2411,7 @@ namespace Volian.Controls.Library
|
|||||||
Refresh();
|
Refresh();
|
||||||
OnNodeInsert(this, new vlnTreeEventArgs(SelectedNode));
|
OnNodeInsert(this, new vlnTreeEventArgs(SelectedNode));
|
||||||
}
|
}
|
||||||
|
OnUnPauseRefresh(this, null);
|
||||||
}
|
}
|
||||||
private void CreateEnhancedForProcedure(MenuSelections typ, Procedure sourceProc, ProcedureInfo lastProcedureInfo)
|
private void CreateEnhancedForProcedure(MenuSelections typ, Procedure sourceProc, ProcedureInfo lastProcedureInfo)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user