github tonikelope/megabasterd v8.50
MegaBasterd 8.50

latest release: v8.51
5 hours ago

TL;DR

  • Fixes #770 -- translation polish + UX wrinkles in the Settings dialog reported against 8.48. Three more strings that bypassed the i18n bundle are now routed through it (Always reload MEGA folders instead of using cached folder data, Default download directory, Java properties (UTF-8) (*.properties)), the ELC accounts table column headers (Host / User / API-KEY) are localised, the SmartProxy WARNING JLabel now honours \n in translations (Italian had \n\n since the v8.46 refactor but the label rendered it as a literal), and the external-translation-file picker (#766) opens at the MegaBasterd jar location with a roomier default size.
  • 3 new bundle keys added to every messages*.properties: always_reload_mega_folders, default_download_directory, java_properties_utf_8_filter. EN/ES/IT hand-authored; DE/HU/TR/VI/ZH machine-baseline, refinable by native speakers via #397.
  • Filled in missing ES/DE/VI/ZH translations for the existing user / api_key bundle keys, which had been carrying English literals -- so the new ELC header routing actually surfaces translated text outside IT/HU/TR. (Skipped the 8.49 release tag; the build that surfaced this gap was never useful in isolation.)

New in 8.50

#770 -- Translation polish in Settings

  • Always reload MEGA folders instead of using cached folder data checkbox (Downloads tab). The checkbox text was set via .form-generated initComponents but had no matching key in any bundle, so MiscTools.translateLabels inverted the English bundle, found no entry, and rendered the literal verbatim in every locale. Fix is a single new key always_reload_mega_folders per bundle; no code change required.

  • Default download directory JFileChooser title (Downloads tab -> Set folder button). The dialog title was passed as a raw English literal to setDialogTitle(...). Wrapped the call site in LabelTranslatorSingleton.getInstance().translate(...) so the new default_download_directory bundle key resolves at open time.

  • Java properties (UTF-8) (*.properties) file-filter description (Advanced tab -> Browse for the external-translation file picker shipped in #766). The filter description was a raw English literal in the FileNameExtensionFilter constructor. Same fix as above -- wrapped in the legacy translate(...) shim with a new java_properties_utf_8_filter bundle key per locale.

  • ELC accounts table column headers Host / User / API-KEY (Account tab, bottom table). MiscTools.translateLabels is the recursive component-tree walker that handles every translated label in the project, but it only enumerates JLabel, JButton, JCheckBox, JRadioButton, JMenuItem, JMenu (the JRadioButton case was added in 8.48 for #767). JTable column headers live in TableColumnModel and are not visited at all, so the headers shipped in raw English. Added a small translateAccountTableHeaders() helper that walks the ELC table's column model and routes each header through LabelTranslatorSingleton.translate(...). Called once from the constructor (after translateLabels(this)) and from both setModel(...) rebuilds (the master-pass unlock flow and the Delete all accounts flow). The two rebuild branches were also resetting the third header to "API KEY" with a space; aligned them with the form-defined "API-KEY" so the translation lookup succeeds in all three code paths. MEGA columns (Email / Password) are skipped: both terms render verbatim across every active bundle today, and the existing password key carries a trailing colon used by a different label, so routing "Password" through the inverter would no-op anyway.

    Sub-fix: the existing user / api_key bundle keys had been carrying raw English literals ("User", "API-KEY") as their values in messages_es, messages_de, messages_vi, and (for api_key only) messages_zh -- a copy-paste baseline from the original i18n refactor that had no visible consequence until the new header routing started consuming the keys. Filled them in with proper localised text: ES Usuario/Clave API, DE Benutzer/API-Schlüssel, VI Người dùng/Khóa API, ZH API 密钥. IT, HU, TR were already complete.

  • SmartProxy WARNING JLabel \n support. The Italian translation of warning_using_proxies_or_vpn_to_bypass_mega_s_daily has had \n\n in it since v8.46 to break the long "WARNING: Using proxies or VPN..." paragraph into two lines, but JLabel only renders newlines when the text is HTML-wrapped -- so the Italian (and the Chinese, which inherited a \n\n-using value, though its current value is a stale paste from a different key and is a separate cleanup task) rendered the \n as a literal and the label overflowed horizontally off the dialog. Re-emitted the translated WARNING wrapped in <html>...</html> with literal \n converted to <br> immediately after translateLabels(smart_proxy_settings) runs. Translators in any locale can now add \n to their bundle value to break the WARNING into multiple lines.

#770 -- External-translation-file picker UX

  • Default starting path = MegaBasterd jar directory. When the ext_lang_path_field is empty (no override is currently configured), the JFileChooser opened by ext_lang_browse_button now opens at the parent of the running jar via MiscTools.getCurrentJarParentPath(). Translators typically drop messages_xx.properties next to the jar, so this saves several scroll/click steps versus the JVM default (user home). Falls back to the JFileChooser default if the jar location cannot be resolved (e.g. running from an unpacked classpath).

  • Larger default JFileChooser size. Set setPreferredSize(900, 600) on the picker so deep directory trees need less scrolling. Same dialog as above (Advanced tab -> external translation file Browse).

i18n

Three new keys added to every messages*.properties bundle: always_reload_mega_folders, default_download_directory, java_properties_utf_8_filter. EN / ES / IT are hand-authored. DE / HU / TR / VI / ZH translated in the same style as the v8.37/v8.48 refactors (intended as a working baseline for native-speaker refinement via #397).

The two new ELC headers (User, API-KEY) and the SmartProxy WARNING reuse the existing keys (user, api_key, warning_using_proxies_or_vpn_to_bypass_mega_s_daily) which were already present in every bundle; only the call sites changed (and the four values noted above were filled in).

Other

  • Version bumped to 8.50 in pom.xml and MainPanel.VERSION.

Don't miss a new megabasterd release

NewReleases is sending notifications on new releases.