diff --git a/bauh/gems/web/controller.py b/bauh/gems/web/controller.py index eb21fac9..b13556b8 100644 --- a/bauh/gems/web/controller.py +++ b/bauh/gems/web/controller.py @@ -165,26 +165,25 @@ class WebApplicationManager(SoftwareManager): bt_continue = self.i18n['continue'].capitalize() - option_single_instance = InputOption(label=self.i18n['web.install.option.single.label'], value="--single-instance", tooltip=self.i18n['web.install.option.single.tip']) - option_maximized = InputOption(label=self.i18n['web.install.option.max.label'], value="--maximize", tooltip=self.i18n['web.install.option.max.tip']) - option_fullscren = InputOption(label=self.i18n['web.install.option.fullscreen.label'], value="--full-screen", tooltip=self.i18n['web.install.option.fullscreen.tip']) - option_no_frame = InputOption(label=self.i18n['web.install.option.noframe.label'], value="--hide-window-frame", tooltip=self.i18n['web.install.option.noframe.tip']) + op_single = InputOption(label=self.i18n['web.install.option.single.label'], value="--single-instance", tooltip=self.i18n['web.install.option.single.tip']) + op_max = InputOption(label=self.i18n['web.install.option.max.label'], value="--maximize", tooltip=self.i18n['web.install.option.max.tip']) + op_fs = InputOption(label=self.i18n['web.install.option.fullscreen.label'], value="--full-screen", tooltip=self.i18n['web.install.option.fullscreen.tip']) + op_nframe = InputOption(label=self.i18n['web.install.option.noframe.label'], value="--hide-window-frame", tooltip=self.i18n['web.install.option.noframe.tip']) + op_ncache = InputOption(label=self.i18n['web.install.option.nocache.label'], value="--clear-cache", tooltip=self.i18n['web.install.option.nocache.tip']) + op_insecure = InputOption(label=self.i18n['web.install.option.insecure.label'], value="--insecure", tooltip=self.i18n['web.install.option.insecure.tip']) + op_igcert = InputOption(label=self.i18n['web.install.option.ignore_certificate.label'], value="--ignore-certificate", tooltip=self.i18n['web.install.option.ignore_certificate.tip']) - tray_option_off = InputOption(label=self.i18n['web.install.option.tray.off.label'], value=0, tooltip=self.i18n['web.install.option.tray.off.tip']) - tray_option_default = InputOption(label=self.i18n['web.install.option.tray.default.label'], value='--tray', tooltip=self.i18n['web.install.option.tray.default.tip']) - tray_option_min = InputOption(label=self.i18n['web.install.option.tray.min.label'], value='--tray=start-in-tray', tooltip=self.i18n['web.install.option.tray.min.tip']) - input_tray = SingleSelectComponent(type_=SelectViewType.COMBO, options=[tray_option_off, tray_option_default, tray_option_min], label=self.i18n['web.install.option.tray.label']) - check_options = MultipleSelectComponent(options=[option_single_instance, option_maximized, option_fullscren, option_no_frame], - default_options={option_single_instance}, label='') + tray_op_off = InputOption(label=self.i18n['web.install.option.tray.off.label'], value=0, tooltip=self.i18n['web.install.option.tray.off.tip']) + tray_op_default = InputOption(label=self.i18n['web.install.option.tray.default.label'], value='--tray', tooltip=self.i18n['web.install.option.tray.default.tip']) + tray_op_min = InputOption(label=self.i18n['web.install.option.tray.min.label'], value='--tray=start-in-tray', tooltip=self.i18n['web.install.option.tray.min.tip']) + + check_options = MultipleSelectComponent(options=[op_single, op_max, op_fs, op_nframe, op_ncache, op_insecure, op_igcert], default_options={op_single}, label='') + input_tray = SingleSelectComponent(type_=SelectViewType.COMBO, options=[tray_op_off, tray_op_default, tray_op_min], label=self.i18n['web.install.option.tray.label']) # input_internal_urls = TextInput() - components = [ - check_options, - input_tray - ] res = watcher.request_confirmation(title=self.i18n['web.install.options_dialog.title'], body=self.i18n['web.install.options_dialog.body'].format(bold(bt_continue)), - components=components, + components=[check_options, input_tray], confirmation_label=bt_continue, deny_label=self.i18n['cancel'].capitalize()) @@ -194,7 +193,7 @@ class WebApplicationManager(SoftwareManager): if check_options.values: selected.extend(check_options.get_selected_values()) - if input_tray.value != 0: + if input_tray.value: selected.append(input_tray.get_selected_value()) return res, selected diff --git a/bauh/gems/web/resources/locale/en b/bauh/gems/web/resources/locale/en index 0978b293..280e2984 100644 --- a/bauh/gems/web/resources/locale/en +++ b/bauh/gems/web/resources/locale/en @@ -19,6 +19,12 @@ web.install.option.fullscreen.label=Open in fullscreen web.install.option.fullscreen.tip=If the app should always be opened in fullscreen web.install.option.noframe.label=No frame web.install.option.noframe.tip=If the app should not have a frame around it ( like browsers have ) +web.install.option.nocache.label=No cache +web.install.option.nocache.tip=Session data will not be stored after the app is closed +web.install.option.insecure.label=Allow insecure content +web.install.option.insecure.tip=It allows the execution of insecure content within the application +web.install.option.ignore_certificate.label=Ignore certificate errors +web.install.option.ignore_certificate.tip=Certificate related errors will be ignored by the app web.install.option.tray.label=Tray mode web.install.option.tray.off.label=Off web.install.option.tray.off.tip=Off diff --git a/bauh/gems/web/resources/locale/pt b/bauh/gems/web/resources/locale/pt index 300e7219..a357dd4a 100644 --- a/bauh/gems/web/resources/locale/pt +++ b/bauh/gems/web/resources/locale/pt @@ -19,6 +19,12 @@ web.install.option.fullscreen.label=Abrir em tela cheia web.install.option.fullscreen.tip=Se o aplicativo sempre deve ser aberto em tela cheia web.install.option.noframe.label=Sem moldura web.install.option.noframe.tip=Se o aplicativo não deve ter uma moldura em volta ( como os navegadores têm ) +web.install.option.nocache.label=Sem cache +web.install.option.nocache.tip=Dados de sessão não serão armazenados após o aplicativo ser fechado +web.install.option.insecure.label=Permitir conteúdo não confiável +web.install.option.insecure.tip=Permite a execução de conteúdo não confiável dentro do aplicativo +web.install.option.ignore_certificate.label=Ignorar erros de certificado +web.install.option.ignore_certificate.tip=Erros associados a certificados serão ignorados pelo aplicativo web.install.option.tray.label=Modo bandeja web.install.option.tray.off.label=Desligado web.install.option.tray.off.tip=Desligado