startup changes
This commit is contained in:
parent
e2431666e1
commit
418952bd25
@ -1,3 +1,4 @@
|
|||||||
|
import haxe.MainLoop;
|
||||||
import kernel.Init;
|
import kernel.Init;
|
||||||
import lib.ui.Observable;
|
import lib.ui.Observable;
|
||||||
import lib.ui.TextElement;
|
import lib.ui.TextElement;
|
||||||
@ -11,20 +12,11 @@ class Startup {
|
|||||||
public static function main() {
|
public static function main() {
|
||||||
Init.initKernel();
|
Init.initKernel();
|
||||||
|
|
||||||
exampleUI();
|
MainLoop.add(() -> {
|
||||||
|
|
||||||
KernelEvents.instance.startEventLoop();
|
KernelEvents.instance.startEventLoop();
|
||||||
}
|
},0);
|
||||||
|
|
||||||
static function exampleProgramm() {
|
exampleUI();
|
||||||
var context = WindowManager.instance.createNewContext();
|
|
||||||
|
|
||||||
context.clickSignal.handle(data -> {
|
|
||||||
context.setCursorPos(data.pos.x,data.pos.y);
|
|
||||||
context.write("x");
|
|
||||||
});
|
|
||||||
|
|
||||||
context.write("Example programm");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static function exampleUI() {
|
static function exampleUI() {
|
||||||
|
Loading…
Reference in New Issue
Block a user