From 62a786955dda4c06f91877915f17cecd80f3a860 Mon Sep 17 00:00:00 2001 From: Jonathan Harris Date: Sat, 9 Jan 2016 17:18:55 +0000 Subject: [PATCH] Update EDSM autoopen translations. For consistency move it into its own setting. --- EDMarketConnector.py | 2 +- L10n/en.template | 2 +- L10n/es.strings | 3 +++ L10n/fr.strings | 3 +++ L10n/it.strings | 3 +++ L10n/lv.strings | 3 +++ L10n/nl.strings | 3 +++ L10n/ru.strings | 3 +++ L10n/uk.strings | 3 +++ config.py | 1 - prefs.py | 8 ++++---- 11 files changed, 27 insertions(+), 7 deletions(-) diff --git a/EDMarketConnector.py b/EDMarketConnector.py index 65704216..81008191 100755 --- a/EDMarketConnector.py +++ b/EDMarketConnector.py @@ -474,7 +474,7 @@ class AppWindow: result = self.edsm.result if result['done']: self.system['image'] = result['img'] - if result['uncharted'] and (config.getint('output') & config.EDSM_AUTOOPEN): + if result['uncharted'] and config.getint('edsm_autoopen'): webbrowser.open(result['url']) else: self.w.after(int(EDSM_POLL * 1000), self.edsmpoll) diff --git a/L10n/en.template b/L10n/en.template index c9385220..697a8f41 100644 --- a/L10n/en.template +++ b/L10n/en.template @@ -23,7 +23,7 @@ "Automatically make a log entry on entering a system" = "Automatically make a log entry on entering a system"; /* [prefs.py] */ -"Automatically open uncharted systems' EDSM pages" = "Automatically open uncharted systems' EDSM pages"; +"Automatically open uncharted systems’ EDSM pages" = "Automatically open uncharted systems’ EDSM pages"; /* Cmdr stats. [stats.py] */ "Balance" = "Balance"; diff --git a/L10n/es.strings b/L10n/es.strings index 3df4c75b..83a74ba7 100644 --- a/L10n/es.strings +++ b/L10n/es.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Crear automáticamente una entrada en el registro al entrar en un sistema"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Abrir automáticamente sistemas no cartografiados en EDSM"; + /* Cmdr stats. [stats.py] */ "Balance" = "Saldo"; diff --git a/L10n/fr.strings b/L10n/fr.strings index ab6436dc..2dd5ea83 100644 --- a/L10n/fr.strings +++ b/L10n/fr.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Ajouter automatiquement une entrée au journal en entrant dans un système"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Ouvrir automatiquement les pages EDSM des systèmes inexplorés"; + /* Cmdr stats. [stats.py] */ "Balance" = "Solde"; diff --git a/L10n/it.strings b/L10n/it.strings index f0f64981..28b29a41 100644 --- a/L10n/it.strings +++ b/L10n/it.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Inserisce automaticamente una log entry entrando in un sistema"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Apre automaticamente una pagina su EDSM dei sistemi non esplorati"; + /* Cmdr stats. [stats.py] */ "Balance" = "Saldo"; diff --git a/L10n/lv.strings b/L10n/lv.strings index ddeefd6c..6c74f15b 100644 --- a/L10n/lv.strings +++ b/L10n/lv.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Automātiski veikt ierakstu ierodoties sistēmā"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Automātiski atvērt neatklāto sistēmu EDSM lapas"; + /* Cmdr stats. [stats.py] */ "Balance" = "Bilance"; diff --git a/L10n/nl.strings b/L10n/nl.strings index 71e02207..32a93da3 100644 --- a/L10n/nl.strings +++ b/L10n/nl.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Automatisch een log regel aanmaken bij het binnengaan van een stelsel"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Automatisch openen van nog niet in kaart gebrachte systemen op EDSM website"; + /* Cmdr stats. [stats.py] */ "Balance" = "Balans"; diff --git a/L10n/ru.strings b/L10n/ru.strings index 24f71e52..da679804 100644 --- a/L10n/ru.strings +++ b/L10n/ru.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Автоматически заносить в журнал полета каждую посещённую систему"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Автоматически открывать EDSM для неисследованных систем"; + /* Cmdr stats. [stats.py] */ "Balance" = "Баланс"; diff --git a/L10n/uk.strings b/L10n/uk.strings index b9121245..a3e63738 100644 --- a/L10n/uk.strings +++ b/L10n/uk.strings @@ -22,6 +22,9 @@ /* Output setting. [prefs.py] */ "Automatically make a log entry on entering a system" = "Автоматично робити запис у журналі на вході в систему"; +/* [prefs.py] */ +"Automatically open uncharted systems’ EDSM pages" = "Автоматично відкривати сторінки EDSM для незвіданих систем"; + /* Cmdr stats. [stats.py] */ "Balance" = "Баланс"; diff --git a/config.py b/config.py index e38486a6..3d19ba5a 100644 --- a/config.py +++ b/config.py @@ -80,7 +80,6 @@ class Config: OUT_SHIP_CORIOLIS = 128 OUT_LOG_EDSM = 256 OUT_LOG_AUTO = 512 - EDSM_AUTOOPEN = 1024 if platform=='darwin': diff --git a/prefs.py b/prefs.py index e301e053..d7514bd2 100644 --- a/prefs.py +++ b/prefs.py @@ -157,8 +157,8 @@ class PreferencesDialog(tk.Toplevel): ttk.Separator(edsmframe, orient=tk.HORIZONTAL).grid(columnspan=2, padx=PADX, pady=PADY, sticky=tk.EW) self.out_log_edsm = tk.IntVar(value = (output & config.OUT_LOG_EDSM) and 1) nb.Checkbutton(edsmframe, text=_('Send flight log to Elite Dangerous Star Map'), variable=self.out_log_edsm, command=self.outvarchanged).grid(columnspan=2, padx=BUTTONX, sticky=tk.W) - self.edsm_autoopen = tk.IntVar(value = (output & config.EDSM_AUTOOPEN) and 1) - self.edsm_autoopen_button = nb.Checkbutton(edsmframe, text=_("Automatically open uncharted systems' EDSM pages"), variable=self.edsm_autoopen) + self.edsm_autoopen = tk.BooleanVar(value = config.getint('edsm_autoopen')) + self.edsm_autoopen_button = nb.Checkbutton(edsmframe, text=_(u"Automatically open uncharted systems’ EDSM pages"), variable=self.edsm_autoopen) self.edsm_autoopen_button.grid(columnspan=2, padx=BUTTONX, sticky=tk.W) if monitor.logdir: self.edsm_log_auto_button = nb.Checkbutton(edsmframe, text=_('Automatically make a log entry on entering a system'), variable=self.out_log_auto, command=self.outvarchanged) # Output setting @@ -371,10 +371,10 @@ class PreferencesDialog(tk.Toplevel): (self.out_log_file.get() and config.OUT_LOG_FILE) + (self.out_ship_coriolis.get() and config.OUT_SHIP_CORIOLIS) + (self.out_log_edsm.get() and config.OUT_LOG_EDSM) + - (self.out_log_auto.get() and config.OUT_LOG_AUTO) + - (self.edsm_autoopen.get() and config.EDSM_AUTOOPEN)) + (self.out_log_auto.get() and config.OUT_LOG_AUTO)) config.set('outdir', self.outdir.get().startswith('~') and join(config.home, self.outdir.get()[2:]) or self.outdir.get()) + config.set('edsm_autoopen', self.edsm_autoopen.get()) config.set('edsm_cmdrname', self.edsm_cmdr.get().strip()) config.set('edsm_apikey', self.edsm_apikey.get().strip())