LibGUI: Make Window::set_title() take a String

This commit is contained in:
Andreas Kling 2021-04-16 20:06:43 +02:00
commit 050648b270
Notes: sideshowbarker 2024-07-18 19:32:52 +09:00
2 changed files with 4 additions and 4 deletions

View file

@ -220,12 +220,12 @@ void Window::hide()
}
}
void Window::set_title(const StringView& title)
void Window::set_title(String title)
{
m_title_when_windowless = title;
m_title_when_windowless = move(title);
if (!is_visible())
return;
WindowServerConnection::the().send_sync<Messages::WindowServer::SetWindowTitle>(m_window_id, title);
WindowServerConnection::the().send_sync<Messages::WindowServer::SetWindowTitle>(m_window_id, m_title_when_windowless);
}
String Window::title() const