summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorAudrius Meskauskas <audriusa@Bioinformatics.org>2006-04-13 16:49:16 +0000
committerAudrius Meskauskas <audriusa@Bioinformatics.org>2006-04-13 16:49:16 +0000
commit9c4ae63e42ba757e5480c3d8f5dbcaff12cdc5fc (patch)
tree307e3dad21276a264104a3e4106b5e5f4fed62fc /gnu
parentd107381ef7f6effe5f1968aa30f3de405b7bedde (diff)
downloadclasspath-9c4ae63e42ba757e5480c3d8f5dbcaff12cdc5fc.tar.gz
2006-04-13 Audrius Meskauskas <AudriusA@Bioinformatics.org>
* javax/swing/JTree.java (getPreferredSize): Return the cloned instance. * javax/swing/ViewportLayout.java (layoutContainer): Do not manage the view size and location if the view is in the scroll pane. Also manage size and location for Scrollable, if it is not in the scroll pane. * javax/swing/plaf/basic/BasicTreeUI.java, * javax/swing/tree/FixedHeightLayoutCache.java, * javax/swing/tree/VariableHeightLayoutCache.java: Rewritten. * gnu/javax/swing/tree/GnuPath.java: New file.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/javax/swing/tree/GnuPath.java65
1 files changed, 65 insertions, 0 deletions
diff --git a/gnu/javax/swing/tree/GnuPath.java b/gnu/javax/swing/tree/GnuPath.java
new file mode 100644
index 000000000..dd576e8d3
--- /dev/null
+++ b/gnu/javax/swing/tree/GnuPath.java
@@ -0,0 +1,65 @@
+/* GnuPath.java -- The extended version of TreePath
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package gnu.javax.swing.tree;
+
+import javax.swing.tree.TreePath;
+
+/**
+ * The tree path with additional data. Needed for the optimized tree drawing.
+ * Returned by layout caches.
+ *
+ * @author Audrius Meskauskas
+ */
+public class GnuPath extends TreePath
+{
+ /**
+ * The flag, marking the last visible child.
+ */
+ public boolean isLastChild;
+
+ /**
+ * Create a new path, specifying flag if this path is the path to the
+ * last visible child (needed for optimized tree drawing).
+ */
+ public GnuPath(Object[] path, boolean lastChild)
+ {
+ super(path);
+ isLastChild = lastChild;
+ }
+}