diff --git a/Makefile b/Makefile index 09e1671..527ed30 100644 --- a/Makefile +++ b/Makefile @@ -133,10 +133,11 @@ install: check uninstall @if [[ "${PREFIX}" == @("/usr"|"/usr/") ]]; then \ install -Dm644 -t "${DESTDIR}${PREFIX}/share/polkit-1/actions/" "com.ublinux.${PKGNAME}.policy"; \ else \ -# install -Dm644 "com.ublinux.${PKGNAME}.policy" "${DESTDIR}${PREFIX}/share/polkit-1/actions/com.ublinux.${PKGNAME}$${PREFIX//\//-}.policy"; \ + install -Dm644 "com.ublinux.${PKGNAME}.policy" "${DESTDIR}/usr/share/polkit-1/actions/com.ublinux.${PKGNAME}$${PREFIX//\//-}-local.policy"; \ install -Dm644 "com.ublinux.${PKGNAME}.policy" "${DESTDIR}/usr/share/polkit-1/actions/com.ublinux.${PKGNAME}$${PREFIX//\//-}.policy"; \ -# sed -e "s+/usr/bin+${PREFIX}/bin+" -e "s+\.run+$${PREFIX//\//-}\.run+g" -i "${DESTDIR}${PREFIX}/share/polkit-1/actions/com.ublinux.${PKGNAME}$${PREFIX//\//-}.policy"; \ + # sed -e "s+/usr/bin+${PREFIX}/bin+" -e "s+\.run+$${PREFIX//\//-}\.run+g" -i "${DESTDIR}${PREFIX}/share/polkit-1/actions/com.ublinux.${PKGNAME}$${PREFIX//\//-}.policy"; \ sed -e "s+/usr/bin+/usr/bin+" -e "s+\.run+$${PREFIX//\//-}\.run+g" -i "${DESTDIR}/usr/share/polkit-1/actions/com.ublinux.${PKGNAME}$${PREFIX//\//-}.policy"; \ + sed -e '\|annotate key=|s|/usr/bin|${PREFIX}/bin|' -e '/action id=/s/\.run/${PKGIDENT}\.run/' -i ${DESTDIR}/usr/share/polkit-1/actions/com.ublinux.${PKGNAME}-local.policy;\ fi @if [[ -z "${DESTDIR}" ]]; then \ ldconfig -n ${DESTDIR}/usr/lib; \ diff --git a/locale/ubinstall-gtk.pot b/locale/ubinstall-gtk.pot index 8d97093..f61f5b7 100644 --- a/locale/ubinstall-gtk.pot +++ b/locale/ubinstall-gtk.pot @@ -5366,4 +5366,7 @@ msgid "The required field is highlighted in green" msgstr "" msgid "Authentication in the bootloader menu" +msgstr "" + +msgid "Exit" msgstr "" \ No newline at end of file diff --git a/locale/ubinstall-gtk_ru.po b/locale/ubinstall-gtk_ru.po index fc8cecf..ccab3e5 100644 --- a/locale/ubinstall-gtk_ru.po +++ b/locale/ubinstall-gtk_ru.po @@ -5561,4 +5561,7 @@ msgid "The required field is highlighted in green" msgstr "Обязательное поле подсвечено зелёным" msgid "Authentication in the bootloader menu" -msgstr "Аутентификация в меню загрузчика" \ No newline at end of file +msgstr "Аутентификация в меню загрузчика" + +msgid "Exit" +msgstr "Выход" \ No newline at end of file diff --git a/source/ubinstall-gtk-advanced.c b/source/ubinstall-gtk-advanced.c index 82b934f..242e4f3 100644 --- a/source/ubinstall-gtk-advanced.c +++ b/source/ubinstall-gtk-advanced.c @@ -700,8 +700,8 @@ void yon_advanced_init(main_window *widgets){ } yon_char_parsed_free(vmf_file,size); g_signal_handlers_unblock_by_func(G_OBJECT(widgets->AdvancedVirtualDeviceCombo),G_CALLBACK(on_advanced_virtual_device_changed),widgets); - - if (!strcmp(config(AUTOINSTALL_TYPE_INSTALL),"custom")){ + char *install_mode = config(AUTOINSTALL_TYPE_INSTALL); + if (!yon_char_is_empty(install_mode)&&!strcmp(install_mode,"custom")){ advanced_part_data *data1 = yon_advanced_get_config_data(0); advanced_part_data *data2 = yon_advanced_get_config_data(1); yon_advanced_part_select_for_data(data1,widgets); diff --git a/source/ubinstall-gtk-bootloader.c b/source/ubinstall-gtk-bootloader.c index 0c664e5..a9b074b 100644 --- a/source/ubinstall-gtk-bootloader.c +++ b/source/ubinstall-gtk-bootloader.c @@ -18,6 +18,11 @@ int yon_bootloader_save(main_window *widgets){ yon_config_register(GRUB_SUPERUSERS_parameter,GRUB_SUPERUSERS_parameter_command,NULL); yon_config_set_status(GRUB_SUPERUSERS_parameter,-1); } + + if (!gtk_switch_get_active(GTK_SWITCH(widgets->BootloadNoPasswordSwitch))){ + yon_config_remove_by_key(GRUB_SUPERUSERS_parameter); + + } else { GtkTreeIter iter; GtkTreeModel *model = GTK_TREE_MODEL(widgets->BootloadUsersList); for_iter(model,&iter){ @@ -31,6 +36,7 @@ int yon_bootloader_save(main_window *widgets){ yon_config_remove_by_key(GRUB_SUPERUSERS_parameter); } } + } if (!main_config.configure_mode){ @@ -475,7 +481,10 @@ void yon_bootloader_init(main_window *widgets){ } else { gtk_entry_set_text(GTK_ENTRY(widgets->BootloadDefaultOSEntry),DEFAULT_BOOTLOAD_MENU_ITEM_LABEL); } - { + if (!admins&&!size){ + gtk_switch_set_active(GTK_SWITCH(widgets->BootloadNoPasswordSwitch),0); + } else { + gtk_switch_set_active(GTK_SWITCH(widgets->BootloadNoPasswordSwitch),1); int admins_size; config_str admins_parsed = yon_char_parse(admins,&admins_size,","); GtkTreeIter iter; diff --git a/source/ubinstall-gtk-configuration-mode.c b/source/ubinstall-gtk-configuration-mode.c index cc3c2cc..32311cf 100644 --- a/source/ubinstall-gtk-configuration-mode.c +++ b/source/ubinstall-gtk-configuration-mode.c @@ -21,6 +21,13 @@ int yon_configuration_path_check(const char *path){ } else { full_path = yon_char_new(path); } + { + if (!strstr(full_path,".")){ + char *temp = yon_char_append(full_path,".ini"); + free(full_path); + full_path = temp; + } + } if (access(full_path,F_OK)){ dialog_confirmation_data *data = yon_confirmation_dialog_data_new(); data->action_text = homedir_create?CREATE_CONFIG_DIALOG_LABEL_HOMEDIR:CREATE_CONFIG_DIALOG_LABEL; @@ -68,7 +75,11 @@ void on_path_choose(GtkWidget *,configuration_window *window){ filechooser_window *dialog = yon_config_file_chooser_window_new(GTK_FILE_CHOOSER_ACTION_SAVE); yon_gtk_window_setup(GTK_WINDOW(dialog->Window),GTK_WINDOW(window->Window),CONFIGURATION_MODE_TITLE_LABEL,icon_path,"filechooser_window"); if (yon_file_chooser_start(dialog)==GTK_RESPONSE_APPLY){ - gtk_entry_set_text(GTK_ENTRY(window->PathEntry),dialog->last_success_selection); + char *path = dialog->last_success_selection; + if (!strstr(dialog->last_success_selection,".")){ + path = yon_char_append(dialog->last_any_selection,".ini"); + } + gtk_entry_set_text(GTK_ENTRY(window->PathEntry),path); free(dialog); } } @@ -124,11 +135,11 @@ void on_configuration_mode_switch(GtkWidget *,main_window *widgets){ yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),ROOT_FORCE_CONFIGURATION_MODE_LABEL,0,BACKGROUND_IMAGE_INFO_TYPE); } - if (!yon_char_is_empty(main_config.config_save_path)) { + if (!yon_char_is_empty(main_config.config_save_path)&&strcmp(main_config.config_save_path,"system")) { gtk_entry_set_text(GTK_ENTRY(window->PathEntry),main_config.config_save_path); + } free(main_config.config_save_path); main_config.config_save_path = NULL; - } gtk_widget_show(window->Window); gtk_main(); yon_config_mode_start(widgets); diff --git a/source/ubinstall-gtk-install-start.c b/source/ubinstall-gtk-install-start.c index 85b6281..c79400f 100644 --- a/source/ubinstall-gtk-install-start.c +++ b/source/ubinstall-gtk-install-start.c @@ -8,20 +8,38 @@ int yon_installation_start(main_window *widgets){ void yon_quick_install(GtkWidget *self, main_window *widgets){ if (!yon_installation_check_packages_size(widgets)) return; - if (!main_config.dry_run){ - main_config.save_configured=1; - gtk_widget_hide(self); - gtk_widget_show(gtk_widget_get_parent(widgets->InstallationProgress)); - pthread_create(&main_config.install_thread,NULL,on_config_save,widgets); - gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->Notebook),YON_PAGE_INSTALLATION); - if (!yon_char_is_empty(main_config.config_load_path)){ - char *command = quick_install_command(main_config.config_load_path); - yon_launch_app_with_arguments(command,NULL); - } - yon_page_init(widgets,YON_PAGE_INSTALLATION); - yon_page_update(widgets); - - } else { - yon_launch("ubconfig --source system get /"); - } + main_config.save_configured=1; + gtk_widget_hide(self); + gtk_widget_show(gtk_widget_get_parent(widgets->InstallationProgress)); + pthread_create(&main_config.install_thread,NULL,on_quick_install_start,widgets); + gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->Notebook),YON_PAGE_INSTALLATION); + yon_page_init(widgets,YON_PAGE_INSTALLATION); + yon_page_update(widgets); } + +void *on_quick_install_start(void *data){ + main_window *widgets = (main_window*)data; + + g_idle_add((GSourceFunc)yon_progress_bar_start,widgets); + if (!main_config.dry_run){ + char *command = yon_debug_output("%s\n",quick_install_command(main_config.config_load_path)); + yon_debug_output("%s\n","Entered installation"); + if (system(yon_debug_output("%s\n",command))){ + + gdk_threads_add_idle((GSourceFunc)on_install_error,widgets); + free(command); + g_mutex_lock(&main_config.install_mutex); + main_config.install_complete=1; + g_mutex_unlock(&main_config.install_mutex); + return 0; + }; + free(command); + g_mutex_lock(&main_config.install_mutex); + main_config.install_complete=1; + g_mutex_unlock(&main_config.install_mutex); + g_idle_add((GSourceFunc)on_install_success,widgets); + } else { + yon_launch("ubconfig --source system get /"); + } + return 0; +} \ No newline at end of file diff --git a/source/ubinstall-gtk-page-switch.c b/source/ubinstall-gtk-page-switch.c index bf37402..5d27784 100644 --- a/source/ubinstall-gtk-page-switch.c +++ b/source/ubinstall-gtk-page-switch.c @@ -149,7 +149,7 @@ void yon_navigation_buttons_set_sensetiveness(main_window *widgets){ gtk_widget_hide(widgets->StartScenarioButton); switch(page){ case YON_PAGE_WELCOME: - yon_load_proceed(YON_CONFIG_LOCAL); + // yon_load_proceed(YON_CONFIG_LOCAL); gtk_widget_hide(widgets->BackButton); gtk_widget_set_sensitive(widgets->NextButton,1); gtk_widget_set_sensitive(widgets->CancelInstallButton,0); @@ -158,18 +158,20 @@ void yon_navigation_buttons_set_sensetiveness(main_window *widgets){ gtk_widget_hide(widgets->BackButton); gtk_widget_hide(widgets->SourceButton); gtk_widget_show(widgets->NextButton); + gtk_button_set_label(GTK_BUTTON(widgets->CancelInstallButton),EXIT_LABEL); break; case YON_PAGE_LICENCE: gtk_widget_show(widgets->BackButton); gtk_widget_set_sensitive(widgets->BackButton,1); gtk_widget_set_sensitive(widgets->LoadLocalConfigurationMenuItem,1); gtk_widget_set_sensitive(widgets->LoadExternalConfigurationMenuItem,1); - if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widgets->LicenseAgreeRadio))) - gtk_widget_set_sensitive(widgets->NextButton,1); - else - gtk_widget_set_sensitive(widgets->NextButton,0); - + if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widgets->LicenseAgreeRadio))){ + gtk_widget_set_sensitive(widgets->NextButton,1); + } else { + gtk_widget_set_sensitive(widgets->NextButton,0); + } gtk_widget_set_sensitive(widgets->CancelInstallButton,1); + gtk_button_set_label(GTK_BUTTON(widgets->CancelInstallButton),EXIT_LABEL); break; case YON_PAGE_INSTALLATION: gtk_widget_set_sensitive(widgets->NextButton,0); @@ -228,6 +230,7 @@ void yon_navigation_buttons_set_sensetiveness(main_window *widgets){ { gtk_widget_set_sensitive(widgets->LoadLocalConfigurationMenuItem,0); gtk_widget_set_sensitive(widgets->LoadExternalConfigurationMenuItem,0); + gtk_button_set_label(GTK_BUTTON(widgets->CancelInstallButton),CANCEL_LABEL); } break; default: gtk_widget_set_sensitive(widgets->BackButton,1); @@ -268,6 +271,7 @@ void yon_navigation_buttons_set_sensetiveness(main_window *widgets){ gtk_button_set_label(GTK_BUTTON(widgets->NextButton),NEXT_LABEL); GtkWidget *image = gtk_button_get_image(GTK_BUTTON(widgets->NextButton)); gtk_image_set_from_icon_name(GTK_IMAGE(image),arrow_right_icon_path,GTK_ICON_SIZE_BUTTON); + gtk_button_set_label(GTK_BUTTON(widgets->CancelInstallButton),CANCEL_LABEL); } break; default: break; } @@ -454,7 +458,7 @@ void yon_container_stop_loading(GtkWidget *target){ void yon_configuration_mode_check(main_window *widgets){ enum YON_PAGES page = gtk_notebook_get_current_page(GTK_NOTEBOOK(widgets->Notebook)); - if (page==YON_PAGE_WELCOME&&!main_config.force_ini){ + if (page==YON_PAGE_WELCOME&&!main_config.force_ini&&!getuid()){ gtk_widget_set_sensitive(widgets->ConfigurationModeMenuItem,1); } else { gtk_widget_set_sensitive(widgets->ConfigurationModeMenuItem,0); diff --git a/source/ubinstall-gtk-saving.c b/source/ubinstall-gtk-saving.c index 338500e..17c8531 100644 --- a/source/ubinstall-gtk-saving.c +++ b/source/ubinstall-gtk-saving.c @@ -7,22 +7,22 @@ void yon_config_save_proceed(char *path, YON_CONFIG_TYPE type){ void yon_load_proceed(YON_CONFIG_TYPE type){ if (type!=YON_CONFIG_CUSTOM){ yon_config_clean(); + if (main_config.config_load_path){ + if (main_config.startup_config){ + yon_config_restore(NULL); + yon_config_custom_clean(main_config.startup_config); + } + main_config.startup_config = NULL; + } } if (!yon_char_is_empty(config_get_default_command)){ yon_config_load_config(YON_CONFIG_DEFAULT,config_get_default_command,NULL); } - if (main_config.config_load_path){ - if (main_config.startup_config){ - yon_config_restore(NULL); - yon_config_custom_clean(main_config.startup_config); - } - main_config.startup_config = NULL; - yon_config_custom_load_config(&main_config.startup_config,config_get_command(main_config.config_load_path),NULL); - } switch (type){ case YON_CONFIG_LOCAL: main_config.config_load_path = yon_char_new("system"); main_config.config_save_path = main_config.config_load_path; + yon_config_custom_load_config(&main_config.startup_config,config_get_command("system"),NULL); yon_config_load_config(type,config_get_command("system"),NULL); break; case YON_CONFIG_CUSTOM: @@ -30,14 +30,23 @@ void yon_load_proceed(YON_CONFIG_TYPE type){ char *path = NULL; path=yon_custom_config_init(GTK_FILE_CHOOSER_ACTION_OPEN); if (!yon_char_is_empty(path)){ + if (main_config.config_load_path){ + if (main_config.startup_config){ + yon_config_restore(NULL); + yon_config_custom_clean(main_config.startup_config); + } + main_config.startup_config = NULL; + } main_config.config_load_path = yon_char_new(path); main_config.config_save_path = main_config.config_load_path; yon_config_clean(); yon_config_load_config(type,config_get_command(path),NULL); + yon_config_custom_load_config(&main_config.startup_config,config_get_command(path),NULL); } } else { yon_config_clean(); yon_config_load_config(type,config_get_command(main_config.force_ini),NULL); + yon_config_custom_load_config(&main_config.startup_config,config_get_command(main_config.force_ini),NULL); } break; default: @@ -53,25 +62,28 @@ void on_config_local_load(GtkWidget *,main_window *widgets){ yon_load_proceed(YON_CONFIG_LOCAL); main_config.load_mode=YON_CONFIG_LOCAL; yon_main_window_update_locale(widgets); - yon_page_init(widgets,gtk_notebook_get_current_page(GTK_NOTEBOOK(widgets->Notebook))); + yon_navigation_buttons_set_sensetiveness(widgets); } -void on_config_custom_load(GtkWidget *,main_window *){ +void on_config_custom_load(GtkWidget *,main_window *widgets){ char *temp_custom_path = NULL; yon_load_proceed(YON_CONFIG_CUSTOM); if (!yon_char_is_empty(main_config.config_load_path)){ main_config.load_mode=YON_CONFIG_CUSTOM; free(temp_custom_path); } + yon_navigation_buttons_set_sensetiveness(widgets); } -void on_config_custom_load_last(GtkWidget *,main_window *){ +void on_config_custom_load_last(GtkWidget *,main_window *widgets){ yon_config_clean(); if (!yon_char_is_empty(config_get_default_command)) yon_config_load_config(YON_CONFIG_DEFAULT,config_get_default_command,NULL); char *command = config_get_command(main_config.config_load_path); yon_config_load_config(YON_CONFIG_CUSTOM,command,NULL); main_config.load_mode=YON_CONFIG_CUSTOM; + int page = gtk_notebook_get_current_page(GTK_NOTEBOOK(widgets->Notebook)); + yon_page_init(widgets,page); } void on_config_global_local_save(GtkWidget *,main_window *widgets){ diff --git a/source/ubinstall-gtk-source.c b/source/ubinstall-gtk-source.c index 77eb8e1..57924b9 100644 --- a/source/ubinstall-gtk-source.c +++ b/source/ubinstall-gtk-source.c @@ -174,6 +174,11 @@ void on_source_accept(GtkWidget *,source_window *window){ yon_ubl_status_highlight_incorrect(element->DeviceCombo); return; } + if (strstr(cur,",")){ + yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),PATH_INVALID_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE); + yon_ubl_status_highlight_incorrect(element->DeviceCombo); + return; + } char *temp = yon_char_append_element(sources_list,cur,","); if (!yon_char_is_empty(sources_list)) free(sources_list); sources_list = temp; @@ -187,7 +192,12 @@ void on_source_accept(GtkWidget *,source_window *window){ } if (yon_char_check_element(sources_list,cur,",")){ yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),VALUE_REPEAT_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE); - yon_ubl_status_highlight_incorrect(element->DeviceCombo); + yon_ubl_status_highlight_incorrect(element->PathEntry); + return; + } + if (strstr(cur,",")){ + yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),PATH_INVALID_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE); + yon_ubl_status_highlight_incorrect(element->PathEntry); return; } char *temp = yon_char_append_element(sources_list,cur,","); @@ -198,7 +208,12 @@ void on_source_accept(GtkWidget *,source_window *window){ char *cur = (char*)gtk_entry_get_text(GTK_ENTRY(element->PathEntry)); if (yon_char_check_element(sources_list,cur,",")){ yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),VALUE_REPEAT_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE); - yon_ubl_status_highlight_incorrect(element->DeviceCombo); + yon_ubl_status_highlight_incorrect(element->PathEntry); + return; + } + if (strstr(cur,",")){ + yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),PATH_INVALID_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE); + yon_ubl_status_highlight_incorrect(element->PathEntry); return; } char *temp = yon_char_append_element(sources_list,cur,","); diff --git a/source/ubinstall-gtk.c b/source/ubinstall-gtk.c index 9751093..61d9db7 100644 --- a/source/ubinstall-gtk.c +++ b/source/ubinstall-gtk.c @@ -237,6 +237,7 @@ void config_init(){ for (int i=0;iBootloadUserEditButton = yon_gtk_builder_get_widget(builder,"BootloadUserEditButton"); widgets->BootloadAdminCheckCell = GTK_CELL_RENDERER(gtk_builder_get_object(builder,"BootloadAdminCheckCell")); widgets->BootloadUserRemoveButton = yon_gtk_builder_get_widget(builder,"BootloadUserRemoveButton"); + widgets->BootloadNoPasswordSwitch = yon_gtk_builder_get_widget(builder,"BootloadNoPasswordSwitch"); widgets->BootloadUsersList = GTK_LIST_STORE(gtk_builder_get_object(builder,"BootloadUsersList")); widgets->NetworkDomainSwitch = yon_gtk_builder_get_widget(builder,"NetworkDomainSwitch"); @@ -883,6 +885,7 @@ void yon_main_window_create(main_window *widgets){ g_signal_connect(G_OBJECT(widgets->BootloadAdminCheckCell),"toggled",G_CALLBACK(on_bootloader_admin_toggled),widgets); g_signal_connect(G_OBJECT(widgets->BootloadUserRemoveButton),"clicked",G_CALLBACK(on_bootloader_user_remove),widgets); g_signal_connect(G_OBJECT(widgets->BootloadUserTree),"cursor-changed",G_CALLBACK(on_bootloader_selected),widgets); + g_signal_connect(G_OBJECT(widgets->BootloadNoPasswordSwitch),"state-set",G_CALLBACK(yon_gtk_widget_set_sensitive_from_switch),gtk_widget_get_parent(gtk_widget_get_parent(widgets->BootloadUserAddButton))); g_signal_connect(G_OBJECT(widgets->BootloadTimerSwitch),"state-set",G_CALLBACK(yon_gtk_widget_set_sensitive_from_switch),widgets->BootloadTimerSpin); @@ -1101,14 +1104,14 @@ main_window *yon_main_window_complete(){ } int main(int argc, char *argv[]){ - main_config.argv=argv; - main_config.argc = argc; config_str unfound = NULL; int size=0; opterr=0; yon_ubl_connect_config((_template_config*)&main_config); textdomain(LocaleName); config_init(); + main_config.argv=yon_char_parsed_copy(argv,argc); + main_config.argc = argc; gtk_init(&argc,&argv); yon_ubl_window_init(TITLE_LABEL,"",LocaleName,CssPath,LocaleName,version_application,WIKI_LINK); yon_ubl_setup_arguments(argc,argv,&unfound,&size,ADDITIONAL_ARGS); diff --git a/source/ubinstall-gtk.h b/source/ubinstall-gtk.h index f279cfc..509e1bd 100755 --- a/source/ubinstall-gtk.h +++ b/source/ubinstall-gtk.h @@ -157,7 +157,7 @@ layout && /description:/ {\ #define yon_check_database_command "pacman -Syy >/dev/null" #define internet_tomezone_check_command "curl -s ipinfo.io/timezone" -#define ubinstall_dry_run_command "/usr/bin/bash -c \"ubinstall --dry-run" +#define ubinstall_dry_run_command "/usr/bin/bash -c \"ubinstall --dry-run\"" #define os_name_get_command "sed -En 's/^PRETTY_NAME=[\"]*([^\"]+)[\"]*/\\1/p' /etc/os-release" #define get_keyboard_layout_change_command "grep \"grp:\" /usr/share/X11/xkb/rules/base.lst | awk '{$1=$1; sub(/^!.*$/, \"\"); if ($1 ~ /^grp:/) {opt=$1; $1=\"\"; print opt \"|\" substr($0,2)}}'" @@ -296,7 +296,7 @@ layout && /description:/ {\ #define get_localisation_command "ubconfig -ea --source global get [autoinstall] AUTOINSTALL[installer_locale] -- get [autoinstall] AUTOINSTALL['ubconfig set [locale] LANG'] -- get [locale] LANG" -#define save_config_command yon_char_unite("/usr/bin/bash -c \"nice ubinstall autoinstall",main_config.debug_mode?" --debug":""," --noautoconfig --noinstall_extra\"", NULL) +#define save_config_command yon_char_unite("/usr/bin/bash -c \"nice ubinstall autoinstall",main_config.debug_mode?" --debug":"","\"", NULL) #define quick_install_command(path) yon_char_unite("nice ubinstall autoinstall",main_config.debug_mode?" --debug":""," --config='",path,"' --noautoconfig --noinstall_extra", NULL) #define set_user_config_command yon_char_unite("nice ubinstall autoconfig",main_config.debug_mode?" --debug":""," install_extra", NULL) @@ -777,7 +777,7 @@ typedef struct GtkWidget *BootloadTimerSpin; GtkWidget *BootloadDefaultOSEntry; GtkWidget *BootloadDefaulOSButton; - // GtkWidget *BootloadNoPasswordSwitch; + GtkWidget *BootloadNoPasswordSwitch; GtkWidget *BootloadUserAddButton; GtkWidget *BootloadUserEditButton; GtkCellRenderer *BootloadAdminCheckCell; @@ -1642,4 +1642,5 @@ void yon_status_thread_update_active(main_window *widgets); void *yon_status_thread_update(main_window *widgets); void yon_db_lock_update(GFileMonitor *,GFile *,GFile *,GFileMonitorEvent ,main_window *widgets); void yon_db_unlock_update(GFileMonitor *,GFile *,GFile *,GFileMonitorEvent ,main_window *widgets); -void on_config_install_success(GtkWidget *self, int state, main_window *widgets); \ No newline at end of file +void on_config_install_success(GtkWidget *self, int state, main_window *widgets); +void *on_quick_install_start(void *data); \ No newline at end of file diff --git a/source/ubl-strings.h b/source/ubl-strings.h index 402aa72..fb0a0aa 100644 --- a/source/ubl-strings.h +++ b/source/ubl-strings.h @@ -207,6 +207,7 @@ NULL) #define CONFIGURATION_MODE_TITLE_LABEL _("Choose installation configuration file") #define SAVE_AND_EXIT_LABEL _("Save and exit") +#define EXIT_LABEL yon_char_get_localised_from_lib("Exit") #define NO_LABEL _("No") #define PARITY_INVALID_LABEL(target) yon_char_unite(_("Invalid devices parity. Needed:")," ",target,NULL) diff --git a/ubinstall-gtk.glade b/ubinstall-gtk.glade index 5022ba5..9629206 100644 --- a/ubinstall-gtk.glade +++ b/ubinstall-gtk.glade @@ -6598,6 +6598,7 @@ Select a different installation sources. True + False False 5 @@ -14513,7 +14514,7 @@ separately into the selected partition. 5 - Cancel + Exit True True True