Class OpenPatricianScene
- java.lang.Object
-
- ch.sahits.game.openpatrician.javafx.OpenPatricianScene
-
- Direct Known Subclasses:
BaseStartupScene
,InGameOptionsScene
,MainGameScene
,NewGameScene
public class OpenPatricianScene extends java.lang.Object
The open patrician scene stores the dimensions of the scene. Thereby the dimensions of the stage can be bound the scene and the scene can react on size changes.- Author:
- Andi Hotz, (c) Sahits GmbH, 2013 Created on Jul 20, 2013
-
-
Field Summary
Fields Modifier and Type Field Description private javafx.scene.layout.Region
root
-
Constructor Summary
Constructors Constructor Description OpenPatricianScene(javafx.scene.layout.Region root)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
heightChange(double oldHeight, double newHeigth)
Method that is called when the height of the scene changes.private void
registerSizeChanges()
void
widthChange(double oldWidth, double newWidth)
Method that is called when the width of the scene changes.
-
-
-
Method Detail
-
registerSizeChanges
private void registerSizeChanges()
-
heightChange
public void heightChange(double oldHeight, double newHeigth)
Method that is called when the height of the scene changes. Subclasses that need to be aware of size changes should override this method.- Parameters:
oldHeight
- old height of the scenenewHeigth
- new height of the scene
-
widthChange
public void widthChange(double oldWidth, double newWidth)
Method that is called when the width of the scene changes. Subclasses that need to be aware of size changes should override this method.- Parameters:
oldWidth
- old width of the scenenewWidth
- new width of the scene
-
-