diff options
author | Mohammed Sadiq <sadiq@sadiqpk.org> | 2020-08-17 16:13:02 +0530 |
---|---|---|
committer | Benjamin Berg <benjamin@sipsolutions.net> | 2020-08-18 08:48:16 +0000 |
commit | e31b57a8d8219f6f2b3e3948a06dae93cde1845e (patch) | |
tree | 7c353eee14670a533db36514a8a921f3bf5c077d /plugins | |
parent | 71b7021a35dd7f0606013b20c78d3bcc38449188 (diff) | |
download | gnome-settings-daemon-e31b57a8d8219f6f2b3e3948a06dae93cde1845e.tar.gz |
wwan: Don't split strings marked for translation
Splitting strings won't work right in many languages, and makes
the life of translators harder.
See https://gitlab.gnome.org/GNOME/gnome-settings-daemon/-/merge_requests/174#note_890827, #548
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/wwan/cc-wwan-device.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/plugins/wwan/cc-wwan-device.c b/plugins/wwan/cc-wwan-device.c index 7ecfee14..57b869b7 100644 --- a/plugins/wwan/cc-wwan-device.c +++ b/plugins/wwan/cc-wwan-device.c @@ -975,6 +975,13 @@ cc_wwan_device_get_string_from_mode (CcWwanDevice *self, g_return_val_if_fail (CC_IS_WWAN_DEVICE (self), NULL); g_return_val_if_fail (allowed != 0, NULL); + if (allowed == MM_MODEM_MODE_2G) + return g_strdup (_("2G Only")); + if (allowed == MM_MODEM_MODE_3G) + return g_strdup (_("3G Only")); + if (allowed == MM_MODEM_MODE_4G) + return g_strdup (_("4G Only")); + str = g_string_sized_new (10); if (allowed & MM_MODEM_MODE_2G) @@ -984,11 +991,6 @@ cc_wwan_device_get_string_from_mode (CcWwanDevice *self, if (allowed & MM_MODEM_MODE_4G) APPEND_MODE_TO_STRING (str, MM_MODEM_MODE_4G, preferred, "4G"); - if (allowed == MM_MODEM_MODE_2G || - allowed == MM_MODEM_MODE_3G || - allowed == MM_MODEM_MODE_4G) - g_string_append (str, _(" Only")); - if (str->len == 0) return g_string_free (str, TRUE); else |