1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 03:37:43 +00:00

Applications: Stop lying about string types

This commit is contained in:
Hendiadyoin1 2023-06-11 19:43:46 +02:00 committed by Jelle Raaijmakers
parent 5ff80b60cf
commit a45682dcdc
3 changed files with 3 additions and 3 deletions

View file

@ -97,7 +97,7 @@ public:
if (m_piece_set_name == piece_set_name.view()) if (m_piece_set_name == piece_set_name.view())
return {}; return {};
m_piece_set_name = TRY(String::from_utf8(piece_set_name)); m_piece_set_name = TRY(String::from_deprecated_string(piece_set_name));
m_piece_images.clear(); m_piece_images.clear();
m_piece_images.set({ Chess::Color::White, Chess::Type::Pawn }, TRY(load_piece_image(m_piece_set_name, "white-pawn.png"sv))); m_piece_images.set({ Chess::Color::White, Chess::Type::Pawn }, TRY(load_piece_image(m_piece_set_name, "white-pawn.png"sv)));

View file

@ -110,7 +110,7 @@ MainWidget::MainWidget()
return; return;
} }
m_history.push(path.string()); m_history.push(path.string());
auto string_path = String::from_utf8(path.string()); auto string_path = String::from_deprecated_string(path.string());
if (string_path.is_error()) if (string_path.is_error())
return; return;
open_page(string_path.value()); open_page(string_path.value());

View file

@ -112,7 +112,7 @@ FindDialog::FindDialog()
auto action = options[i]; auto action = options[i];
auto& radio = radio_container.add<GUI::RadioButton>(); auto& radio = radio_container.add<GUI::RadioButton>();
radio.set_enabled(action.enabled); radio.set_enabled(action.enabled);
radio.set_text(String::from_deprecated_string(action.title).release_value_but_fixme_should_propagate_errors()); radio.set_text(String::from_utf8(action.title).release_value_but_fixme_should_propagate_errors());
radio.on_checked = [this, i](auto) { radio.on_checked = [this, i](auto) {
m_selected_option = options[i].opt; m_selected_option = options[i].opt;