Display a MessageBox if in debug mode ItemInfo (frmPropGrid) is opened without selecting an Item
Added Interface properties SearchDVPath and SearchPath
This commit is contained in:
parent
4b967f6d4b
commit
7e6fefb00c
@ -983,7 +983,6 @@ namespace VEPROMS
|
||||
{
|
||||
toolsPanel.Expanded = true;
|
||||
toolsTabs.SelectedTab = tabItemLibDocs;
|
||||
toolsTabs.SelectedTab.PerformClick();
|
||||
}
|
||||
else if (args.PanelTabName == "Annots")
|
||||
{
|
||||
@ -1405,8 +1404,13 @@ namespace VEPROMS
|
||||
|
||||
private void btnItemInfo_Click(object sender, EventArgs e)
|
||||
{
|
||||
frmPropGrid pg = new frmPropGrid(tc.SelectedDisplayTabItem.SelectedItemInfo, tc.SelectedDisplayTabItem.SelectedItemInfo.Path);
|
||||
pg.Show();
|
||||
if (tc.SelectedDisplayTabItem != null && tc.SelectedDisplayTabItem.SelectedItemInfo != null)
|
||||
{
|
||||
frmPropGrid pg = new frmPropGrid(tc.SelectedDisplayTabItem.SelectedItemInfo, tc.SelectedDisplayTabItem.SelectedItemInfo.Path);
|
||||
pg.Show();
|
||||
}
|
||||
else
|
||||
MessageBox.Show("Select Item First", "Item not selected", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
}
|
||||
|
||||
private void epAnnotations_Resize(object sender, EventArgs e)
|
||||
|
@ -124,6 +124,20 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
public partial class DocVersionInfo : IVEDrillDownReadOnly
|
||||
{
|
||||
#region SearchPaths
|
||||
public string _SearchDVPath;
|
||||
public string SearchDVPath
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_SearchDVPath == null)
|
||||
_SearchDVPath = ActiveParent.SearchDVPath + "\u0007" + Name;
|
||||
return _SearchDVPath;
|
||||
}
|
||||
}
|
||||
public string SearchPath { get { return ""; } }
|
||||
#endregion
|
||||
|
||||
#region DocVersion Config
|
||||
[NonSerialized]
|
||||
private DocVersionConfig _DocVersionConfig;
|
||||
|
@ -108,6 +108,24 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
public partial class FolderInfo:IVEDrillDownReadOnly
|
||||
{
|
||||
#region Search Paths
|
||||
public string _SearchDVPath;
|
||||
public string SearchDVPath
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_SearchDVPath == null)
|
||||
{
|
||||
if (ActiveParent == null)
|
||||
_SearchDVPath = Name;
|
||||
else
|
||||
_SearchDVPath = ActiveParent.SearchDVPath + "\u0007" + Name;
|
||||
}
|
||||
return _SearchDVPath;
|
||||
}
|
||||
}
|
||||
public string SearchPath { get { return ""; } }
|
||||
#endregion
|
||||
#region Folder Config (Read-Only)
|
||||
[NonSerialized]
|
||||
private FolderConfig _FolderConfig;
|
||||
|
@ -1141,12 +1141,35 @@ namespace VEPROMS.CSLA.Library
|
||||
internal string _SearchDVPath;
|
||||
public string SearchDVPath
|
||||
{
|
||||
get { return _SearchDVPath; }
|
||||
get
|
||||
{
|
||||
if (_SearchDVPath == null)
|
||||
_SearchDVPath = ActiveParent.SearchDVPath;
|
||||
return _SearchDVPath;
|
||||
}
|
||||
}
|
||||
internal string _SearchPath;
|
||||
public string SearchPath
|
||||
{
|
||||
get { return _SearchPath; }
|
||||
get
|
||||
{
|
||||
if (_SearchPath==null)
|
||||
{
|
||||
if (IsProcedure)
|
||||
_SearchPath = ActiveParent.SearchPath + "\u0007" + (DisplayNumber ?? "") + "\u0011" + DisplayText ;
|
||||
else if (IsSection)
|
||||
_SearchPath = ActiveParent.SearchPath + "\u0007" + (DisplayNumber ?? "") + "\u0011" + DisplayText;
|
||||
else
|
||||
{
|
||||
PartInfo myPart = FirstSibling.ItemPartCount > 0 ? FirstSibling.ItemParts[0] : null;
|
||||
if(myPart != null)
|
||||
_SearchPath = myPart.SearchPath + (!IsHigh ? "." : "\u0007") + Ordinal.ToString();
|
||||
else
|
||||
_SearchPath = ActiveParent.SearchPath + (!IsHigh ? "." : "\u0007") + Ordinal.ToString();
|
||||
}
|
||||
}
|
||||
return _SearchPath;
|
||||
}
|
||||
}
|
||||
public string ShortSearchPath
|
||||
{
|
||||
|
@ -60,6 +60,53 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
public partial class PartInfo : IVEDrillDownReadOnly
|
||||
{
|
||||
private string _SearchDVPath;
|
||||
public string SearchDVPath
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_SearchDVPath == null)
|
||||
_SearchDVPath = ActiveParent.SearchDVPath;
|
||||
return _SearchDVPath;
|
||||
}
|
||||
}
|
||||
private string _SearchPath;
|
||||
public string SearchPath
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_SearchPath == null)
|
||||
{
|
||||
string partText = "";
|
||||
switch ((E_FromType) FromType)
|
||||
{
|
||||
case E_FromType.Procedure:
|
||||
break;
|
||||
case E_FromType.Section:
|
||||
break;
|
||||
case E_FromType.Caution:
|
||||
partText = ".Caution";
|
||||
break;
|
||||
case E_FromType.Note:
|
||||
partText = ".Note";
|
||||
break;
|
||||
case E_FromType.RNO:
|
||||
partText = ".RNO";
|
||||
break;
|
||||
case E_FromType.Step:
|
||||
break;
|
||||
case E_FromType.Table:
|
||||
partText = ".Table";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
_SearchPath = ActiveParent.SearchPath + partText;
|
||||
}
|
||||
return _SearchPath;
|
||||
}
|
||||
}
|
||||
|
||||
internal PartInfo(SafeDataReader dr, ItemInfo itemInfo)
|
||||
{
|
||||
if (_MyLog.IsDebugEnabled) _MyLog.DebugFormat("[{0}] PartInfo.Constructor", GetHashCode());
|
||||
|
@ -14,6 +14,8 @@ namespace VEPROMS.CSLA.Library
|
||||
IVEDrillDownReadOnly ActiveParent { get; }
|
||||
FormatInfo ActiveFormat { get; }
|
||||
FormatInfo LocalFormat { get; }
|
||||
string SearchDVPath { get; }
|
||||
string SearchPath { get; }
|
||||
string ToString();
|
||||
ConfigDynamicTypeDescriptor MyConfig { get; }
|
||||
//IVEDrillDown Get();
|
||||
|
Loading…
x
Reference in New Issue
Block a user