# Path: draobpilc/lib/gpaste_client.py
# class Action():
# class Target():
#     REPLACE = 'REPLACE'
#     REMOVE = 'REMOVE'
#     ALL = 'ALL'
#     POSITION = 'POSITION'
# SCHEMA_ID = common.SETTINGS[common.GPASTE_SCHEMA_ID]
#     SETTINGS = utils.get_settings(SCHEMA_ID)
# def get_prop(property_name):
# def connect(name, callback):
# def disconnect(signal_match):
# def add(text):
# def get_history():
# def get_raw_history():
# def get_element(uuid):
# def get_raw_element(uuid):
# def select(uuid):
# def get_element_kind(uuid):
# def replace(uuid, contents):
# def delete(uuid):
# def list_histories():
# def get_history_size(name):
# def get_history_name():
# def switch_history(name):
# def delete_history(name):
# def empty_history(name):
# def track(t):
# def reexecute():
# def backup_history(history_name, backup_name):


from gi.repository import Gtk
from draobpilc.lib import gpaste_client
        self._entry.connect('activate', self._on_entry_activate)
        self._entry.props.buffer.connect('notify::text',
            lambda b, p: self._hide_error()
        )

        content_area = self.get_content_area()
        content_area.add(label_overlay)
        content_area.add(self._entry)
        content_area.show_all()

        self.connect('response', self._on_response)

    def _on_entry_activate(self, entry):
        self._backup_history(self._entry.get_text()) and self.destroy()

    def _on_response(self, dialog, response_id):
        if response_id == Gtk.ResponseType.OK:
            self._backup_history(self._entry.get_text()) and self.destroy()
        else:
            self.destroy()

    def _hide_error(self):
        self._error_label.hide()
        self._label.set_opacity(1)

    def _show_error(self):
        self._label.set_opacity(0)
        self._error_label.show()

    def _backup_history(self, name):

# Path: draobpilc/lib/gpaste_client.py
# class Action():
# class Target():
#     REPLACE = 'REPLACE'
#     REMOVE = 'REMOVE'
#     ALL = 'ALL'
#     POSITION = 'POSITION'
# SCHEMA_ID = common.SETTINGS[common.GPASTE_SCHEMA_ID]
#     SETTINGS = utils.get_settings(SCHEMA_ID)
# def get_prop(property_name):
# def connect(name, callback):
# def disconnect(signal_match):
# def add(text):
# def get_history():
# def get_raw_history():
# def get_element(uuid):
# def get_raw_element(uuid):
# def select(uuid):
# def get_element_kind(uuid):
# def replace(uuid, contents):
# def delete(uuid):
# def list_histories():
# def get_history_size(name):
# def get_history_name():
# def switch_history(name):
# def delete_history(name):
# def empty_history(name):
# def track(t):
# def reexecute():
# def backup_history(history_name, backup_name):


# Path: draobpilc/widgets/backup_history_dialog.py
from gi.repository import Gtk
from draobpilc.lib import gpaste_client

        self._entry.connect('activate', self._on_entry_activate)
        self._entry.props.buffer.connect('notify::text',
            lambda b, p: self._hide_error()
        )

        content_area = self.get_content_area()
        content_area.add(label_overlay)
        content_area.add(self._entry)
        content_area.show_all()

        self.connect('response', self._on_response)

    def _on_entry_activate(self, entry):
        self._backup_history(self._entry.get_text()) and self.destroy()

    def _on_response(self, dialog, response_id):
        if response_id == Gtk.ResponseType.OK:
            self._backup_history(self._entry.get_text()) and self.destroy()
        else:
            self.destroy()

    def _hide_error(self):
        self._error_label.hide()
        self._label.set_opacity(1)

    def _show_error(self):
        self._label.set_opacity(0)
        self._error_label.show()

    def _backup_history(self, name):

        histories = gpaste_client.list_histories()