Added a null reference check for selectedDVI on the tc_PanelTabDisplay() function.
Added logic to skip the checks for changed integrated graphics (figures) when the RO database has none.
This commit is contained in:
parent
56ab02c3f7
commit
ac47021609
@ -2889,6 +2889,7 @@ namespace VEPROMS
|
|||||||
}
|
}
|
||||||
private void tc_PanelTabDisplay(object sender, StepPanelTabDisplayEventArgs args)
|
private void tc_PanelTabDisplay(object sender, StepPanelTabDisplayEventArgs args)
|
||||||
{
|
{
|
||||||
|
if (_SelectedDVI == null) return;
|
||||||
if (args.PanelTabName == "Bookmarks")
|
if (args.PanelTabName == "Bookmarks")
|
||||||
{
|
{
|
||||||
toolsPanel.Expanded = true;
|
toolsPanel.Expanded = true;
|
||||||
|
@ -390,6 +390,8 @@ namespace VEPROMS.CSLA.Library
|
|||||||
/// <param name="ChangedFiles">List of Files that have changed</param>
|
/// <param name="ChangedFiles">List of Files that have changed</param>
|
||||||
/// <param name="roids">List of ROIDs with changed figures</param>
|
/// <param name="roids">List of ROIDs with changed figures</param>
|
||||||
private static void FindChangedFiles(ROFSTLookup.rochild[] rochild,List<string> ChangedFiles, List<string> roids)
|
private static void FindChangedFiles(ROFSTLookup.rochild[] rochild,List<string> ChangedFiles, List<string> roids)
|
||||||
|
{
|
||||||
|
if (ChangedFiles != null)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < rochild.Length; i++)
|
for (int i = 0; i < rochild.Length; i++)
|
||||||
{
|
{
|
||||||
@ -397,10 +399,11 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
string filename = rochild[i].value;
|
string filename = rochild[i].value;
|
||||||
filename = filename.Substring(0, filename.IndexOf('\n'));
|
filename = filename.Substring(0, filename.IndexOf('\n'));
|
||||||
if(ChangedFiles.Contains(filename))
|
if (ChangedFiles.Contains(filename))
|
||||||
roids.Add(rochild[i].roid);
|
roids.Add(rochild[i].roid);
|
||||||
}
|
}
|
||||||
if (rochild[i].children != null) FindChangedFiles(rochild[i].children,ChangedFiles, roids);
|
if (rochild[i].children != null) FindChangedFiles(rochild[i].children, ChangedFiles, roids);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -411,6 +414,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
/// <returns>List of Files which have changed (DTS)</returns>
|
/// <returns>List of Files which have changed (DTS)</returns>
|
||||||
private static List<string> GetChangedFigures(ROFstInfo origROFst, ROFstInfo rofst)
|
private static List<string> GetChangedFigures(ROFstInfo origROFst, ROFstInfo rofst)
|
||||||
{
|
{
|
||||||
|
if (origROFst.ROFstFigures == null) return null;
|
||||||
Dictionary<string,int> orig = new Dictionary<string,int>();
|
Dictionary<string,int> orig = new Dictionary<string,int>();
|
||||||
foreach (FigureInfo fi in origROFst.ROFstFigures)
|
foreach (FigureInfo fi in origROFst.ROFstFigures)
|
||||||
{
|
{
|
||||||
@ -463,6 +467,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
List<string> delList = new List<string>();
|
List<string> delList = new List<string>();
|
||||||
List<string> chgList = newLU.GetValueDifferences(origLU, ref delList);
|
List<string> chgList = newLU.GetValueDifferences(origLU, ref delList);
|
||||||
// Any figures which have been changed will be included in the list of values that have changed.
|
// Any figures which have been changed will be included in the list of values that have changed.
|
||||||
|
if (MyChangedFigureROIDs != null)
|
||||||
foreach (string roid in MyChangedFigureROIDs)
|
foreach (string roid in MyChangedFigureROIDs)
|
||||||
if (!chgList.Contains(roid))
|
if (!chgList.Contains(roid))
|
||||||
chgList.Add(roid);
|
chgList.Add(roid);
|
||||||
@ -522,7 +527,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
foreach (string chg in chgList)
|
foreach (string chg in chgList)
|
||||||
{
|
{
|
||||||
string padroid = chg.Length <= 12 ? chg + "0000" : chg;
|
string padroid = chg.Length <= 12 ? chg + "0000" : chg;
|
||||||
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Updating DRO Values");
|
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Updating RO Values");
|
||||||
if (activeDRoids.Contains(chg.Substring(0, 12)))
|
if (activeDRoids.Contains(chg.Substring(0, 12)))
|
||||||
{
|
{
|
||||||
ROFSTLookup.rochild roch = newLU.GetRoChild(chg);
|
ROFSTLookup.rochild roch = newLU.GetRoChild(chg);
|
||||||
@ -587,7 +592,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
foreach (DROUsageInfo droUsg in Daffected)
|
foreach (DROUsageInfo droUsg in Daffected)
|
||||||
{
|
{
|
||||||
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Removing Old DRO Values");
|
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Removing Old RO Values");
|
||||||
Pdf.DeleteAll(droUsg.DocID);
|
Pdf.DeleteAll(droUsg.DocID);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user