mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:07:34 +00:00
Userland: Set Button text using the new String class
This commit is contained in:
parent
b5cb9a9ebb
commit
e39adc4772
49 changed files with 134 additions and 127 deletions
|
@ -122,7 +122,7 @@ FindInFilesWidget::FindInFilesWidget()
|
|||
|
||||
m_textbox = top_container.add<GUI::TextBox>();
|
||||
|
||||
m_button = top_container.add<GUI::Button>("Find in files");
|
||||
m_button = top_container.add<GUI::Button>(String::from_utf8("Find in files"sv).release_value_but_fixme_should_propagate_errors());
|
||||
m_button->set_fixed_width(100);
|
||||
|
||||
m_result_view = add<GUI::TableView>();
|
||||
|
|
|
@ -51,7 +51,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
auto app_icon = TRY(GUI::Icon::try_create_default_icon("app-inspector"sv));
|
||||
if (gui_mode) {
|
||||
choose_pid:
|
||||
auto process_chooser = TRY(GUI::ProcessChooser::try_create("Inspector"sv, "Inspect"sv, app_icon.bitmap_for_size(16)));
|
||||
auto process_chooser = TRY(GUI::ProcessChooser::try_create("Inspector"sv, String::from_utf8_short_string("Inspect"sv), app_icon.bitmap_for_size(16)));
|
||||
if (process_chooser->exec() == GUI::Dialog::ExecResult::Cancel)
|
||||
return 0;
|
||||
pid = process_chooser->pid();
|
||||
|
|
|
@ -331,7 +331,7 @@ static bool prompt_to_stop_profiling(pid_t pid, DeprecatedString const& process_
|
|||
}).release_value_but_fixme_should_propagate_errors();
|
||||
update_timer->start();
|
||||
|
||||
auto& stop_button = widget->add<GUI::Button>("Stop");
|
||||
auto& stop_button = widget->add<GUI::Button>(String::from_utf8_short_string("Stop"sv));
|
||||
stop_button.set_fixed_size(140, 22);
|
||||
stop_button.on_click = [&](auto) {
|
||||
GUI::Application::the()->quit();
|
||||
|
@ -344,7 +344,7 @@ static bool prompt_to_stop_profiling(pid_t pid, DeprecatedString const& process_
|
|||
bool generate_profile(pid_t& pid)
|
||||
{
|
||||
if (!pid) {
|
||||
auto process_chooser = GUI::ProcessChooser::construct("Profiler"sv, "Profile"sv, Gfx::Bitmap::load_from_file("/res/icons/16x16/app-profiler.png"sv).release_value_but_fixme_should_propagate_errors());
|
||||
auto process_chooser = GUI::ProcessChooser::construct("Profiler"sv, String::from_utf8_short_string("Profile"sv), Gfx::Bitmap::load_from_file("/res/icons/16x16/app-profiler.png"sv).release_value_but_fixme_should_propagate_errors());
|
||||
if (process_chooser->exec() == GUI::Dialog::ExecResult::Cancel)
|
||||
return false;
|
||||
pid = process_chooser->pid();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue