class App
protected init do end
+ # Starts the internal setup of graphical and other stuff
+ # Is called just before run
+ fun setup do end
+
# Main entry point of your application
fun run do end
# Helper function for logging warnings
fun log_warning(msg: String) do sys.stderr.write "{log_prefix} warn: {msg}\n"
+
+ # Main init method for graphical stuff
+ # Is called when display is ready so graphical assets
+ # can be loaded at this time.
+ fun window_created do end
+
+ # Called before destroying the window
+ fun window_closing do end
end
protected fun app: App do return once new App
+app.setup
app.run