From c4f4288d2f2b9023505c7cbc74caa5df3b7b9320 Mon Sep 17 00:00:00 2001 From: eg3p Date: Thu, 19 Aug 2004 19:51:21 +0000 Subject: [PATCH] eliminated some unnecessary comments i had left in there --- source/org/thdl/tib/input/DuffPane.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/source/org/thdl/tib/input/DuffPane.java b/source/org/thdl/tib/input/DuffPane.java index 5a9775a..9da603f 100644 --- a/source/org/thdl/tib/input/DuffPane.java +++ b/source/org/thdl/tib/input/DuffPane.java @@ -1023,8 +1023,11 @@ public class DuffPane extends TibetanPane implements FocusListener { public void paste() { /* added by AM. If we are pasting over selected text, such text such be substituted by the text to be pasted. */ - deleteCurrentSelection(); - paste(getSelectionStart()); + // Respect setEditable(boolean): + if (this.isEditable()) { + deleteCurrentSelection(); + paste(getSelectionStart()); + } } /** @@ -1047,10 +1050,9 @@ public void paste(int offset) try { Transferable contents = rtfBoard.getContents(this); - + if (contents.isDataFlavorSupported(rtfFlavor)) { - InputStream in = (InputStream)contents.getTransferData(rtfFlavor); int p1 = offset;