mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:07:46 +00:00
LibGfx: Use "try_" prefix for static factory functions
Also mark them as [[nodiscard]].
This commit is contained in:
parent
f0409081f5
commit
c7d891765c
131 changed files with 422 additions and 421 deletions
|
@ -792,7 +792,7 @@ static bool decode_dds(DDSLoadingContext& context)
|
|||
dbgln_if(DDS_DEBUG, "There are {} bytes remaining, we need {} for mipmap level {} of the image", stream.remaining(), needed_bytes, mipmap_level);
|
||||
VERIFY(stream.remaining() >= needed_bytes);
|
||||
|
||||
context.bitmap = Bitmap::create_purgeable(BitmapFormat::BGRA8888, { width, height });
|
||||
context.bitmap = Bitmap::try_create_purgeable(BitmapFormat::BGRA8888, { width, height });
|
||||
|
||||
decode_bitmap(stream, context, format, width, height);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue