From caa7845f0efd44ed3d3deb40222cdbd93c5bcb53 Mon Sep 17 00:00:00 2001 From: Igor Belitskiy Date: Mon, 3 Apr 2023 16:00:06 +0600 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=B8?= =?UTF-8?q?=D0=BB=20=D0=B1=D0=B0=D0=B3=20=D1=81=20=D0=B3=D0=BB=D0=BE=D0=B1?= =?UTF-8?q?=D0=B0=D0=BB=D1=8C=D0=BD=D1=8B=D0=BC=20=D1=81=D0=BE=D1=85=D1=80?= =?UTF-8?q?=D0=B0=D0=BD=D0=B5=D0=BD=D0=B8=D0=B5=D0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/ubl-settings-bootloader.cc | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/source/ubl-settings-bootloader.cc b/source/ubl-settings-bootloader.cc index 02d381a..a09addf 100755 --- a/source/ubl-settings-bootloader.cc +++ b/source/ubl-settings-bootloader.cc @@ -78,8 +78,9 @@ void MainWindow::settings(){ btnBoxAboutDialog->set_visible(false); ubl_make_plugs(boxSave,boxButton, socket_ext_id_I, socket_trd_id_I); if (this->check_root() == 0) { - spbSecond->set_range(1, 60); + spbSecond->set_range(0, 60); spbSecond->set_increments(1.0, 1.0); + spbSecond->set_value(1); this->fill_in_view(); this->change_password_protecc(); this->change_security_login(); @@ -627,6 +628,7 @@ void MainWindow::get_menu_boot(string cmd, std::map &map_temp) chbLoadVariantSelectionTimer->set_active(true); spbSecond->set_sensitive(true); lblInfoSeconds->set_sensitive(true); + } else if (res_response.error == 3) { if (start_error != index_error) { @@ -650,12 +652,22 @@ void MainWindow::set_menu_boot(string cmd = "", string cmd_remove = "") { cmd += to_string(value); this->wrapper_system(cmd, ""); } + else { + flag_save_local = true; + flag_save_global = true; + flag_save_all = true; + } map_cmd_selection["GRUB_TIMEOUT"] = to_string(value); } else if (chbLoadVariantSelectionTimer->get_active() == false) { if (cmd_remove.length() != 0) { this->wrapper_system(cmd_remove, ""); } + else { + flag_save_local = true; + flag_save_global = true; + flag_save_all = true; + } map_cmd_selection["GRUB_TIMEOUT"] = ""; } else { @@ -758,7 +770,9 @@ void MainWindow::set_active_boot_second() { } void MainWindow::wrapper_save_all_cfg() { - if (this->save_global_cfg() && this->save_local_cfg()) { + bool _flag_local = this->save_local_cfg(); + bool _flag_global = this->save_global_cfg(); + if (_flag_local && _flag_global) { this->info_warning_error(5); flag_save_all = false; }