mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 09:14:58 +00:00
LibGUI+Browser: Set menu names using the new String class
This commit is contained in:
parent
956f4d9205
commit
dccd70385d
3 changed files with 1 additions and 7 deletions
|
@ -810,7 +810,7 @@ ErrorOr<void> BrowserWindow::take_screenshot(ScreenshotType type)
|
|||
void BrowserWindow::update_displayed_zoom_level()
|
||||
{
|
||||
VERIFY(m_zoom_menu);
|
||||
auto zoom_level_text = DeprecatedString::formatted("&Zoom ({}%)", round_to<int>(active_tab().view().zoom_level() * 100));
|
||||
auto zoom_level_text = String::formatted("&Zoom ({}%)", round_to<int>(active_tab().view().zoom_level() * 100)).release_value_but_fixme_should_propagate_errors();
|
||||
m_zoom_menu->set_name(zoom_level_text);
|
||||
active_tab().update_reset_zoom_button();
|
||||
}
|
||||
|
|
|
@ -89,11 +89,6 @@ void Menu::update_parent_menu_item()
|
|||
}
|
||||
}
|
||||
|
||||
void Menu::set_name(DeprecatedString name)
|
||||
{
|
||||
set_name(String::from_deprecated_string(name).release_value_but_fixme_should_propagate_errors());
|
||||
}
|
||||
|
||||
void Menu::set_name(String name)
|
||||
{
|
||||
m_name = move(name);
|
||||
|
|
|
@ -34,7 +34,6 @@ public:
|
|||
int menu_id() const { return m_menu_id; }
|
||||
|
||||
String const& name() const { return m_name; }
|
||||
void set_name(DeprecatedString);
|
||||
void set_name(String);
|
||||
|
||||
Gfx::Bitmap const* icon() const { return m_icon.ptr(); }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue