import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

public class DisplayPanel extends JPanel
{
	private Image myImage;
	private JLabel myLabel;
	
	DisplayPanel(Image x)
	{
		super();
		myImage = x;
		setSize(myImage.getWidth(null),myImage.getHeight(null));
		myLabel = new JLabel (new ImageIcon(myImage));
		add(myLabel);

	}
	public void displayImage(Image x)
	{
		myImage = x;
		myLabel.setIcon (new ImageIcon (myImage));
	}
	
}
