//(c):Benja Fallenstein package gzz.view; import gzz.*; import gzz.vob.*; import java.awt.Dimension; /** An HBox that contains a cell, using a given CellView. */ public class CellHBox implements HBox { Cell cell; CellView view; ViewContext context; static Dimension dim = new Dimension(); public CellHBox(Cell cell, CellView view, ViewContext context) { this.cell = cell; this.view = view; this.context = context; } public float getWidth(float scale) { view.getDefaultSize(scale, dim); return dim.width; } public float getHeight(float scale) { view.getDefaultSize(scale, dim); return dim.height; } public float getDepth(float scale) { throw new UnsupportedOperationException("XXX"); } public Object getKey() { return cell; } public void place(VobScene vs, int coordsys, float scale) { view.place(cell, vs, coordsys, context, scale); } public void setPrev(HBox b) {} }