mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:57:35 +00:00
LibGUI: Fix const-correctness issues
This commit is contained in:
parent
bfe081caad
commit
faa1a09042
44 changed files with 180 additions and 183 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
||||
* Copyright (c) 2018-2023, Andreas Kling <kling@serenityos.org>
|
||||
* Copyright (c) 2021, Julius Heijmen <julius.heijmen@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
|
@ -26,7 +26,7 @@ Icon::Icon(Icon const& other)
|
|||
{
|
||||
}
|
||||
|
||||
Icon::Icon(RefPtr<Gfx::Bitmap>&& bitmap)
|
||||
Icon::Icon(RefPtr<Gfx::Bitmap const>&& bitmap)
|
||||
: Icon()
|
||||
{
|
||||
if (bitmap) {
|
||||
|
@ -36,7 +36,7 @@ Icon::Icon(RefPtr<Gfx::Bitmap>&& bitmap)
|
|||
}
|
||||
}
|
||||
|
||||
Icon::Icon(RefPtr<Gfx::Bitmap>&& bitmap1, RefPtr<Gfx::Bitmap>&& bitmap2)
|
||||
Icon::Icon(RefPtr<Gfx::Bitmap const>&& bitmap1, RefPtr<Gfx::Bitmap const>&& bitmap2)
|
||||
: Icon(move(bitmap1))
|
||||
{
|
||||
if (bitmap2) {
|
||||
|
@ -64,7 +64,7 @@ Gfx::Bitmap const* IconImpl::bitmap_for_size(int size) const
|
|||
return best_fit;
|
||||
}
|
||||
|
||||
void IconImpl::set_bitmap_for_size(int size, RefPtr<Gfx::Bitmap>&& bitmap)
|
||||
void IconImpl::set_bitmap_for_size(int size, RefPtr<Gfx::Bitmap const>&& bitmap)
|
||||
{
|
||||
if (!bitmap) {
|
||||
m_bitmaps.remove(size);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue