예제 #1
0
 public void MouseClick(Intergraph.GTechnology.API.IGTMapWindow MapWindow, Intergraph.GTechnology.API.IGTPoint UserPoint, int Button, int ShiftState, Intergraph.GTechnology.API.IGTDDCKeyObjects LocatedObjects, Intergraph.GTechnology.API.IGTPlacementTechniqueEventMode EventMode)
 {
     try
     {
         string ownerFeatureName = m_ActiveMapWindow.DetailID == 0 ? "Pad" : "Vault";
         if (0 == LocatedObjects.Count)
         {
             // If there are no linear objects in the collection, then there is nothing to use to create
             // the new geometry.  Beep to notify the user and display a message in the status bar.
             System.Console.Beep();
             m_GTApplication.SetStatusBarText(GTStatusPanelConstants.gtaspcMessage, "There is no existing " + ownerFeatureName + " symbol feature to Own the Primary switch gear which is to be placed adjacent to it.");
         }
         else
         {
             if (1 == LocatedObjects.Count && ((LocatedObjects[0].FNO == 108 && LocatedObjects[0].ComponentViewName == "V_PAD_S" && m_ActiveMapWindow.DetailID == 0) || (LocatedObjects[0].FNO == 117 && LocatedObjects[0].ComponentViewName == "V_VAULT_DP" && m_GTApplication.ActiveMapWindow.DetailID != 0)))
             {
                 // There is exactly 1 linear object in the collection, so use it to creat the new geometry.
                 this.PlacePrimarySwitchGear(LocatedObjects[0]);
                 MapWindow.HighlightedObjects.Clear();
             }
             else
             {
                 m_GTApplication.SetStatusBarText(GTStatusPanelConstants.gtaspcMessage, "Please identify only " + ownerFeatureName + " symbol feature to Own the Primary switch gear which is to be placed adjacent to it.");
             }
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
예제 #2
0
 public virtual void MouseClick(Intergraph.GTechnology.API.IGTMapWindow MapWindow, Intergraph.GTechnology.API.IGTPoint UserPoint, int Button, int ShiftState, Intergraph.GTechnology.API.IGTDDCKeyObjects LocatedObjects, Intergraph.GTechnology.API.IGTPlacementTechniqueEventMode EventMode)
 {
     if (!bSilent)
     {
         m_PTHelper.MouseClick(UserPoint, Button, ShiftState);
     }
 }
예제 #3
0
 public virtual void MouseDblClick(Intergraph.GTechnology.API.IGTMapWindow MapWindow, Intergraph.GTechnology.API.IGTPoint UserPoint, int ShiftState, Intergraph.GTechnology.API.IGTDDCKeyObjects LocatedObjects)
 {
     if (!bSilent)
     {
         if (m_PTHelper != null)
         {
             m_PTHelper.MouseDblClick(UserPoint, ShiftState);
         }
         if (m_gtApplication != null)
         {
             m_gtApplication.SetStatusBarText(GTStatusPanelConstants.gtaspcMessage, "Please click on related Primary Conductor feature.");
         }
     }
 }
예제 #4
0
 public void KeyUp(Intergraph.GTechnology.API.IGTMapWindow MapWindow, int KeyCode, int ShiftState, Intergraph.GTechnology.API.IGTPlacementTechniqueEventMode EventMode)
 {
     //throw new Exception("The method or operation is not implemented.");
 }
예제 #5
0
 public void MouseMove(Intergraph.GTechnology.API.IGTMapWindow MapWindow, Intergraph.GTechnology.API.IGTPoint UserPoint, int ShiftState, Intergraph.GTechnology.API.IGTDDCKeyObjects LocatedObjects, Intergraph.GTechnology.API.IGTPlacementTechniqueEventMode EventMode)
 {
 }
예제 #6
0
 public void KeyUp(Intergraph.GTechnology.API.IGTMapWindow MapWindow, int KeyCode, int ShiftState, Intergraph.GTechnology.API.IGTPlacementTechniqueEventMode EventMode)
 {
 }