You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Start.java 1.1KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /*
  2. * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
  3. * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Main.java to edit this template
  4. */
  5. package mvcgrafik;
  6. import javax.swing.JOptionPane;
  7. import javax.swing.UIManager;
  8. import mvcgrafik.controller.GrafikController;
  9. import mvcgrafik.model.GrafikModel;
  10. import mvcgrafik.view.GrafikFrame;
  11. import mvcgrafik.view.GrafikView;
  12. /**
  13. * Builder Class
  14. * @author le
  15. */
  16. public class Start
  17. {
  18. public Start()
  19. {
  20. GrafikModel model = new GrafikModel();
  21. GrafikFrame frm = new GrafikFrame();
  22. GrafikView view = frm.getgZeichenflaeche();
  23. view.setModel(model);
  24. GrafikController controller = new GrafikController(view, model);
  25. controller.registerEvents();
  26. frm.setVisible(true);
  27. }
  28. /**
  29. * @param args the command line arguments
  30. */
  31. public static void main(String[] args)
  32. {
  33. try
  34. {
  35. UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
  36. }
  37. catch (Exception ex)
  38. {
  39. JOptionPane.showMessageDialog(null, ex.toString());
  40. }
  41. new Start();
  42. }
  43. }