From 609ddb1962ccc410a674579a26133da913dc982f Mon Sep 17 00:00:00 2001 From: Kathy Date: Mon, 9 May 2016 11:32:13 +0000 Subject: [PATCH] =?UTF-8?q?Enhanced:=20Refresh=20enhanced=20procedure?= =?UTF-8?q?=E2=80=99s=20text=20if=20different=20from=20source=20(prompt=20?= =?UTF-8?q?user)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Volian.Controls.Library/DisplayTabControl.cs | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/PROMS/Volian.Controls.Library/DisplayTabControl.cs b/PROMS/Volian.Controls.Library/DisplayTabControl.cs index e630a0b6..fae9229f 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabControl.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabControl.cs @@ -931,6 +931,22 @@ namespace Volian.Controls.Library pg.Selected = true; HandleChangeId(myItemInfo, pg); SelectDisplayTabItem(pg); + + // If this is an enhanced document, check for refresh of text items: + if (myItemInfo.IsProcedure) + { + // make the myiteminfo into a procedureinfo (depending on where this is called from, just + // casting it crashed: + ProcedureInfo pi = ProcedureInfo.Get(myItemInfo.ItemID); + ItemInfoList iil = pi.FindEnhancedProcedureTextDifferences(); + if (iil != null) + { + if (MessageBox.Show(this, "Text differences were found between this enhanced procedure and its source procedure. Do you want to refresh the text in this procedure?", "Confirm Text Refresh", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question) == DialogResult.Yes) + { + pi.EnhancedProcedureRefreshTextDifferences(iil); + } + } + } } pg.MyStepTabPanel.MyProcedureItemInfo = proc;