progressBar = new JProgressBar();
progressBar = new ProgressBar(progressModel);
	public ResultsPanel(SearchModel searchModel, ExamplesModel examplesModel) {		super();				if (searchModel == null)			throw new NullPointerException("searchModel == null");		this.searchModel = searchModel;		searchModel.addObserver(this);				if (examplesModel == null)			throw new NullPointerException("searchModel == null");				setLayout(new BorderLayout());		setBorder(BorderFactory.createLoweredBevelBorder());				FlowLayout fl = new ScrollFlowLayout();		fl.setAlignment(FlowLayout.LEFT);		resultsPanel = new ScrollPanel();		resultsPanel.setLayout(fl);		resultsPanel.setOpaque(false);		resultsPanel.setBorder(BorderFactory.createEmptyBorder(0,15,0,0));				JScrollPane resultsScrollPane = new JScrollPane(resultsPanel);		resultsScrollPane.setBorder(null);		resultsScrollPane.getViewport().setBackground(Color.WHITE);			fullSizePanel = new ImagePanel();		fullSizePanel.setBackground(Color.WHITE);		fullSizePanel.setLayout(new BoxLayout(fullSizePanel, BoxLayout.Y_AXIS));		fullSizePanel.setCursor(new Cursor(Cursor.HAND_CURSOR));		fullSizePanel.setToolTipText("Click here to go back");		fullSizePanel.add(Box.createGlue());		fsProgressBar = new JProgressBar();		fsProgressBar.setIndeterminate(true);		fsProgressBar.setAlignmentX(JPanel.CENTER_ALIGNMENT);		fsProgressBar.setAlignmentY(JPanel.CENTER_ALIGNMENT);		fsProgressBar.setString("loading image ...");		fsProgressBar.setStringPainted(true);		fsProgressBar.setMaximumSize			(new Dimension(300,fsProgressBar.getPreferredSize().height));		fsProgressBar.setVisible(false);		fullSizePanel.add(fsProgressBar);		fullSizePanel.add(Box.createGlue());				cardLayout = new CardLayout();		centerPanel = new JPanel(cardLayout);		centerPanel.add(resultsScrollPane, "results");		centerPanel.add(fullSizePanel, "fullSize");		add(centerPanel);				fullSizePanel.addMouseListener(new MouseAdapter() {			public void mouseClicked(MouseEvent e) {				cardLayout.show(centerPanel, "results");			}		});				progressBar = new JProgressBar();		progressBar.setStringPainted(true);		progressBar.setVisible(false);		add(progressBar, BorderLayout.SOUTH);				selectedImgModel = new ImageModel();		fullSizeImgModel = new ImageModel();		fullSizeImgModel.addObserver(this);		sidebar = new SideBar(selectedImgModel, fullSizeImgModel, examplesModel);		add(sidebar, BorderLayout.WEST);	}