mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 15:38:10 +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
|
@ -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