|
|
|
|
@ -263,13 +263,11 @@ void MainWindow::settings() {
|
|
|
|
|
vector<string> os_control_list;
|
|
|
|
|
this->pars_os(os_control_list);
|
|
|
|
|
this->download_local_cfg();
|
|
|
|
|
// this->download_globl_cfg();
|
|
|
|
|
vector<tuple<string, vector<string>>> vec_list_os = format_os_list(os_control_list);
|
|
|
|
|
obj_menu_os.set_main_revealer(revilerMenuOS);
|
|
|
|
|
obj_menu_os.set_builder(builder, path_glade);
|
|
|
|
|
obj_menu_os.set_map(vec_list_os);
|
|
|
|
|
obj_menu_os.set_entry(entrListOS);
|
|
|
|
|
// obj_menu_os.set_last_launched_os(map_global_cmd_selection["GRUB_DEFAULT"]);
|
|
|
|
|
obj_menu_os.set_last_launched_os(this->str_last_launched_os);
|
|
|
|
|
obj_menu_os.init();
|
|
|
|
|
obj_menu_os.event();
|
|
|
|
|
@ -400,7 +398,6 @@ void MainWindow::item_selected_kernel(const Gtk::TreeModel::Path&, const Gtk::Tr
|
|
|
|
|
if (this->intel_idle_cstate_check(size_kernel, list_store_kernel, "GRUB_CMDLINE_LINUX") == false) {
|
|
|
|
|
string str_flags = template_item_selected(size_kernel, list_store_kernel, "GRUB_CMDLINE_LINUX");
|
|
|
|
|
map_cmd_selection["GRUB_CMDLINE_LINUX"] = str_flags;
|
|
|
|
|
// Utils::str_replace_all(str_flags, " ", ", ");
|
|
|
|
|
entryKernel->set_text(str_flags);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@ -415,7 +412,6 @@ void MainWindow::item_selected_OTT(const Gtk::TreeModel::Path&, const Gtk::TreeM
|
|
|
|
|
if (this->intel_idle_cstate_check(size_OTT, list_store_OTT, "GRUB_TERMINAL_OUTPUT") == false) {
|
|
|
|
|
string str_flags = template_item_selected(size_OTT, list_store_OTT, "GRUB_TERMINAL_OUTPUT");
|
|
|
|
|
map_cmd_selection["GRUB_TERMINAL_OUTPUT"] = str_flags;
|
|
|
|
|
// Utils::str_replace_all(str_flags, " ", ", ");
|
|
|
|
|
entryOTT->set_text(str_flags);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@ -430,7 +426,6 @@ void MainWindow::item_selected_IPT(const Gtk::TreeModel::Path&, const Gtk::TreeM
|
|
|
|
|
if (this->intel_idle_cstate_check(size_IPT, list_store_IPT, "GRUB_TERMINAL_INPUT") == false) {
|
|
|
|
|
string str_flags = template_item_selected(size_IPT, list_store_IPT, "GRUB_TERMINAL_INPUT");
|
|
|
|
|
map_cmd_selection["GRUB_TERMINAL_INPUT"] = str_flags;
|
|
|
|
|
// Utils::str_replace_all(str_flags, " ", ", ");
|
|
|
|
|
entryIPT->set_text(str_flags);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@ -756,7 +751,6 @@ void MainWindow::set_entry_to_tree_view(Glib::RefPtr<Gtk::ListStore> &list_store
|
|
|
|
|
flag_blocked_tree_view = true;
|
|
|
|
|
vector<string> vec_params;
|
|
|
|
|
std::string text = entry.get_text();
|
|
|
|
|
// Utils::str_replace_all(text, " ", "");
|
|
|
|
|
vec_params = Utils::split(text, ' ');
|
|
|
|
|
for (auto &name: vec_Option) {
|
|
|
|
|
this->set_row(list_store, size, name, false);
|
|
|
|
|
@ -764,7 +758,6 @@ void MainWindow::set_entry_to_tree_view(Glib::RefPtr<Gtk::ListStore> &list_store
|
|
|
|
|
for (auto &name: vec_params) {
|
|
|
|
|
this->set_row(list_store, size, name, true);
|
|
|
|
|
}
|
|
|
|
|
// Utils::str_replace_all(text, ",", " ");
|
|
|
|
|
if (text.length() > 0) {
|
|
|
|
|
if (text[0] == ' ') {
|
|
|
|
|
text = text.substr(1, text.length() - 1);
|
|
|
|
|
@ -920,7 +913,6 @@ void MainWindow::check_resize_window() {
|
|
|
|
|
else {
|
|
|
|
|
height = plug->get_window()->get_height();
|
|
|
|
|
width = plug->get_window()->get_width();
|
|
|
|
|
// lblInfoHead->set_text(to_string(height));
|
|
|
|
|
}
|
|
|
|
|
if (height != old_height) {
|
|
|
|
|
if (minimal_height >= height) {
|
|
|
|
|
@ -973,7 +965,6 @@ void MainWindow::set_tree_view_user() {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
// map_cmd_selection[key] = "";
|
|
|
|
|
}
|
|
|
|
|
if (row[m_columns_user.check_button]) {
|
|
|
|
|
if (users_root.length() != 0) {
|
|
|
|
|
@ -1306,15 +1297,12 @@ void MainWindow::wrapper_save_local_cfg() {
|
|
|
|
|
|
|
|
|
|
void MainWindow::set_data_cfg() {
|
|
|
|
|
string str_flags = entryKernel->get_text();
|
|
|
|
|
// Utils::str_remove(str_flags, ",");
|
|
|
|
|
Utils::str_replace_all(str_flags, " \"", "\"");
|
|
|
|
|
map_cmd_selection["GRUB_CMDLINE_LINUX"] = str_flags;
|
|
|
|
|
str_flags = entryIPT->get_text();
|
|
|
|
|
// Utils::str_remove(str_flags, ",");
|
|
|
|
|
Utils::str_replace_all(str_flags, " \"", "\"");
|
|
|
|
|
map_cmd_selection["GRUB_TERMINAL_INPUT"] = str_flags;
|
|
|
|
|
str_flags = entryOTT->get_text();
|
|
|
|
|
// Utils::str_remove(str_flags, ",");
|
|
|
|
|
Utils::str_replace_all(str_flags, " \"", "\"");
|
|
|
|
|
map_cmd_selection["GRUB_TERMINAL_OUTPUT"] = str_flags;
|
|
|
|
|
if (chbLoadVariantSelectionTimer->get_active()) {
|
|
|
|
|
@ -1390,7 +1378,6 @@ void MainWindow::set_entry(Gtk::Entry* entry, std::map<string, string> &map_temp
|
|
|
|
|
if (map_temp.find(key) != map_temp.end()) {
|
|
|
|
|
string value = map_temp[key];
|
|
|
|
|
Utils::str_replace_all(value, "\"", "");
|
|
|
|
|
// Utils::str_replace_all(value, " ", ", ");
|
|
|
|
|
entry->set_text(value);
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
|