diff --git a/drongo b/drongo index 883b1c95..0002d6ba 160000 --- a/drongo +++ b/drongo @@ -1 +1 @@ -Subproject commit 883b1c95b4e8bd961fb07ff09327d9da4a5bcb9d +Subproject commit 0002d6bae69feb4a5195418ae99d520653c5e7dc diff --git a/src/main/java/com/sparrowwallet/sparrow/BaseController.java b/src/main/java/com/sparrowwallet/sparrow/BaseController.java index f7a14f2b..012b9c31 100644 --- a/src/main/java/com/sparrowwallet/sparrow/BaseController.java +++ b/src/main/java/com/sparrowwallet/sparrow/BaseController.java @@ -25,7 +25,7 @@ public abstract class BaseController { scriptArea.setMouseOverTextDelay(Duration.ofMillis(150)); scriptArea.addEventHandler(MouseOverTextEvent.MOUSE_OVER_TEXT_BEGIN, e -> { TwoDimensional.Position position = scriptArea.getParagraph(0).getStyleSpans().offsetToPosition(e.getCharacterIndex(), Backward); - if(position.getMajor() % 2 == 0) { + if(position.getMajor() % 2 == 0 && scriptArea.getScript().getChunks().size() > position.getMajor() / 2) { ScriptChunk hoverChunk = scriptArea.getScript().getChunks().get(position.getMajor()/2); if(!hoverChunk.isOpCode()) { Point2D pos = e.getScreenPosition(); diff --git a/src/main/java/com/sparrowwallet/sparrow/control/ScriptArea.java b/src/main/java/com/sparrowwallet/sparrow/control/ScriptArea.java index ff66766d..c140fab7 100644 --- a/src/main/java/com/sparrowwallet/sparrow/control/ScriptArea.java +++ b/src/main/java/com/sparrowwallet/sparrow/control/ScriptArea.java @@ -58,6 +58,8 @@ public class ScriptArea extends CodeArea { append("", "script-signature"); } else if(chunk.isPubKey()) { append("", "script-pubkey"); + } else if(chunk.isString()) { + append(chunk.toString(), "script-other"); } else if(chunk.isScript()) { Script nestedScript = chunk.getScript(); if (nestedScript.equals(redeemScript)) { diff --git a/src/main/java/com/sparrowwallet/sparrow/io/Hwi.java b/src/main/java/com/sparrowwallet/sparrow/io/Hwi.java index d017801a..7f073c21 100644 --- a/src/main/java/com/sparrowwallet/sparrow/io/Hwi.java +++ b/src/main/java/com/sparrowwallet/sparrow/io/Hwi.java @@ -278,7 +278,7 @@ public class Hwi { } catch(IOException e) { throw new SignTransactionException("Could not sign PSBT", e); } catch(PSBTParseException e) { - throw new SignTransactionException("Could not parse signed PSBT", e); + throw new SignTransactionException("Could not parse signed PSBT" + (e.getMessage() != null ? ": " + e.getMessage() : ""), e); } finally { isPromptActive = false; }