import java.applet.Applet; import java.awt.*; import java.awt.event.*; import java.io.*; import java.net.*; public class Tripsuklient extends Applet{ public void init(){ setLayout(new BorderLayout()); add("Center", new Tripsupaneel()); } public static void main(String argumendid[]){ Frame f=new Frame("Tripsuraam"); f.add("Center", new Tripsupaneel()); f.setSize(300, 300); f.setVisible(true); } } class Tripsupaneel extends Panel{ Button nupp[]=new Button[10]; String omanimi; TextArea suhtlus=new TextArea("",3, 60,TextArea.SCROLLBARS_VERTICAL_ONLY); public Tripsupaneel(){ setLayout(new BorderLayout()); add("North", suhtlus); Panel nupupaneel=new Panel(); nupupaneel.setLayout(new GridLayout(3, 3)); for(int i=0; i<9; i++){ nupp[i]=new Button(" "); nupupaneel.add(nupp[i]); } add("Center", nupupaneel); nupp[9]=new Button("Stopp"); add("South", nupp[9]); seaNupud(false); TripsukliendiLoim vahendaja=new TripsukliendiLoim(this); // vahendaja.start(); } void seaNupud(boolean kasutatav){ if(!kasutatav)for(int i=0; i