Exemplo n.º 1
0
    def __init__(self, parent, columns: List[TableModelColumn],
                 columns_movable, filtering_sorting):
        AttrsProtected.__init__(self)
        ColumnedItemModelMixin.__init__(self, parent, columns, columns_movable)
        QAbstractTableModel.__init__(self, parent)

        if filtering_sorting:
            self.enable_filter_proxy_model(self)
        self.data_lock = thread_utils.EnhRLock()
Exemplo n.º 2
0
 def __init__(self, tree_id: Optional[int]):
     AttrsProtected.__init__(self)
     Bip44Entry.__init__(self, tree_id=tree_id, id=None, parent=None)
     self.balance = 0
     self.received = 0
     self.name = ''
     self.last_scan_block_height = None
     self.db_fields.extend(('balance', 'received'))
     self.bip44_account = None
     self.__is_change = False
     self.set_attr_protection()
    def __init__(self, tree_id: Optional[int]):
        AttrsProtected.__init__(self)
        Bip44Entry.__init__(self, tree_id=tree_id, id=None, parent=None)
        self.balance = 0
        self.received = 0
        self.name = ''
        self.last_scan_block_height = None
        self.db_fields.extend(('balance', 'received'))
        self.bip44_account = None
        self.__is_change = False

        # timestamp of the last db-network balance consictency check
        self.last_balance_verify_ts = 0

        self.set_attr_protection()
Exemplo n.º 4
0
 def __init__(self, parent, columns: List[TableModelColumn],
              columns_movable, filtering_sorting):
     AttrsProtected.__init__(self)
     QAbstractItemModel.__init__(self, parent)
     self.parent_widget = parent
     self._columns = columns
     self._col_idx_by_name: Dict[str, int] = {}
     self._rebuild_column_index()
     self.view: Optional[QAbstractItemView] = None
     self.columns_movable = columns_movable
     self.initial_sorting_column_name = ''
     self.initial_sorting_order = Qt.AscendingOrder
     self.proxy_model: Optional[ColumnedSortFilterProxyModel] = None
     self.data_lock = thread_utils.EnhRLock()
     if filtering_sorting:
         self.enable_filter_proxy_model(self)
Exemplo n.º 5
0
 def __init__(self,
              tree_id: Optional[int],
              id: Optional[int],
              xpub: Optional[str],
              address_index: Optional[int],
              bip32_path: Optional[str]):
     AttrsProtected.__init__(self)
     Bip44Entry.__init__(self, tree_id=tree_id, id=id, parent=None, xpub=xpub, address_index=address_index,
                         bip32_path=bip32_path)
     self.balance: Optional[int] = 0
     self.received: Optional[int] = 0
     self.addresses: List[Bip44AddressType] = []
     self.status: int = 0  # 0: default, 1: force show (used when received = 0), 2: force hide (used when received > 0)
     self.view_fresh_addresses_count = 1  # how many unused addresses will be shown in GUI
     self.db_fields.extend(('balance', 'received', 'status'))
     self.set_attr_protection()
Exemplo n.º 6
0
 def __init__(self,
              name,
              caption,
              visible,
              initial_width: int = None,
              additional_attrs: Optional[List[str]] = None):
     AttrsProtected.__init__(self)
     self.name = name
     self.caption = caption
     self.visible = visible
     self.initial_width = initial_width
     self.visual_index = None
     if additional_attrs:
         for attr in additional_attrs:
             self.add_attribute(attr)
     self.def_width = None
     self.set_attr_protection()
Exemplo n.º 7
0
 def __init__(self):
     AttrsProtected.__init__(self)
     self.ident = None
     self.status = None
     self.protocol = None
     self.payee = None
     self.lastseen = None
     self.activeseconds = None
     self.lastpaidtime = None
     self.lastpaidblock = None
     self.ip = None
     self.db_id = None
     self.marker = None
     self.modified = False
     self.monitor_changes = False
     self.queue_position = None
     self.set_attr_protection()