From 76e39eac8cee2175ec62a191f7c91ca53857e80c Mon Sep 17 00:00:00 2001 From: Benji Dial Date: Fri, 5 Mar 2021 18:07:48 -0500 Subject: more raleigh, including button and vbox widgets --- src/user/raleigh/util.cpp | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) (limited to 'src/user/raleigh/util.cpp') diff --git a/src/user/raleigh/util.cpp b/src/user/raleigh/util.cpp index 958897b..db0982b 100644 --- a/src/user/raleigh/util.cpp +++ b/src/user/raleigh/util.cpp @@ -1,6 +1,22 @@ #include +#include +#include -coord::coord(uint32_t x, uint32_t y) - : x(x), y(y) {} -coord::coord() - : x(0), y(0) {} \ No newline at end of file +namespace raleigh { + coord::coord(uint32_t x, uint32_t y) + : x(x), y(y) {} + coord::coord() + : x(0), y(0) {} + + __attribute__ ((noreturn)) + void show_error_and_quitf(const char *fmt, ...) { + va_list args; + va_start(args, fmt); + + struct popup info; + info_popupf_v(&info, fmt, RGB(7f, 00, 00), RGB(bf, bf, bf), args); + make_modal(&info); + + __pcrt_quit(); + } +} \ No newline at end of file -- cgit v1.2.3