Esempio n. 1
0
    def __on_copy_available(self, value):
        """ Change states of cut and copy action """

        cut_action = Pireal.get_action("cut_action")
        cut_action.setEnabled(value)
        copy_action = Pireal.get_action("copy_action")
        copy_action.setEnabled(value)
Esempio n. 2
0
    def __on_copy_available(self, value):
        """ Change states of cut and copy action """

        cut_action = Pireal.get_action("cut_action")
        cut_action.setEnabled(value)
        copy_action = Pireal.get_action("copy_action")
        copy_action.setEnabled(value)
Esempio n. 3
0
 def new_query(self, filename=''):
     pireal = Pireal.get_service("pireal")
     db_container = self.get_active_db()
     db_container.new_query(filename)
     # Enable editor actions
     # FIXME: refactoring
     pireal.set_enabled_query_actions(True)
     zoom_in_action = Pireal.get_action("zoom_in")
     zoom_in_action.setEnabled(True)
     zoom_out_action = Pireal.get_action("zoom_out")
     zoom_out_action.setEnabled(True)
     paste_action = Pireal.get_action("paste_action")
     paste_action.setEnabled(True)
     comment_action = Pireal.get_action("comment")
     comment_action.setEnabled(True)
     uncomment_action = Pireal.get_action("uncomment")
     uncomment_action.setEnabled(True)
Esempio n. 4
0
 def new_query(self, filename=''):
     pireal = Pireal.get_service("pireal")
     db_container = self.get_active_db()
     db_container.new_query(filename)
     # Enable editor actions
     # FIXME: refactoring
     pireal.set_enabled_query_actions(True)
     zoom_in_action = Pireal.get_action("zoom_in")
     zoom_in_action.setEnabled(True)
     zoom_out_action = Pireal.get_action("zoom_out")
     zoom_out_action.setEnabled(True)
     paste_action = Pireal.get_action("paste_action")
     paste_action.setEnabled(True)
     comment_action = Pireal.get_action("comment")
     comment_action.setEnabled(True)
     uncomment_action = Pireal.get_action("uncomment")
     uncomment_action.setEnabled(True)
     search_action = Pireal.get_action("search")
     search_action.setEnabled(True)