mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 17:47:45 +00:00
AK+Everywhere: Replace "protocol" with "scheme" url helpers
URL had properly named replacements for protocol(), set_protocol() and create_with_file_protocol() already. This patch removes these function and updates all call sites to use the functions named according to the specification. See https://url.spec.whatwg.org/#concept-url-scheme
This commit is contained in:
parent
454bf1fde0
commit
4230dbbb21
61 changed files with 113 additions and 116 deletions
|
@ -103,7 +103,7 @@ bool MailWidget::connect_and_login()
|
|||
if (server.is_empty()) {
|
||||
auto result = GUI::MessageBox::show(window(), "Mail has no servers configured. Do you want configure them now?"sv, "Error"sv, GUI::MessageBox::Type::Error, GUI::MessageBox::InputType::YesNo);
|
||||
if (result == GUI::MessageBox::ExecResult::Yes)
|
||||
Desktop::Launcher::open(URL::create_with_file_protocol("/bin/MailSettings"));
|
||||
Desktop::Launcher::open(URL::create_with_file_scheme("/bin/MailSettings"));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
TRY(Core::System::unveil("/tmp/user/%uid/portal/launch", "rw"));
|
||||
TRY(Core::System::unveil(nullptr, nullptr));
|
||||
|
||||
TRY(Desktop::Launcher::add_allowed_url(URL::create_with_file_protocol("/bin/MailSettings")));
|
||||
TRY(Desktop::Launcher::add_allowed_url(URL::create_with_file_scheme("/bin/MailSettings")));
|
||||
TRY(Desktop::Launcher::add_allowed_handler_with_any_url("/bin/MailSettings"));
|
||||
TRY(Desktop::Launcher::seal_allowlist());
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue