From 348e1876d25320e6480f2795c9388b2bc080c743 Mon Sep 17 00:00:00 2001 From: Benji Dial Date: Sun, 7 Mar 2021 12:16:12 -0500 Subject: text entry, with cursor, but no keyboard --- src/user/raleigh/window.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/user/raleigh/window.cpp') diff --git a/src/user/raleigh/window.cpp b/src/user/raleigh/window.cpp index 41eb9ce..c23545b 100644 --- a/src/user/raleigh/window.cpp +++ b/src/user/raleigh/window.cpp @@ -3,6 +3,8 @@ #include #include +#include + namespace raleigh { window::window(widget &root, _pixel_t bg_color, bool (*on_close)(window &)) : handle(0), size(root.size), root(root), bg_color(bg_color), @@ -11,7 +13,7 @@ namespace raleigh { root.window_offset = coord(0, 0); root.notify_window_change(); - pixbuf = (_pixel_t *)get_block(size.x * size.y * sizeof(_pixel_t)); + pixbuf = new _pixel_t[size.x * size.y]; if (!pixbuf) show_error_and_quitf("Failed to create %d byte pixel buffer\nfor requested %dx%d pixel window.", size.x * size.y * sizeof(_pixel_t), size.x, size.y); -- cgit v1.2.3