How to use the aeidon.util.affirm function in aeidon

To help you get started, we’ve selected a few aeidon examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github otsaloma / gaupol / gaupol / actions / edit.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(page is not None)
        aeidon.util.affirm(page.project.subtitles)
        aeidon.util.affirm(selected_rows)
github otsaloma / gaupol / gaupol / actions / edit.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(page is not None)
        row, col = page.view.get_focus()
        aeidon.util.affirm(not None in (row, col))
        column = page.view.get_column(col)
        renderer = column.get_cells()[0]
        aeidon.util.affirm(renderer.props.mode ==
                           Gtk.CellRendererMode.EDITABLE)
github otsaloma / gaupol / gaupol / actions / tools.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(aeidon.SpellChecker.available())
github otsaloma / gaupol / gaupol / actions / file.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(page is not None)
github otsaloma / gaupol / gaupol / actions / search.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        """Raise :exc:`aeidon.AffirmationError` if action cannot be done."""
        aeidon.util.affirm(page is not None)
github otsaloma / gaupol / gaupol / actions / file.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(page is not None)
github otsaloma / gaupol / gaupol / actions / audio.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(application.player is not None)
        aeidon.util.affirm(application.player.ready)
github otsaloma / gaupol / gaupol / actions / format.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        """Raise :exc:`aeidon.AffirmationError` if action cannot be done."""
        aeidon.util.affirm(page is not None)
        aeidon.util.affirm(selected_rows)
        col = page.view.get_focus()[1]
        aeidon.util.affirm(col is not None)
        aeidon.util.affirm(page.view.is_text_column(col))
github otsaloma / gaupol / gaupol / actions / projects.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(page is not None)
        index = application.pages.index(page) + 1
        aeidon.util.affirm(index in range(len(application.pages)))
github otsaloma / gaupol / gaupol / actions / edit.py View on Github external
def _affirm_doable(self, application, page, selected_rows):
        aeidon.util.affirm(page is not None)
        aeidon.util.affirm(page.project.can_undo())