forked from FranciscoZacarias/Algorithm-Visualizer-JavaFX
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMain.java
More file actions
49 lines (41 loc) · 1.14 KB
/
Copy pathMain.java
File metadata and controls
49 lines (41 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package Main;
import Model.Grid;
import ViewController.Controller;
import ViewController.View;
import javafx.application.Application;
import javafx.stage.Stage;
/**
*
* @author frank
*/
public class Main extends Application
{
private final String APP_TITLE = "Algorithm Visualizer - Francisco Zacarias";
public static void main(String[] args)
{
launch(args);
}
@Override
public void start(Stage primaryStage) throws Exception
{
View app = createApp();
primaryStage.setScene(app.getScene());
primaryStage.setTitle(APP_TITLE);
primaryStage.show();
}
private View createApp()
{
// Create Model
Grid model = new Grid();
// Create View
View view = new View(model);
// Create Controller
Controller controller = new Controller(model, view);
return view;
}
}