mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-19 00:31:52 +00:00
LibGfx: Remove try_
prefix from bitmap creation functions
Those don't have any non-try counterpart, so we might as well just omit it.
This commit is contained in:
parent
1971bff314
commit
82a152b696
Notes:
sideshowbarker
2024-07-17 01:10:58 +09:00
Author: https://github.com/timschumi
Commit: 82a152b696
Pull-request: https://github.com/SerenityOS/serenity/pull/17181
186 changed files with 598 additions and 598 deletions
|
@ -25,7 +25,7 @@ JS::GCPtr<ImageData> ImageData::create_with_size(JS::Realm& realm, int width, in
|
|||
return nullptr;
|
||||
auto data = JS::NonnullGCPtr<JS::Uint8ClampedArray>(*data_or_error.release_value());
|
||||
|
||||
auto bitmap_or_error = Gfx::Bitmap::try_create_wrapper(Gfx::BitmapFormat::RGBA8888, Gfx::IntSize(width, height), 1, width * sizeof(u32), data->data().data());
|
||||
auto bitmap_or_error = Gfx::Bitmap::create_wrapper(Gfx::BitmapFormat::RGBA8888, Gfx::IntSize(width, height), 1, width * sizeof(u32), data->data().data());
|
||||
if (bitmap_or_error.is_error())
|
||||
return nullptr;
|
||||
return realm.heap().allocate<ImageData>(realm, realm, bitmap_or_error.release_value(), move(data));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue