mirror of
https://github.com/sparrowwallet/sparrow.git
synced 2024-12-25 05:06:45 +00:00
show returned errors on hwi enumerate
This commit is contained in:
parent
44ac7f3c0e
commit
d8b7938a63
2 changed files with 15 additions and 1 deletions
|
@ -73,7 +73,12 @@ public class DevicePane extends TitledDescriptionPane {
|
||||||
createSetPassphraseButton();
|
createSetPassphraseButton();
|
||||||
createImportButton();
|
createImportButton();
|
||||||
|
|
||||||
if (device.getNeedsPinSent() != null && device.getNeedsPinSent()) {
|
if(device.getError() != null) {
|
||||||
|
setError("Error", device.getError());
|
||||||
|
Platform.runLater(() -> {
|
||||||
|
setExpanded(true);
|
||||||
|
});
|
||||||
|
} else if(device.getNeedsPinSent() != null && device.getNeedsPinSent()) {
|
||||||
unlockButton.setVisible(true);
|
unlockButton.setVisible(true);
|
||||||
} else if(device.getNeedsPassphraseSent() != null && device.getNeedsPassphraseSent()) {
|
} else if(device.getNeedsPassphraseSent() != null && device.getNeedsPassphraseSent()) {
|
||||||
setPassphraseButton.setVisible(true);
|
setPassphraseButton.setVisible(true);
|
||||||
|
|
|
@ -11,6 +11,7 @@ public class Device {
|
||||||
private Boolean needsPinSent;
|
private Boolean needsPinSent;
|
||||||
private Boolean needsPassphraseSent;
|
private Boolean needsPassphraseSent;
|
||||||
private String fingerprint;
|
private String fingerprint;
|
||||||
|
private String error;
|
||||||
|
|
||||||
public String getType() {
|
public String getType() {
|
||||||
return type;
|
return type;
|
||||||
|
@ -60,6 +61,14 @@ public class Device {
|
||||||
this.fingerprint = fingerprint;
|
this.fingerprint = fingerprint;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getError() {
|
||||||
|
return error;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setError(String error) {
|
||||||
|
this.error = error;
|
||||||
|
}
|
||||||
|
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return getModel() + ":" + getPath();
|
return getModel() + ":" + getPath();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue