I am looking at MainViewController.java in the MovieTrackerProject. Some of the methods, such as menuActionSaveAs contain the following line:
Window mainWindow = movieWatchListView.getScene().getWindow();
What does this line do?
This line would retrieve the window that the movieWatchListView is associated with. It gets the scene that the movieWatchListView is a part of and then gets the window that holds that scene. Therefore, mainWindow would now represent the main window of the software. This would be helpful if you wanted to somehow reference that window.
I was confused by this as well, so I asked Dr. Stonedahl. Right now, I have Window mainWindow = displayLesson in use.obtainScene().getWindow(); in my app, the displayLesson is where the cards are displayed.