/// <summary> /// 开关柜管理 /// </summary> /// <param name="Sender"></param> /// <param name="e"></param> static void MI6_OnClick(object Sender, EventArgs e) { var ent = PublicMethod.Instance.GetObject(objectId, OpenMode.ForRead) as Entity; //如果是标注就跳过 if (ent is DBText || ent is MText) { return; } if (ent != null) { var g3eObject = new G3EObject(); if (false == DBEntityFinder.Instance.GetG3EIds(ent.ObjectId, ref g3eObject)) { return; } var ee = new selectEntityArgs { g3eObject = g3eObject, objId = ent.ObjectId }; if (KGGManager != null) { KGGManager(new object(), ee); } } }
static void MI8_OnClick(object sender, EventArgs e) { var g3eObject = new G3EObject(); if (DBEntityFinder.Instance.GetG3EIds(objectId, ref g3eObject)) { var ee = new selectEntityArgs { g3eObject = g3eObject, objId = objectId }; if (JLBManager != null) { JLBManager(new object(), ee); } } }
public static void AddOrRefreshConnectCtr(bool badd) { try { if (objectId != ObjectId.Null) { if (PublicMethod.Instance.lockFrameObjectID == objectId) { return; } var selectedEntity = PublicMethod.Instance.GetObject(objectId, OpenMode.ForRead) as Entity; if (selectedEntity == null) { return; } G3EObject g3eObject = null; if (false == DBEntityFinder.Instance.GetG3EIds(objectId, ref g3eObject)) { PublicMethod.Instance.ShowMessage("实体没有扩展属性!\n"); return; } var ee = new selectEntityArgs { g3eObject = g3eObject, objId = objectId, badd = badd //新建or更新面板 }; if (EntityConnectHandler != null) { EntityConnectHandler(new object(), ee); } } } catch (System.Exception ex) { PublicMethod.Instance.Editor.WriteMessageWithReturn(ex); } }