20 |
*/ |
*/ |
21 |
public abstract class ScrollblockCellLinker implements CellBuoyViewLinker { |
public abstract class ScrollblockCellLinker implements CellBuoyViewLinker { |
22 |
|
|
23 |
BuoyViewNodeType pageSpanNodeType; |
public BuoyViewNodeType pageSpanNodeType; |
24 |
|
|
25 |
public void doLinks(Cell c, VobScene vs, int cs, |
public void doLinks(Cell c, VobScene vs, int cs, |
26 |
BuoyViewNodeType cellNodeType, |
BuoyViewNodeType cellNodeType, |
42 |
} |
} |
43 |
} |
} |
44 |
|
|
|
PageSpanCellView pscv = new PageSpanCellView(); |
|
|
|
|
|
/** A dummy routine that makes an enfilade from a span. |
|
|
* It's not nice that this is needed... |
|
|
*/ |
|
|
private Enfilade1D makeEnf(Object a) { |
|
|
return gzz.media.impl.Enfilade1DImpl.theMaker.makeEnfilade( |
|
|
(Span)a); |
|
|
} |
|
|
|
|
|
public class PageSpanNodeType implements BuoyViewNodeType { |
|
|
public void renderBuoy(VobScene vs, int into, Object linkId, Object anchor) { |
|
|
// XXX!!!! |
|
|
// Irregu! |
|
|
// find edges of span |
|
|
// should place only that region surrounded by irregu |
|
|
PageSpan s = (PageSpan)anchor; |
|
|
ScrollBlock sb = s.getScrollBlock(); |
|
|
pscv.placeCentered(makeEnf(sb.getCurrent()), vs, into, s, |
|
|
.5f, 200); |
|
|
} |
|
|
public BuoyViewMainNode createMainNode(Object linkId, Object anchor, |
|
|
BuoyLinkListener l) { |
|
|
return new PageSpanMainNode((PageSpan)anchor, l); |
|
|
} |
|
|
} |
|
|
public class PageSpanMainNode implements BuoyViewMainNode { |
|
|
float x, y; |
|
|
ScrollBlock sb; |
|
|
BuoyLinkListener listener; |
|
|
|
|
|
public PageSpanMainNode(PageSpan sp, BuoyLinkListener listener) { |
|
|
this.listener = listener; |
|
|
this.sb = sp.getScrollBlock(); |
|
|
} |
|
|
|
|
|
public void renderMain(VobScene vs, int into) { |
|
|
} |
|
|
public void keystroke(String s) { |
|
|
} |
|
|
public boolean mouse(MouseEvent e, VobScene oldVobScene) { |
|
|
return false; |
|
|
} |
|
|
} |
|
|
|
|
45 |
// XXX Reverse links! Scrollblock to |
// XXX Reverse links! Scrollblock to |
46 |
} |
} |
47 |
|
|