[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gzz-commits] gzz ./TODO gzz/modules/pp2/PPCanvasNode.java gz...
From: |
Tuomas J. Lukka |
Subject: |
[Gzz-commits] gzz ./TODO gzz/modules/pp2/PPCanvasNode.java gz... |
Date: |
Wed, 05 Feb 2003 15:21:05 -0500 |
CVSROOT: /cvsroot/gzz
Module name: gzz
Changes by: Tuomas J. Lukka <address@hidden> 03/02/05 15:21:05
Modified files:
. : TODO
gzz/modules/pp2: PPCanvasNode.java
gzz/view/buoy : BuoyAdaptor.java BuoyViewNodeType.java
CellBuoyViewNodeType.java
Log message:
API change: sizes for buoys
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/TODO.diff?tr1=1.562&tr2=1.563&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/modules/pp2/PPCanvasNode.java.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/buoy/BuoyAdaptor.java.diff?tr1=1.6&tr2=1.7&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/buoy/BuoyViewNodeType.java.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/buoy/CellBuoyViewNodeType.java.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
Patches:
Index: gzz/TODO
diff -u gzz/TODO:1.562 gzz/TODO:1.563
--- gzz/TODO:1.562 Wed Feb 5 13:31:01 2003
+++ gzz/TODO Wed Feb 5 15:21:04 2003
@@ -16,7 +16,6 @@
HT03 deadline:
tjl:
- the great buoy redesign
- - nadir box size; box size tests
- make pagespan nodes show just the span, when
shown as buoys!
- make buoys return the anchor
Index: gzz/gzz/modules/pp2/PPCanvasNode.java
diff -u gzz/gzz/modules/pp2/PPCanvasNode.java:1.4
gzz/gzz/modules/pp2/PPCanvasNode.java:1.5
--- gzz/gzz/modules/pp2/PPCanvasNode.java:1.4 Wed Feb 5 10:02:38 2003
+++ gzz/gzz/modules/pp2/PPCanvasNode.java Wed Feb 5 15:21:05 2003
@@ -33,7 +33,7 @@
/** XXX
*/
public class PPCanvasNode implements CellBuoyViewNodeType {
-private static final String rcsid = "$Id: PPCanvasNode.java,v 1.4 2003/02/05
15:02:38 mudyc Exp $";
+private static final String rcsid = "$Id: PPCanvasNode.java,v 1.5 2003/02/05
20:21:05 tjl Exp $";
public static boolean dbg = false;
private static void pa(String s) { System.out.println("PPCanvasNode:"+s); }
@@ -69,7 +69,14 @@
return true;
}
- public void renderBuoy(VobScene vs, int into, Cell c, Object content) {
+ public Object getSize(Cell c, Object content, float[] wh) {
+ wh[0] = 200;
+ wh[1] = 200;
+ return null;
+ }
+
+ public void renderBuoy(VobScene vs, int into, Cell c, Object content,
+ Object cachedSize) {
pa("Tee poiju!!!");
vs.activate(into);
Index: gzz/gzz/view/buoy/BuoyAdaptor.java
diff -u gzz/gzz/view/buoy/BuoyAdaptor.java:1.6
gzz/gzz/view/buoy/BuoyAdaptor.java:1.7
--- gzz/gzz/view/buoy/BuoyAdaptor.java:1.6 Tue Feb 4 16:16:31 2003
+++ gzz/gzz/view/buoy/BuoyAdaptor.java Wed Feb 5 15:21:05 2003
@@ -35,11 +35,20 @@
// Implement BuoyViewNodeType
+ public Object getSize(Object linkId, Object anchor, float[] wh) {
+ if(anchor instanceof Cell) {
+ Cell c = (Cell)anchor;
+ return getNode(c).getSize(c, null, wh);
+ }
+ throw new Error("Unknown anchor!");
+ }
+
+
public void renderBuoy(VobScene vs, int into,
- Object linkId, Object anchor) {
+ Object linkId, Object anchor, Object cachedSize) {
if(anchor instanceof Cell) {
Cell c = (Cell)anchor;
- getNode(c).renderBuoy(vs, into, c, null);
+ getNode(c).renderBuoy(vs, into, c, null, cachedSize);
return;
}
throw new Error("Unknown anchor!");
Index: gzz/gzz/view/buoy/BuoyViewNodeType.java
diff -u gzz/gzz/view/buoy/BuoyViewNodeType.java:1.4
gzz/gzz/view/buoy/BuoyViewNodeType.java:1.5
--- gzz/gzz/view/buoy/BuoyViewNodeType.java:1.4 Tue Feb 4 10:09:51 2003
+++ gzz/gzz/view/buoy/BuoyViewNodeType.java Wed Feb 5 15:21:05 2003
@@ -6,10 +6,18 @@
/** An interface representing a single node of the buoy view.
*/
public interface BuoyViewNodeType {
+
+ /** Get the ideal size for this buoy.
+ * @return An object that, if passed to renderBuoy, may help
+ * performance a little.
+ */
+ Object getSize(Object linkId, Object anchor, float[] wh);
+
/** Render portion of the view relevant to linkId and anchor
* into the given box. This should not have any side effects.
*/
- void renderBuoy(VobScene vs, int into, Object linkId, Object anchor);
+ void renderBuoy(VobScene vs, int into, Object linkId, Object anchor,
+ Object cachedSize);
/** Focus was set to the buoy -- create an object that knows
* the user interface and motion in that space.
Index: gzz/gzz/view/buoy/CellBuoyViewNodeType.java
diff -u gzz/gzz/view/buoy/CellBuoyViewNodeType.java:1.1
gzz/gzz/view/buoy/CellBuoyViewNodeType.java:1.2
--- gzz/gzz/view/buoy/CellBuoyViewNodeType.java:1.1 Mon Feb 3 01:57:50 2003
+++ gzz/gzz/view/buoy/CellBuoyViewNodeType.java Wed Feb 5 15:21:05 2003
@@ -13,11 +13,19 @@
/** True if this view "owns" a certain cell.
*/
boolean ownsCell(Cell c);
+
+ /** Get the ideal size for this buoy.
+ * @return An object that, if passed to renderBuoy, may help
+ * performance a little.
+ */
+ Object getSize(Cell c, Object content, float[] wh);
+
/** Render this view centered on a given cell.
* @param content If not null, an object describing the part of content
* that the view should be centered on. Can be
ignored.
*/
- void renderBuoy(VobScene vs, int into, Cell c, Object content);
+ void renderBuoy(VobScene vs, int into, Cell c, Object content,
+ Object cachedSize);
BuoyViewMainNode createMainNode(Cell c, Object content, CellPlacementHook
hook);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gzz-commits] gzz ./TODO gzz/modules/pp2/PPCanvasNode.java gz...,
Tuomas J. Lukka <=