| 65 exit(-1); |
67 exit(-1); |
| 66 } |
68 } |
| 67 } |
69 } |
| 68 |
70 |
| 69 static UiObject* create_window(const char *title, void *window_data, bool simple) { |
71 static UiObject* create_window(const char *title, void *window_data, bool simple) { |
| 70 CxMempool *mp = cxMempoolCreateSimple(256); |
72 UiObject *obj = uic_object_new_toplevel(); |
| 71 const CxAllocator *a = mp->allocator; |
|
| 72 UiObject *obj = cxCalloc(a, 1, sizeof(UiObject)); |
|
| 73 obj->ctx = uic_context(obj, mp); |
|
| 74 obj->window = window_data; |
73 obj->window = window_data; |
| 75 |
74 |
| 76 HWND hwnd = CreateWindowEx( |
75 HWND hwnd = CreateWindowEx( |
| 77 0, |
76 0, |
| 78 L"UiMainWindow", |
77 L"UiMainWindow", |