Esempio n. 1
0
 def _close(self, button_id=None):
     """Closes the actual confirmation dialogue represented by this
        instance.
     """
     if button_id is None:
         DialogueWindow._close(self, button_id)
         return
     if button_id not in self.button_ids:
         raise Exception("confirm dialogue '%s' does not contain a button with id %s" % (self.name, button_id))
     if self.keys is not None:
         SCREEN.type(self.keys[button_id])
         sleep(1)
     else:
         button = self.buttons[button_id]
         if isinstance(button, list):
             clickAny(button)
         else:
             SCREEN.click(button)
         sleep(1)
Esempio n. 2
0
 def _close(self, button_id = None):
     """Closes the actual confirmation dialogue represented by this
        instance.
     """
     if button_id is None:
         DialogueWindow._close(self, button_id)
         return
     if button_id not in self.button_ids:
         raise Exception("confirm dialogue '%s' does not contain a button with id %s" %
                 (self.name, button_id))
     if self.keys is not None:
         SCREEN.type(self.keys[button_id])
         sleep(1)
     else:
         button = self.buttons[button_id]
         if isinstance(button, list):
             clickAny(button)
         else:
             SCREEN.click(button)
         sleep(1)
Esempio n. 3
0
 def click(self, name):
     """Clicks the specified button.
     """
     i, match = self._button_matches[name]
     _LOGGER.info("%sclick '%s': %s", self._debugprefix, name, str(match))
     SCREEN.click(match, NO_MODIFIER)
Esempio n. 4
0
 def click(self, name):
     """Clicks the specified button.
     """
     i, match = self._button_matches[name]
     _LOGGER.info("%sclick '%s': %s", self._debugprefix, name, str(match))
     SCREEN.click(match, NO_MODIFIER)
Esempio n. 5
0
 def close(self):
     """Clicks on the close button in this window's title bar."""
     _LOGGER.debug('close window: %s', self.title)
     SCREEN.click(self.close_button)
Esempio n. 6
0
 def maximize(self):
     """Clicks on the maximize button in this window's title bar."""
     _LOGGER.debug('maximize window: %s', self.title)
     SCREEN.click(self.maximize_button)
Esempio n. 7
0
 def setFocus(self):
     """Clicks on the center of this window's title bar."""
     _LOGGER.debug('setFocus: %s', self.title)
     SCREEN.click(self.titlebar_region)
Esempio n. 8
0
 def close(self):
     """Clicks on the close button in this window's title bar."""
     _LOGGER.debug('close window: %s', self.title)
     SCREEN.click(self.close_button)
Esempio n. 9
0
 def maximize(self):
     """Clicks on the maximize button in this window's title bar."""
     _LOGGER.debug('maximize window: %s', self.title)
     SCREEN.click(self.maximize_button)
Esempio n. 10
0
 def setFocus(self):
     """Clicks on the center of this window's title bar."""
     _LOGGER.debug('setFocus: %s', self.title)
     SCREEN.click(self.titlebar_region)