def _process_file(self): """ Takes a screen shot for the next DemoFile object in the queue. """ while len(self.demo_files) > 0: demo_file = self.demo_files.pop(0) try: self.ui = demo_file.demo.edit_facets() self.ui.control.bounds = (500, 500, 1280, 720) self.demo_file = demo_file self.path = demo_file.path image_file = file_with_ext(demo_file.path, "png") self.image = image_file if exists(image_file) else None break except: pass
def _snap_set(self): """ Handles the 'snap' event being fired. """ self.image = self.ui.control.image self.image.save(file_with_ext(self.demo_file.path, "png"))
def _selected_set(self): """ Handles the 'selected' facet being changed. """ do_later(self.owner.set, selected=self.find(file_with_ext(self.selected.name, "py")))