コード例 #1
0
 def Activated(self):
     self.selObj = None
     # get the selected object
     if Asm4.getSelectedContainer():
         self.selObj = Asm4.getSelectedContainer()
     elif Asm4.getSelectedLink():
         self.selObj = Asm4.getSelectedLink()
     # should be unnecessary, but who knows
     if self.selObj:
         # initialise the UI
         self.selectedPart.setText(self.selObj.Name)
         proposedName = self.selObj.Label+'_sym'
         self.mirroredPartName.setText(proposedName)
         self.UI.show()
コード例 #2
0
    def Activated(self):
        #global processedLinks
        # reset processed links cache
        processedLinks = []

        container = Asm4.getSelectedContainer()
        if not container:
            container = Asm4.checkModel()
        link = Asm4.getSelectedLink()
        if link:
            showChildLCSs(link, False, processedLinks)
        elif container:
            for objName in container.getSubObjects(1):
                showChildLCSs(container.getSubObject(objName, 1), False,
                              processedLinks)
コード例 #3
0
 def IsActive(self):
     # Will handle LCSs only for the Assembly4 model
     if Asm4.getSelectedContainer() or Asm4.checkModel(
     ) or Asm4.getSelectedLink():
         return True
     return False
コード例 #4
0
 def IsActive(self):
     # treats all container types : Body and Part
     if Asm4.getSelectedContainer() or Asm4.checkModel(
     ) or Asm4.getSelectedLink():
         return True
     return False
コード例 #5
0
 def IsActive(self):
     # this works on Parts and Bodies, and links to such
     if Asm4.getSelectedLink() or Asm4.getSelectedContainer():
         return(True)
     else:
         return(False)