We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 06aec42 commit 5bcdcadCopy full SHA for 5bcdcad
src/core/Windows.zig
@@ -234,9 +234,10 @@ fn initWindow(
234
.from_windows_hwnd = &native.surface_descriptor_from_hwnd,
235
} };
236
237
- const context: Context = .{ .core = core, .window_id = window_id };
+ const context = try core.allocator.create(Context);
238
+ context.* = .{ .core = core, .window_id = window_id };
239
- _ = w.SetWindowLongPtrW(native_window, w.GWLP_USERDATA, @bitCast(@intFromPtr(&context)));
240
+ _ = w.SetWindowLongPtrW(native_window, w.GWLP_USERDATA, @bitCast(@intFromPtr(context)));
241
242
restoreWindowPosition(core, window_id);
243
0 commit comments