mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 04:27:45 +00:00
LibGfx: Switch a bunch of API's from taking StringView to String
These were all getting converted into String internally anyway.
This commit is contained in:
parent
050648b270
commit
e873d27ab1
12 changed files with 17 additions and 17 deletions
|
@ -143,7 +143,7 @@ RefPtr<Bitmap> Bitmap::create_wrapper(BitmapFormat format, const IntSize& size,
|
|||
return adopt(*new Bitmap(format, size, scale_factor, pitch, data));
|
||||
}
|
||||
|
||||
RefPtr<Bitmap> Bitmap::load_from_file(const StringView& path, int scale_factor)
|
||||
RefPtr<Bitmap> Bitmap::load_from_file(String const& path, int scale_factor)
|
||||
{
|
||||
if (scale_factor > 1 && path.starts_with("/res/")) {
|
||||
LexicalPath lexical_path { path };
|
||||
|
@ -439,11 +439,11 @@ Bitmap::~Bitmap()
|
|||
delete[] m_palette;
|
||||
}
|
||||
|
||||
void Bitmap::set_mmap_name([[maybe_unused]] const StringView& name)
|
||||
void Bitmap::set_mmap_name([[maybe_unused]] String const& name)
|
||||
{
|
||||
VERIFY(m_needs_munmap);
|
||||
#ifdef __serenity__
|
||||
::set_mmap_name(m_data, size_in_bytes(), name.to_string().characters());
|
||||
::set_mmap_name(m_data, size_in_bytes(), name.characters());
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue