B2016-094: click in Tree View white space does not select tree node if step opened from Search
This commit is contained in:
parent
ccd4e4726f
commit
d16add0a0e
@ -3624,6 +3624,7 @@ namespace Volian.Controls.Library
|
|||||||
public void AdjustTree(ItemInfo selectedItem)
|
public void AdjustTree(ItemInfo selectedItem)
|
||||||
{
|
{
|
||||||
// start at the top parent and walk down the nodes to find child
|
// start at the top parent and walk down the nodes to find child
|
||||||
|
Console.WriteLine("VlnTreeview:AdjustTree");
|
||||||
VETreeNode node = FindNodeAndExpand(selectedItem);
|
VETreeNode node = FindNodeAndExpand(selectedItem);
|
||||||
if (node != null)
|
if (node != null)
|
||||||
{
|
{
|
||||||
@ -3697,7 +3698,14 @@ namespace Volian.Controls.Library
|
|||||||
}
|
}
|
||||||
public bool CompareVEObject(IVEDrillDownReadOnly obj1, IVEDrillDownReadOnly obj2)
|
public bool CompareVEObject(IVEDrillDownReadOnly obj1, IVEDrillDownReadOnly obj2)
|
||||||
{
|
{
|
||||||
if (obj1.GetType().Name != obj2.GetType().Name) return false;
|
if (obj1.GetType().Name != obj2.GetType().Name)
|
||||||
|
{
|
||||||
|
// see if both can be cast as ItemInfo, because 1st check may be comparing ItemInfo & ProcedureInfo and returns
|
||||||
|
// false even though they are same base object type (fixes bug B2016-094)
|
||||||
|
ItemInfo ii1 = obj1 as ItemInfo;
|
||||||
|
ItemInfo ii2 = obj2 as ItemInfo;
|
||||||
|
if (ii1 == null || ii2 == null) return false;
|
||||||
|
}
|
||||||
ItemInfo myItem = obj1 as ItemInfo;
|
ItemInfo myItem = obj1 as ItemInfo;
|
||||||
if (myItem != null)
|
if (myItem != null)
|
||||||
if (myItem.ItemID == ((ItemInfo)obj2).ItemID) return true;
|
if (myItem.ItemID == ((ItemInfo)obj2).ItemID) return true;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user