
	import java.awt.*;
	import java.awt.event.*;

	public class Garage extends Frame implements ActionListener
	{
		Button b;
		Dia d;

		public Garage(String caption)
		{
			super(caption);
			init();
		}

		void init()
		{
			d = new Dia(this, "look for a part");

			setSize(200,200);
			add(b = new Button("look for a part"));
			b.addActionListener(this);

			setVisible(true);
		}

		public void actionPerformed (ActionEvent event)
		{
			Object source = event.getSource();
			if ( source == b)
				{
					d.show();
					if (d.OK)
					{
						setLayout(new GridLayout(0,1));
						add (new Label(d.car_name));
						add (new Label(d.part_name));
						add (new Label(Integer.toString(d.part_serial_number)));
						add (new Label(Integer.toString(d.amuont)));
						add (new Label(Integer.toString(d.price)));
						setVisible(true);
					}
				}
		}

		public static void main(String[] args)
		{
			Garage g = new Garage(" Garage appliction");
		}

	}
