/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package menu;

import java.awt.*;
import javax.swing.*;
import javax.swing.border.*;
import javax.swing.border.Border.*;
import DrawTop.*;

public class GuidancePanel extends JPanel{
    static JPanel glassPane=ObjectTable.getGlassPane("MessageField");
    static JLabel viewLabel=new JLabel();
    static JLabel settingsLabel=new JLabel();
    Rectangle guidancePanelBounds;
    
    public GuidancePanel(){
		this.guidancePanelBounds=DrawParameters.GuidancePanelBounds;
        Border raisedetched = BorderFactory.createEtchedBorder(EtchedBorder.RAISED);
        FlowLayout flowLayout=new FlowLayout(FlowLayout.LEADING, 0, 0);
        this.setLayout(flowLayout);
        JPanel basePanel=new JPanel();
        basePanel.setLayout(flowLayout);
        viewLabel.setBorder(raisedetched);
        viewLabel.setForeground(Color.BLUE);
        viewLabel.setBackground(Color.WHITE);
        viewLabel.setOpaque(true);
        Font font=MenuConstants.MenuItemFont;
        viewLabel.setFont(font);
        viewLabel.setPreferredSize(new Dimension(180,22));
        basePanel.add(viewLabel);

        settingsLabel.setBorder(raisedetched);
        settingsLabel.setForeground(Color.BLUE);
        settingsLabel.setBackground(Color.WHITE);
        settingsLabel.setOpaque(true);
        settingsLabel.setFont(font);
        settingsLabel.setPreferredSize(new Dimension(1000,22));
        basePanel.add(settingsLabel);
        this.add(basePanel);

        this.setBounds(guidancePanelBounds);
        glassPane.add(this);
        glassPane.setVisible(true);
        this.setVisible(true);
    }
    public static void showViewMessage(String message){
        glassPane.setVisible(false);
        viewLabel.setText(message);
        glassPane.setVisible(true);
        
    }
    public static void showSettingsMessage(String message){
        glassPane.setVisible(false);
        settingsLabel.setText(message);
        glassPane.setVisible(true);
    }
}
