mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 18:07:34 +00:00
Mail: Ask the user if they want to see the mail settings
This commit is contained in:
parent
bccfa205d3
commit
312bac1967
2 changed files with 11 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2021, Luke Wilde <lukew@serenityos.org>
|
||||
* Copyright (c) 2021, Undefine <cqundefine@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -103,7 +104,9 @@ bool MailWidget::connect_and_login()
|
|||
auto server = Config::read_string("Mail", "Connection", "Server", {});
|
||||
|
||||
if (server.is_empty()) {
|
||||
GUI::MessageBox::show_error(window(), "Mail has no servers configured. Refer to the Mail(1) man page for more information.");
|
||||
int result = GUI::MessageBox::show(window(), "Mail has no servers configured. Do you want configure them now?", "Error", GUI::MessageBox::Type::Error, GUI::MessageBox::InputType::YesNo);
|
||||
if (result == GUI::MessageBox::ExecResult::ExecYes)
|
||||
Desktop::Launcher::open(URL::create_with_file_protocol("/bin/MailSettings"), "/bin/MailSettings");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue