1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 13:20:05 -04:00

Rename to Emigui

This commit is contained in:
Emil Ernerfeldt
2019-01-12 23:07:30 +01:00
parent 1e8a4d3906
commit 8963a99a09
26 changed files with 281 additions and 249 deletions

View File

@@ -3,7 +3,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<head>
<title>Emgui A experiment in an Immediate Mode GUI written in Rust</title>
<title>Emigui A experiment in an Immediate Mode GUI written in Rust</title>
<style>
html {
/* Remove touch delay: */
@@ -35,7 +35,7 @@
delete WebAssembly.instantiateStreaming;
</script>
<!-- this is the JS generated by the `wasm-bindgen` CLI tool -->
<script src="emgui_wasm.js"></script>
<script src="emigui_wasm.js"></script>
<script>
// we'll defer our execution until the wasm is ready to go
function wasm_loaded() {
@@ -44,16 +44,16 @@
}
// here we tell bindgen the path to the wasm file so it can start
// initialization and return to us a promise when it's done
wasm_bindgen("./emgui_wasm_bg.wasm")
wasm_bindgen("./emigui_wasm_bg.wasm")
.then(wasm_loaded)["catch"](console.error);
// ----------------------------------------------------------------------------
var g_webgl_painter = null;
function paint_gui(canvas, input) {
if (g_webgl_painter === null) {
g_webgl_painter = wasm_bindgen.new_webgl_painter("canvas");
g_webgl_painter = wasm_bindgen.new_webgl_gui("canvas");
}
wasm_bindgen.paint_webgl(g_webgl_painter, JSON.stringify(input));
wasm_bindgen.run_gui(g_webgl_painter, JSON.stringify(input));
}
// ----------------------------------------------------------------------------
var g_mouse_pos = { x: -1000.0, y: -1000.0 };