コード例 #1
0
ファイル: clue_view.py プロジェクト: cloew/PyMine
class ClueView(GridSquareFrame):
    """ Represents the Graphical view of the Drone """
    TRANSPARENCY = 100

    def __init__(self, clue, parent=None):
        """ Initialize the drone view """
        GridSquareFrame.__init__(self, parent)
        self.clue = clue
        
        self.adjacencyClue = AdjacencyClueView(clue.adjacencyClue, clue.fragilityClue, parent=self)
        self.adjacencyClue.move(45, 5)
        
        self.warningClue = WeaponCautionClueView(clue.weaponCautionClue, parent=self)
        self.warningClue.move(10, 10)
        
    def updateView(self):
        """ Update the View """
        self.adjacencyClue.updateView()
        self.warningClue.updateView()
        
    def representNewClue(self, clue):
        """ Represent a New Clue """
        self.clue = clue
        self.adjacencyClue.adjacencyClue = clue.adjacencyClue
        self.adjacencyClue.fragilityClue = clue.fragilityClue
        self.warningClue.clue = clue
コード例 #2
0
ファイル: clue_view.py プロジェクト: scloew/PyMine
class ClueView(GridSquareFrame):
    """ Represents the Graphical view of the Drone """
    TRANSPARENCY = 100

    def __init__(self, clue, parent=None):
        """ Initialize the drone view """
        GridSquareFrame.__init__(self, parent)
        self.clue = clue

        self.adjacencyClue = AdjacencyClueView(clue.adjacencyClue,
                                               clue.fragilityClue,
                                               parent=self)
        self.adjacencyClue.move(45, 5)

        self.warningClue = WeaponCautionClueView(clue.weaponCautionClue,
                                                 parent=self)
        self.warningClue.move(10, 10)

    def updateView(self):
        """ Update the View """
        self.adjacencyClue.updateView()
        self.warningClue.updateView()

    def representNewClue(self, clue):
        """ Represent a New Clue """
        self.clue = clue
        self.adjacencyClue.adjacencyClue = clue.adjacencyClue
        self.adjacencyClue.fragilityClue = clue.fragilityClue
        self.warningClue.clue = clue
コード例 #3
0
ファイル: clue_view.py プロジェクト: scloew/PyMine
    def __init__(self, clue, parent=None):
        """ Initialize the drone view """
        GridSquareFrame.__init__(self, parent)
        self.clue = clue

        self.adjacencyClue = AdjacencyClueView(clue.adjacencyClue,
                                               clue.fragilityClue,
                                               parent=self)
        self.adjacencyClue.move(45, 5)

        self.warningClue = WeaponCautionClueView(clue.weaponCautionClue,
                                                 parent=self)
        self.warningClue.move(10, 10)
コード例 #4
0
ファイル: clue_view.py プロジェクト: cloew/PyMine
 def __init__(self, clue, parent=None):
     """ Initialize the drone view """
     GridSquareFrame.__init__(self, parent)
     self.clue = clue
     
     self.adjacencyClue = AdjacencyClueView(clue.adjacencyClue, clue.fragilityClue, parent=self)
     self.adjacencyClue.move(45, 5)
     
     self.warningClue = WeaponCautionClueView(clue.weaponCautionClue, parent=self)
     self.warningClue.move(10, 10)