home *** CD-ROM | disk | FTP | other *** search
Java Source | 1997-07-03 | 600 b | 23 lines |
- package borland.samples.apps.chess.client;
-
- import java.awt.*;
-
- public class EastPanel extends Panel {
- Component sibling;
- public EastPanel() {
-
- }
- public EastPanel(Component c) {
- sibling = c;
- }
- public void setSibling(Component sibling) {
- this.sibling = sibling;
- }
- public Dimension getPreferredSize() {
- int siblingHeight = 280;
- if (sibling != null)
- siblingHeight = sibling.getPreferredSize().height;
- //System.out.println("east Panel prefered size = 280," +( siblingHeight + 60));
- return new Dimension(280, siblingHeight + 60);
- }
- }