55 lines
1.1 KiB
Plaintext
55 lines
1.1 KiB
Plaintext
// Generated using `moon info`, DON'T EDIT IT
|
|
package "demo/moonetui-demo/lib"
|
|
|
|
import {
|
|
"moonbitstack/moonetui/app",
|
|
"moonbitstack/moonetui/driver",
|
|
"moonbitstack/moonetui/widget",
|
|
}
|
|
|
|
// Values
|
|
pub fn[D : @driver.Driver] build(D) -> (@app.App[D], Model)
|
|
|
|
pub fn[D : @driver.Driver] frame(@app.App[D], Model) -> Bool raise
|
|
|
|
// Errors
|
|
|
|
// Types and methods
|
|
pub struct Model {
|
|
systems : Array[Sys]
|
|
order : Array[Int32]
|
|
mut sort : Int32
|
|
mut seed : Int32
|
|
mut tick : Int32
|
|
mut paused : Bool
|
|
mut dark : Bool
|
|
mut fuel : Double
|
|
fleet : Array[Double]
|
|
table : @widget.StatefulTable
|
|
state : @widget.TableState
|
|
detail : @widget.Static
|
|
chart : @widget.Chart
|
|
spark : @widget.Sparkline
|
|
g_load : @widget.Gauge
|
|
g_power : @widget.Gauge
|
|
g_fuel : @widget.Gauge
|
|
g_temp : @widget.Gauge
|
|
header : @widget.Header
|
|
log : Array[String]
|
|
}
|
|
pub fn Model::selected(Self) -> Int32
|
|
pub fn Model::sort_name(Self) -> String
|
|
pub fn Model::step(Self) -> Unit
|
|
|
|
pub struct Sys {
|
|
name : String
|
|
base : Int32
|
|
mut load : Int32
|
|
mut temp : Int32
|
|
hist : Array[Double]
|
|
}
|
|
|
|
// Type aliases
|
|
|
|
// Traits
|