Skip to content

Commit

Permalink
Update the visibility of the "Locate collateral" button after editing
Browse files Browse the repository at this point in the history
collateral address, path or transaction hash fields.
  • Loading branch information
Bertrand256 committed Dec 15, 2018
1 parent 2a4bef0 commit aa7b61c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/masternode_details.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,23 +289,32 @@ def on_edtProtocolVersion_textEdited(self, text):
@pyqtSlot(str)
def on_edtCollateralAddress_textEdited(self, text):
if self.masternode and not self.updating_ui:
update_ui = ((not text) != (not self.masternode.collateralAddress))
self.set_modified()
self.masternode.collateralAddress = text.strip()
self.name_modified.emit(text)
if update_ui:
self.update_ui()

@pyqtSlot(str)
def on_edtCollateralPath_textEdited(self, text):
if self.masternode and not self.updating_ui:
update_ui = ((not text) != (not self.masternode.collateralBip32Path))
self.set_modified()
self.masternode.collateralBip32Path = text.strip()
self.name_modified.emit(text)
if update_ui:
self.update_ui()

@pyqtSlot(str)
def on_edtCollateralTxHash_textEdited(self, text):
if self.masternode and not self.updating_ui:
update_ui = ((not text) != (not self.masternode.collateralTx))
self.set_modified()
self.masternode.collateralTx = text.strip()
self.name_modified.emit(text)
if update_ui:
self.update_ui()

@pyqtSlot(str)
def on_edtCollateralTxIndex_textEdited(self, text):
Expand Down

0 comments on commit aa7b61c

Please sign in to comment.