Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package fr.jejeoh.launcher.minecraft;
- import javax.swing.JFrame;
- import javax.swing.UIManager;
- import javax.swing.UnsupportedLookAndFeelException;
- import fr.theshark34.swinger.Swinger;
- import fr.theshark34.swinger.util.WindowMover;
- @SuppressWarnings("serial")
- public class LauncherFrame extends JFrame {
- private static LauncherFrame instance;
- private LauncherPanel launcherPanel;
- public LauncherFrame() {
- this.setTitle("OLTANAMC");
- this.setSize(975, 625);
- this.setDefaultCloseOperation(EXIT_ON_CLOSE);
- this.setLocationRelativeTo(null);
- this.setUndecorated(true);
- this.setIconImage(Swinger.getResource("icon.png"));
- this.setContentPane(launcherPanel = new LauncherPanel());
- WindowMover mover = new WindowMover(this);
- this.addMouseListener(mover);
- this.addMouseMotionListener(mover);
- this.setVisible(true);
- }
- public static void main(String[] args) {
- try {
- UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
- } catch (ClassNotFoundException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (InstantiationException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (IllegalAccessException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (UnsupportedLookAndFeelException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- //stop gros truc
- Swinger.setResourcePath("/fr/jejeoh/launcher/minecraft/resources/");
- instance = new LauncherFrame();
- }
- public static LauncherFrame getInstance() {
- return instance;
- }
- public LauncherPanel getLauncherPanel() {
- return this.launcherPanel;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement