}
use package core
-#private_file wasm :: package wasm_utils
+#local wasm :: package wasm_utils
// Testing running on the console
main :: (args: [] cstr) {
package app
-#private_file {
+#local {
events :: package js_events
gl :: package gl
gfx :: package immediate_mode
data := (#type [] u8).{ null, 0 };
}
-#private_file MAXIMUM_WINDOWS :: 128
+#local MAXIMUM_WINDOWS :: 128
Application_Window :: struct {
id: str;
}
@Relocate // This should be moved to somewhere else when the code base.
-#private_file {
+#local {
background_tile_texture : gfx.Texture;
draw_background_lines :: (width, height: f32, line_color := gfx.Color4.{0.2, 0.2, 0.2}, line_spacing := 32.0f) {
use package core
-#private_file {
+#local {
events :: package js_events
gl :: package gl
gfx :: package immediate_mode
use package core
-#private_file {
+#local {
app :: package app
ui :: package ui
gfx :: package immediate_mode
config :: package config
}
-#private {
+#package {
scrollable_region := ui.Scrollable_Region_State.{};
debug_log_y_offset := 0.0f;
ui.draw_text(r, conv.str_format(buf, "H: {}\n", alloc.heap.get_watermark()));
}
-#private_file log_buffer : struct {
+#local log_buffer : struct {
line_arena : alloc.arena.ArenaState;
lines : [..] str;
}
package editor
-#private_file {
+#local {
app :: package app
ui :: package ui
config :: package config
// The nitty-gritty of how everything is rendered.
//
-#private_file {
+#local {
__counter : i32;
msg_buffer : [512] u8;
}
}
-#private_file gfx :: package immediate_mode
+#local gfx :: package immediate_mode
#tag gfx.Color4.r, Slider_Float.{ 0, 1 }
#tag gfx.Color4.g, Slider_Float.{ 0, 1 }
#tag gfx.Color4.b, Slider_Float.{ 0, 1 }
package app
-#private_file {
+#local {
config :: package config
editor :: package editor
// Settings Window
//
-#private_file {
+#local {
window_id :: "settings"
window_name :: "Settings"
move_window_to_top(window_id);
}
-#private_file
+#local
settings_window_draw :: (_, win) => {
editor.editor_window_draw(^state.settings, win);
package app.storage
-#private_file {
+#local {
memory :: package core.memory
}
return buffer;
}
-#private_file {
+#local {
__local_storage_store :: (key: str, value: str) -> void #foreign "decompiler" "local_storage_store" ---
__local_storage_value_length :: (key: str) -> i32 #foreign "decompiler" "local_storage_value_length" ---
__local_storage_load :: (key: str, buffer: str) -> void #foreign "decompiler" "local_storage_load" ---
use package core
-#private_file {
+#local {
events :: package js_events
gl :: package gl
gfx :: package immediate_mode
package app
-#private_file {
+#local {
ui :: package ui
gfx :: package immediate_mode
config :: package config
}
-#private_file {
+#local {
WORKER_COUNT :: 4
MAXIMUM_WORK_UNITS :: 64
}
-// This should be #private at some point, however right now it cannot be as this symbol is needed to query the fonts to load.
+// This should be #package at some point, however right now it cannot be as this symbol is needed to query the fonts to load.
Fonts_Container :: struct {
FontData :: struct (index: i32, fnt_file: str, tex_file: str) {}
package feature.hex_viewer
-#private_file {
+#local {
app :: package app
editor :: package editor
ui :: package ui
}
// Should this be global? Or should each viewer window get their own?
-#private global_viewer_state := Hex_Viewer_State.{};
+#package global_viewer_state := Hex_Viewer_State.{};
hex_window: ^app.Application_Window;
package feature.text_editor
-#private_file {
+#local {
app :: package app
ui :: package ui
config :: package config
package feature.wasm
-#private_file {
+#local {
app :: package app
ui :: package ui
config :: package config
use package debug { debug_log }
}
-#private {
+#package {
wasm_state : WasmBinary;
wasm_sections : WasmSections;
-#private_file {
+#local {
events :: package js_events
config :: package config
app :: package app
package ui
-#private_file {
+#local {
iter :: package core.iter
config :: package config
package ui
-#private_file {
+#local {
map :: package core.map
editor :: package editor
}
use package core
-#private_file {
+#local {
ui :: package ui
gfx :: package immediate_mode
config :: package config