ableos/sysdata/libraries/sunset_proto/src/lib.hb

36 lines
624 B
Plaintext
Raw Normal View History

2024-11-10 12:57:48 -06:00
.{math: .{Vec2}} := @use("../../stn/src/lib.hb");
.{Surface} := @use("../../render/src/lib.hb")
$BUFFER := "sunset\0"
client := @use("./client.hb")
server := @use("./server.hb")
message := @use("./message.hb")
WindowID := uint
MessageKind := uint
WindowMessage := packed struct {
kind: MessageKind,
id: WindowID,
length: uint,
data_ptr: ^u8,
// need to replace this with a buffer id
callback: ^u8,
}
WindowProps := struct {
position: Vec2(uint),
dimensions: Vec2(uint),
title: ^u8,
}
WindowWrapper := struct {
id: WindowID,
props: WindowProps,
}
Window := struct {
surface: Surface,
props: WindowProps,
}