diff --git a/Userland/Applets/Keymap/KeymapStatusWidget.cpp b/Userland/Applets/Keymap/KeymapStatusWidget.cpp index 104470fad3..7b6f2fae22 100644 --- a/Userland/Applets/Keymap/KeymapStatusWidget.cpp +++ b/Userland/Applets/Keymap/KeymapStatusWidget.cpp @@ -66,7 +66,7 @@ ErrorOr KeymapStatusWidget::refresh_menu() void KeymapStatusWidget::set_current_keymap(DeprecatedString const& keymap) { m_current_keymap = keymap; - set_tooltip_deprecated(keymap); + set_tooltip(MUST(String::from_deprecated_string(keymap))); update(); } diff --git a/Userland/Applications/Browser/BookmarksBarWidget.cpp b/Userland/Applications/Browser/BookmarksBarWidget.cpp index 44d6b0b92a..940be44013 100644 --- a/Userland/Applications/Browser/BookmarksBarWidget.cpp +++ b/Userland/Applications/Browser/BookmarksBarWidget.cpp @@ -216,7 +216,7 @@ void BookmarksBarWidget::model_did_update(unsigned) button.set_fixed_size(font().width(title) + 32, 20); button.set_relative_rect(rect); button.set_focus_policy(GUI::FocusPolicy::TabFocus); - button.set_tooltip_deprecated(url); + button.set_tooltip(MUST(String::from_deprecated_string(url))); button.set_allowed_mouse_buttons_for_pressing(GUI::MouseButton::Primary | GUI::MouseButton::Middle); button.on_click = [title, url, this](auto) { diff --git a/Userland/Applications/Spreadsheet/SpreadsheetView.cpp b/Userland/Applications/Spreadsheet/SpreadsheetView.cpp index 4dcc4b7619..039cbefce9 100644 --- a/Userland/Applications/Spreadsheet/SpreadsheetView.cpp +++ b/Userland/Applications/Spreadsheet/SpreadsheetView.cpp @@ -80,10 +80,10 @@ void InfinitelyScrollableTableView::mousemove_event(GUI::MouseEvent& event) if (!is_dragging()) { auto tooltip = model->data(index, static_cast(SheetModel::Role::Tooltip)); if (tooltip.is_string()) { - set_tooltip_deprecated(tooltip.as_string()); + set_tooltip(MUST(String::from_deprecated_string(tooltip.as_string()))); show_or_hide_tooltip(); } else { - set_tooltip_deprecated({}); + set_tooltip({}); } } diff --git a/Userland/DevTools/Profiler/FlameGraphView.cpp b/Userland/DevTools/Profiler/FlameGraphView.cpp index b657d4c977..4b70f31f3d 100644 --- a/Userland/DevTools/Profiler/FlameGraphView.cpp +++ b/Userland/DevTools/Profiler/FlameGraphView.cpp @@ -89,11 +89,11 @@ void FlameGraphView::mousemove_event(GUI::MouseEvent& event) if (on_hover_change) on_hover_change(); - DeprecatedString label = ""; + String label; if (m_hovered_bar != nullptr && m_hovered_bar->index.is_valid()) { label = bar_label(*m_hovered_bar); } - set_tooltip_deprecated(label); + set_tooltip(label); show_or_hide_tooltip(); update(); @@ -175,12 +175,12 @@ void FlameGraphView::paint_event(GUI::PaintEvent& event) } } -DeprecatedString FlameGraphView::bar_label(StackBar const& bar) const +String FlameGraphView::bar_label(StackBar const& bar) const { auto label_index = bar.index.sibling_at_column(m_text_column); - DeprecatedString label = "All"; + String label = "All"_string; if (label_index.is_valid()) { - label = m_model.data(label_index).to_deprecated_string(); + label = MUST(String::from_deprecated_string(m_model.data(label_index).to_deprecated_string())); } return label; } diff --git a/Userland/DevTools/Profiler/FlameGraphView.h b/Userland/DevTools/Profiler/FlameGraphView.h index ca98ebe647..97035e3d8b 100644 --- a/Userland/DevTools/Profiler/FlameGraphView.h +++ b/Userland/DevTools/Profiler/FlameGraphView.h @@ -46,7 +46,7 @@ private: bool selected; }; - DeprecatedString bar_label(StackBar const&) const; + String bar_label(StackBar const&) const; void layout_bars(); void layout_children(GUI::ModelIndex& parent, int depth, int left, int right, Vector& selected); diff --git a/Userland/Libraries/LibGUI/Action.cpp b/Userland/Libraries/LibGUI/Action.cpp index 21c07f5b8b..1c22b83223 100644 --- a/Userland/Libraries/LibGUI/Action.cpp +++ b/Userland/Libraries/LibGUI/Action.cpp @@ -308,7 +308,7 @@ void Action::set_tooltip(DeprecatedString tooltip) return; m_tooltip = move(tooltip); for_each_toolbar_button([&](auto& button) { - button.set_tooltip_deprecated(*m_tooltip); + button.set_tooltip(MUST(String::from_deprecated_string(*m_tooltip))); }); for_each_menu_item([&](auto& menu_item) { menu_item.update_from_action({}); diff --git a/Userland/Services/Taskbar/QuickLaunchWidget.cpp b/Userland/Services/Taskbar/QuickLaunchWidget.cpp index 654ca156dd..12bed155eb 100644 --- a/Userland/Services/Taskbar/QuickLaunchWidget.cpp +++ b/Userland/Services/Taskbar/QuickLaunchWidget.cpp @@ -191,7 +191,7 @@ ErrorOr QuickLaunchWidget::add_or_adjust_button(DeprecatedString const& bu button->set_button_style(Gfx::ButtonStyle::Coolbar); auto icon = entry->icon(); button->set_icon(icon.bitmap_for_size(16)); - button->set_tooltip_deprecated(entry->name()); + button->set_tooltip(MUST(String::from_deprecated_string(entry->name()))); button->set_name(button_name); button->on_click = [entry = move(entry), this](auto) { auto result = entry->launch(); diff --git a/Userland/Services/Taskbar/TaskbarWindow.cpp b/Userland/Services/Taskbar/TaskbarWindow.cpp index b37ace87fb..d31558214c 100644 --- a/Userland/Services/Taskbar/TaskbarWindow.cpp +++ b/Userland/Services/Taskbar/TaskbarWindow.cpp @@ -199,7 +199,7 @@ void TaskbarWindow::update_window_button(::Window& window, bool show_as_active) if (!button) return; button->set_text(String::from_deprecated_string(window.title()).release_value_but_fixme_should_propagate_errors()); - button->set_tooltip_deprecated(window.title()); + button->set_tooltip(String::from_deprecated_string(window.title()).release_value_but_fixme_should_propagate_errors()); button->set_checked(show_as_active); button->set_visible(is_window_on_current_workspace(window)); }