LibGL: Make GL::create_context fallible

Propagate errors in places that are already set up to handle them, like
WebGLRenderingContext and the Tubes demo, and convert other callers
to using MUST.
This commit is contained in:
Andrew Kaster 2022-09-16 05:58:30 -06:00 committed by Andreas Kling
commit 8ed5ed3ec0
Notes: sideshowbarker 2024-07-18 00:54:03 +09:00
7 changed files with 14 additions and 20 deletions

View file

@ -59,7 +59,7 @@ private:
constexpr u16 RENDER_WIDTH = 640;
constexpr u16 RENDER_HEIGHT = 480;
m_bitmap = Gfx::Bitmap::try_create(Gfx::BitmapFormat::BGRx8888, { RENDER_WIDTH, RENDER_HEIGHT }).release_value_but_fixme_should_propagate_errors();
m_context = GL::create_context(*m_bitmap);
m_context = MUST(GL::create_context(*m_bitmap));
start_timer(20);