Static setVisible JFrame
I'm trying to create a title screen for a game. Everything has gone fine thus far, except the fact that this JFrame refuses to close. I'm using a JButton in a different JPanel in a different JFrame. I get the error "Cannot make a static reference to the non-static method setVisible(boolean) from the type 
 Window"



    package ZombieFunTimeGo;
    
    import javax.swing.Icon;
    import javax.swing.ImageIcon;
    import javax.swing.JButton;
    import javax.swing.JFrame;
    import javax.swing.JProgressBar;
    
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    
    public class SuperZombieFunTimeGo extends JFrame{
    	
    	private TitleScreen ts;
    	boolean visible;
    	
    	public SuperZombieFunTimeGo() {
    		add(new TitleScreen());
    		setDefaultCloseOperation(EXIT_ON_CLOSE);
    		setSize(1280, 720);
    		ts = new TitleScreen();
    		Container pane = getContentPane();
    		pane.add(ts);
    		setContentPane(ts);
    		setLocationRelativeTo(null);
    		setTitle("Super Zombie Fun Time Go!");
    		setResizable(false);
    		setVisible(true);
    		
    	}
    	public void pullThePlug() {
            WindowEvent wev = new WindowEvent(this, WindowEvent.WINDOW_CLOSING);
            Toolkit.getDefaultToolkit().getSystemEventQueue().postEvent(wev);
    }
    
    	
    	public static void main(String[] args) {
    		new SuperZombieFunTimeGo();
    	}
    }


Static setVisible JFrame
===

I'm trying to create a title screen for a game. Everything has gone fine thus far, except the fact that this JFrame refuses to close. I'm using a JButton in a different JPanel in a different JFrame. I get the error "Cannot make a static reference to the non-static method setVisible(boolean) from the type 
 Window"



    package ZombieFunTimeGo;
    
    import javax.swing.Icon;
    import javax.swing.ImageIcon;
    import javax.swing.JButton;
    import javax.swing.JFrame;
    import javax.swing.JProgressBar;
    
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    
    public class SuperZombieFunTimeGo extends JFrame{
    	
    	private TitleScreen ts;
    	boolean visible;
    	
    	public SuperZombieFunTimeGo() {
    		add(new TitleScreen());
    		setDefaultCloseOperation(EXIT_ON_CLOSE);
    		setSize(1280, 720);
    		ts = new TitleScreen();
    		Container pane = getContentPane();
    		pane.add(ts);
    		setContentPane(ts);
    		setLocationRelativeTo(null);
    		setTitle("Super Zombie Fun Time Go!");
    		setResizable(false);
    		setVisible(true);
    		
    	}
    	public void pullThePlug() {
            WindowEvent wev = new WindowEvent(this, WindowEvent.WINDOW_CLOSING);
            Toolkit.getDefaultToolkit().getSystemEventQueue().postEvent(wev);
    }
    
    	
    	public static void main(String[] args) {
    		new SuperZombieFunTimeGo();
    	}
    }

