def onAssetActivated(self,evt):
   self.theSelectedIdx = evt.GetIndex()
   headAsset = self.GetItemText(self.theSelectedIdx)
   headAdornment = self.GetItem(self.theSelectedIdx,1)
   headNav = self.GetItem(self.theSelectedIdx,2)
   headNry = self.GetItem(self.theSelectedIdx,3)
   headRole = self.GetItem(self.theSelectedIdx,4)
   tailRole = self.GetItem(self.theSelectedIdx,5)
   tailNry = self.GetItem(self.theSelectedIdx,6)
   tailNav = self.GetItem(self.theSelectedIdx,7)
   tailAdornment = self.GetItem(self.theSelectedIdx,8)
   tailAsset = self.GetItem(self.theSelectedIdx,9)
    
   dlg = PatternStructureDialog(self,headAsset,headAdornment.GetText(),headNav.GetText(),headNry.GetText(),headRole.GetText(),tailRole.GetText(),tailNry.GetText(),tailNav.GetText(),tailAdornment.GetText(),tailAsset.GetText())
   if (dlg.ShowModal() == armid.PATTERNSTRUCTURE_BUTTONCOMMIT_ID):
     self.SetStringItem(self.theSelectedIdx,0,dlg.headAsset())
     self.SetStringItem(self.theSelectedIdx,1,dlg.headAdornment())
     self.SetStringItem(self.theSelectedIdx,2,dlg.headNavigation())
     self.SetStringItem(self.theSelectedIdx,3,dlg.headMultiplicity())
     self.SetStringItem(self.theSelectedIdx,4,dlg.headRole())
     self.SetStringItem(self.theSelectedIdx,5,dlg.tailRole())
     self.SetStringItem(self.theSelectedIdx,6,dlg.tailMultiplicity())
     self.SetStringItem(self.theSelectedIdx,7,dlg.tailNavigation())
     self.SetStringItem(self.theSelectedIdx,8,dlg.tailAdornment())
     self.SetStringItem(self.theSelectedIdx,9,dlg.tailAsset())
Esempio n. 2
0
 def onAddAssociation(self, evt):
     dlg = PatternStructureDialog(self)
     if (dlg.ShowModal() == PATTERNSTRUCTURE_BUTTONCOMMIT_ID):
         self.theSelectedIdx = self.GetItemCount()
         self.InsertStringItem(self.theSelectedIdx, dlg.headAsset())
         self.SetStringItem(self.theSelectedIdx, 1, dlg.headAdornment())
         self.SetStringItem(self.theSelectedIdx, 2, dlg.headNavigation())
         self.SetStringItem(self.theSelectedIdx, 3, dlg.headMultiplicity())
         self.SetStringItem(self.theSelectedIdx, 4, dlg.headRole())
         self.SetStringItem(self.theSelectedIdx, 5, dlg.tailRole())
         self.SetStringItem(self.theSelectedIdx, 6, dlg.tailMultiplicity())
         self.SetStringItem(self.theSelectedIdx, 7, dlg.tailNavigation())
         self.SetStringItem(self.theSelectedIdx, 8, dlg.tailAdornment())
         self.SetStringItem(self.theSelectedIdx, 9, dlg.tailAsset())
 def onAddAssociation(self,evt):
   dlg = PatternStructureDialog(self)
   if (dlg.ShowModal() == armid.PATTERNSTRUCTURE_BUTTONCOMMIT_ID):
     self.theSelectedIdx = self.GetItemCount()
     self.InsertStringItem(self.theSelectedIdx,dlg.headAsset())
     self.SetStringItem(self.theSelectedIdx,1,dlg.headAdornment())
     self.SetStringItem(self.theSelectedIdx,2,dlg.headNavigation())
     self.SetStringItem(self.theSelectedIdx,3,dlg.headMultiplicity())
     self.SetStringItem(self.theSelectedIdx,4,dlg.headRole())
     self.SetStringItem(self.theSelectedIdx,5,dlg.tailRole())
     self.SetStringItem(self.theSelectedIdx,6,dlg.tailMultiplicity())
     self.SetStringItem(self.theSelectedIdx,7,dlg.tailNavigation())
     self.SetStringItem(self.theSelectedIdx,8,dlg.tailAdornment())
     self.SetStringItem(self.theSelectedIdx,9,dlg.tailAsset())
Esempio n. 4
0
    def onAssetActivated(self, evt):
        self.theSelectedIdx = evt.GetIndex()
        headAsset = self.GetItemText(self.theSelectedIdx)
        headAdornment = self.GetItem(self.theSelectedIdx, 1)
        headNav = self.GetItem(self.theSelectedIdx, 2)
        headNry = self.GetItem(self.theSelectedIdx, 3)
        headRole = self.GetItem(self.theSelectedIdx, 4)
        tailRole = self.GetItem(self.theSelectedIdx, 5)
        tailNry = self.GetItem(self.theSelectedIdx, 6)
        tailNav = self.GetItem(self.theSelectedIdx, 7)
        tailAdornment = self.GetItem(self.theSelectedIdx, 8)
        tailAsset = self.GetItem(self.theSelectedIdx, 9)

        dlg = PatternStructureDialog(self, headAsset, headAdornment.GetText(),
                                     headNav.GetText(), headNry.GetText(),
                                     headRole.GetText(), tailRole.GetText(),
                                     tailNry.GetText(), tailNav.GetText(),
                                     tailAdornment.GetText(),
                                     tailAsset.GetText())
        if (dlg.ShowModal() == PATTERNSTRUCTURE_BUTTONCOMMIT_ID):
            self.SetStringItem(self.theSelectedIdx, 0, dlg.headAsset())
            self.SetStringItem(self.theSelectedIdx, 1, dlg.headAdornment())
            self.SetStringItem(self.theSelectedIdx, 2, dlg.headNavigation())
            self.SetStringItem(self.theSelectedIdx, 3, dlg.headMultiplicity())
            self.SetStringItem(self.theSelectedIdx, 4, dlg.headRole())
            self.SetStringItem(self.theSelectedIdx, 5, dlg.tailRole())
            self.SetStringItem(self.theSelectedIdx, 6, dlg.tailMultiplicity())
            self.SetStringItem(self.theSelectedIdx, 7, dlg.tailNavigation())
            self.SetStringItem(self.theSelectedIdx, 8, dlg.tailAdornment())
            self.SetStringItem(self.theSelectedIdx, 9, dlg.tailAsset())