SudokuFX
Loading...
Searching...
No Matches
fr.softsf.sudokufx.view.CrashScreenView Class Reference

View class for the crash screen without business logic. More...

+ Inheritance diagram for fr.softsf.sudokufx.view.CrashScreenView:
+ Collaboration diagram for fr.softsf.sudokufx.view.CrashScreenView:

Public Member Functions

void openingMainStage (ISplashScreenView iSplashScreenView)
 Opens the main stage and handles the transition from splash screen to crash screen.
 

Static Public Attributes

static final double CRASHSCREEN_STAGE_RATIO = .8
 

Private Member Functions

void closeButtonClick ()
 Handles the close button click event.
 
void createSVG (final Region region, final String path, final double width, final double height, final double offsetX, final double offsetY)
 Creates an SVG shape and applies it to a Region.
 
void fadeIn (final Node node)
 Applies a fade-in effect to the given node.
 
void hidecrashscreen ()
 Hides and closes the crash screen stage.
 
void initialize ()
 Initializes the crash screen components.
 
void resetButtonClick ()
 Handles the reset button click event.
 
void setCrashscreenvboxTophboxLogosudosvg ()
 Sets up the SVG logo for the crash screen.
 
void showcrashscreen ()
 Shows the crash screen stage.
 

Private Attributes

Button buttonClose
 
Button buttonReset
 
double crashScreenFontSize
 
final Stage crashscreenStage = new Stage()
 
VBox crashscreenvbox
 
Label crashscreenvboxBottomhboxVersionlabel
 
Label crashscreenvboxBottomhboxYearlabel
 
HBox crashscreenvboxCenterhboxHbox
 
Label crashscreenvboxCenterhboxLabel
 
Label crashscreenvboxCenterhboxLabel2
 
Label crashscreenvboxTophboxNamelabel
 
Region crashscreenvboxTophboxRegionsudosvg
 
final DropShadow dropShadow = new DropShadow()
 
ISplashScreenView iSplashScreenView
 
final Stage primaryStage = new Stage()
 

Static Private Attributes

static final double CRASHSCREEN_FONT_RATIO = 0.02
 
static final double CRASHSCREEN_SIZE_RATIO = 0.7
 
static final double FADE_IN_IN_SECONDS_AFTER_SPLASHSCREEN = 0.5
 
static final IFileSystem I_FILE_SYSTEM = new FileSystemManager()
 
static final IOsFolder I_OS_FOLDER_FACTORY = new OsFoldersConfig().iOsFolderFactory()
 
static final Logger LOG = LoggerFactory.getLogger(CrashScreenView.class)
 
static final double SVG_STROKE_DIVISOR = 17.0
 

Detailed Description

View class for the crash screen without business logic.

This class is responsible for displaying and managing the crash screen UI.

Line="200" is excluded from Checkstyle's LineLength check (see checkstyle-suppressions.xml).

Member Function Documentation

◆ closeButtonClick()

void fr.softsf.sudokufx.view.CrashScreenView.closeButtonClick ( )
private

Handles the close button click event.

Logs the action and exits the application.

+ Here is the call graph for this function:

◆ createSVG()

void fr.softsf.sudokufx.view.CrashScreenView.createSVG ( final Region region,
final String path,
final double width,
final double height,
final double offsetX,
final double offsetY )
private

Creates an SVG shape and applies it to a Region.

Parameters
regionThe Region to apply the SVG shape to
pathThe SVG path data
widthThe width of the SVG
heightThe height of the SVG
offsetXThe X offset of the SVG
offsetYThe Y offset of the SVG

◆ fadeIn()

void fr.softsf.sudokufx.view.CrashScreenView.fadeIn ( final Node node)
private

Applies a fade-in effect to the given node.

Parameters
nodeThe node to apply the fade-in effect to
+ Here is the call graph for this function:

◆ hidecrashscreen()

void fr.softsf.sudokufx.view.CrashScreenView.hidecrashscreen ( )
private

Hides and closes the crash screen stage.

◆ initialize()

void fr.softsf.sudokufx.view.CrashScreenView.initialize ( )
private

Initializes the crash screen components.

This method is automatically called by JavaFX after loading the FXML.

+ Here is the call graph for this function:

◆ openingMainStage()

void fr.softsf.sudokufx.view.CrashScreenView.openingMainStage ( ISplashScreenView iSplashScreenView)

Opens the main stage and handles the transition from splash screen to crash screen.

Parameters
iSplashScreenViewThe splash screen view interface

Implements fr.softsf.sudokufx.common.interfaces.IMainView.

+ Here is the call graph for this function:

◆ resetButtonClick()

void fr.softsf.sudokufx.view.CrashScreenView.resetButtonClick ( )
private

Handles the reset button click event.

Attempts to delete the application data directory and then exits the application.

+ Here is the call graph for this function:

◆ setCrashscreenvboxTophboxLogosudosvg()

void fr.softsf.sudokufx.view.CrashScreenView.setCrashscreenvboxTophboxLogosudosvg ( )
private

Sets up the SVG logo for the crash screen.

+ Here is the call graph for this function:

◆ showcrashscreen()

void fr.softsf.sudokufx.view.CrashScreenView.showcrashscreen ( )
private

Shows the crash screen stage.

Member Data Documentation

◆ buttonClose

Button fr.softsf.sudokufx.view.CrashScreenView.buttonClose
private

◆ buttonReset

Button fr.softsf.sudokufx.view.CrashScreenView.buttonReset
private

◆ CRASHSCREEN_FONT_RATIO

final double fr.softsf.sudokufx.view.CrashScreenView.CRASHSCREEN_FONT_RATIO = 0.02
staticprivate

◆ CRASHSCREEN_SIZE_RATIO

final double fr.softsf.sudokufx.view.CrashScreenView.CRASHSCREEN_SIZE_RATIO = 0.7
staticprivate

◆ CRASHSCREEN_STAGE_RATIO

final double fr.softsf.sudokufx.view.CrashScreenView.CRASHSCREEN_STAGE_RATIO = .8
static

◆ crashScreenFontSize

double fr.softsf.sudokufx.view.CrashScreenView.crashScreenFontSize
private

◆ crashscreenStage

final Stage fr.softsf.sudokufx.view.CrashScreenView.crashscreenStage = new Stage()
private

◆ crashscreenvbox

VBox fr.softsf.sudokufx.view.CrashScreenView.crashscreenvbox
private

◆ crashscreenvboxBottomhboxVersionlabel

Label fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxBottomhboxVersionlabel
private

◆ crashscreenvboxBottomhboxYearlabel

Label fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxBottomhboxYearlabel
private

◆ crashscreenvboxCenterhboxHbox

HBox fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxCenterhboxHbox
private

◆ crashscreenvboxCenterhboxLabel

Label fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxCenterhboxLabel
private

◆ crashscreenvboxCenterhboxLabel2

Label fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxCenterhboxLabel2
private

◆ crashscreenvboxTophboxNamelabel

Label fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxTophboxNamelabel
private

◆ crashscreenvboxTophboxRegionsudosvg

Region fr.softsf.sudokufx.view.CrashScreenView.crashscreenvboxTophboxRegionsudosvg
private

◆ dropShadow

final DropShadow fr.softsf.sudokufx.view.CrashScreenView.dropShadow = new DropShadow()
private

◆ FADE_IN_IN_SECONDS_AFTER_SPLASHSCREEN

final double fr.softsf.sudokufx.view.CrashScreenView.FADE_IN_IN_SECONDS_AFTER_SPLASHSCREEN = 0.5
staticprivate

◆ I_FILE_SYSTEM

final IFileSystem fr.softsf.sudokufx.view.CrashScreenView.I_FILE_SYSTEM = new FileSystemManager()
staticprivate

◆ I_OS_FOLDER_FACTORY

final IOsFolder fr.softsf.sudokufx.view.CrashScreenView.I_OS_FOLDER_FACTORY = new OsFoldersConfig().iOsFolderFactory()
staticprivate

◆ iSplashScreenView

ISplashScreenView fr.softsf.sudokufx.view.CrashScreenView.iSplashScreenView
private

◆ LOG

final Logger fr.softsf.sudokufx.view.CrashScreenView.LOG = LoggerFactory.getLogger(CrashScreenView.class)
staticprivate

◆ primaryStage

final Stage fr.softsf.sudokufx.view.CrashScreenView.primaryStage = new Stage()
private

◆ SVG_STROKE_DIVISOR

final double fr.softsf.sudokufx.view.CrashScreenView.SVG_STROKE_DIVISOR = 17.0
staticprivate

The documentation for this class was generated from the following file: