aboutsummaryrefslogtreecommitdiff
path: root/libjava/classpath/javax/swing/JTextArea.java
diff options
context:
space:
mode:
authorMark Wielaard <mark@gcc.gnu.org>2006-01-17 18:09:40 +0000
committerMark Wielaard <mark@gcc.gnu.org>2006-01-17 18:09:40 +0000
commit2127637945ea6b763966398130e0770fa993c860 (patch)
treec976ca91e3ef0bda3b34b37c0195145638d8d08e /libjava/classpath/javax/swing/JTextArea.java
parentbcb36c3e02e3bd2843aad1b9888513dfb5d6e337 (diff)
downloadgcc-2127637945ea6b763966398130e0770fa993c860.zip
gcc-2127637945ea6b763966398130e0770fa993c860.tar.gz
gcc-2127637945ea6b763966398130e0770fa993c860.tar.bz2
Imported GNU Classpath 0.20
Imported GNU Classpath 0.20 * Makefile.am (AM_CPPFLAGS): Add classpath/include. * java/nio/charset/spi/CharsetProvider.java: New override file. * java/security/Security.java: Likewise. * sources.am: Regenerated. * Makefile.in: Likewise. From-SVN: r109831
Diffstat (limited to 'libjava/classpath/javax/swing/JTextArea.java')
-rw-r--r--libjava/classpath/javax/swing/JTextArea.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/libjava/classpath/javax/swing/JTextArea.java b/libjava/classpath/javax/swing/JTextArea.java
index 2fa185b..9b50feb 100644
--- a/libjava/classpath/javax/swing/JTextArea.java
+++ b/libjava/classpath/javax/swing/JTextArea.java
@@ -217,7 +217,11 @@ public class JTextArea extends JTextComponent
public JTextArea(Document doc, String text, int rows, int columns)
{
setDocument(doc == null ? createDefaultModel() : doc);
- setText(text);
+ // Only explicitly setText() when there is actual text since
+ // setText() might be overridden and not expected to be called
+ // from the constructor (as in JEdit).
+ if (text != null)
+ setText(text);
setRows(rows);
setColumns(columns);
}