summaryrefslogtreecommitdiff
path: root/sendto/caja-sendto-command.c
diff options
context:
space:
mode:
authorrbuj <[email protected]>2021-02-07 21:49:22 +0100
committerraveit65 <[email protected]>2021-02-08 21:23:34 +0100
commita8d98cb5572363804ffabd771055959826b32f99 (patch)
treea571b63a981e000fddb80ceac1013cee91bfec66 /sendto/caja-sendto-command.c
parent546660e4c8668f6f94c5d672499d253f70e4fa78 (diff)
downloadcaja-extensions-a8d98cb5572363804ffabd771055959826b32f99.tar.bz2
caja-extensions-a8d98cb5572363804ffabd771055959826b32f99.tar.xz
build: allow users to disable gettext support (--disable-nls)
Diffstat (limited to 'sendto/caja-sendto-command.c')
-rw-r--r--sendto/caja-sendto-command.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/sendto/caja-sendto-command.c b/sendto/caja-sendto-command.c
index 1574e7e..e7d3698 100644
--- a/sendto/caja-sendto-command.c
+++ b/sendto/caja-sendto-command.c
@@ -445,9 +445,13 @@ set_model_for_options_combobox (NS_ui *ui)
GTK_ICON_LOOKUP_USE_BUILTIN, NULL);
gtk_list_store_append (model, &iter);
gtk_list_store_set (model, &iter,
- COLUMN_ICON, pixbuf,
- COLUMN_DESCRIPTION, dgettext(p->info->gettext_package, p->info->description),
- -1);
+ COLUMN_ICON, pixbuf,
+#ifdef ENABLE_NLS
+ COLUMN_DESCRIPTION, g_dgettext (p->info->gettext_package, p->info->description),
+#else
+ COLUMN_DESCRIPTION, p->info->description,
+#endif /* ENABLE_NLS */
+ -1);
if (last_used != NULL && !strcmp(last_used, p->info->id)) {
option = i;
last_used_support_dirs = (p->info->capabilities & CAJA_CAPS_SEND_DIRECTORIES);
@@ -799,9 +803,11 @@ int main (int argc, char **argv)
GOptionContext *context;
GError *error = NULL;
+#ifdef ENABLE_NLS
bindtextdomain (GETTEXT_PACKAGE, MATELOCALEDIR);
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
textdomain (GETTEXT_PACKAGE);
+#endif /* ENABLE_NLS */
context = g_option_context_new ("");
g_option_context_add_main_entries (context, entries, GETTEXT_PACKAGE);