mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 12:37:45 +00:00
Change String&& arguments to const String& in a couple of places.
String&& is more nuisance than anything, and the codegen improvement is basically negligible since the underlying type is already retainable.
This commit is contained in:
parent
23e6c45e87
commit
dddf45f563
11 changed files with 18 additions and 18 deletions
|
@ -35,11 +35,11 @@ GCheckBox::~GCheckBox()
|
|||
{
|
||||
}
|
||||
|
||||
void GCheckBox::set_caption(String&& caption)
|
||||
void GCheckBox::set_caption(const String& caption)
|
||||
{
|
||||
if (caption == m_caption)
|
||||
return;
|
||||
m_caption = move(caption);
|
||||
m_caption = caption;
|
||||
update();
|
||||
}
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ public:
|
|||
virtual ~GCheckBox() override;
|
||||
|
||||
String caption() const { return m_caption; }
|
||||
void set_caption(String&&);
|
||||
void set_caption(const String&);
|
||||
|
||||
bool is_checked() const { return m_checked; }
|
||||
void set_checked(bool);
|
||||
|
|
|
@ -26,9 +26,9 @@ GStatusBar::~GStatusBar()
|
|||
{
|
||||
}
|
||||
|
||||
void GStatusBar::set_text(String&& text)
|
||||
void GStatusBar::set_text(const String& text)
|
||||
{
|
||||
m_label->set_text(move(text));
|
||||
m_label->set_text(text);
|
||||
}
|
||||
|
||||
String GStatusBar::text() const
|
||||
|
|
|
@ -11,7 +11,7 @@ public:
|
|||
virtual ~GStatusBar() override;
|
||||
|
||||
String text() const;
|
||||
void set_text(String&&);
|
||||
void set_text(const String&);
|
||||
|
||||
virtual const char* class_name() const override { return "GStatusBar"; }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue