summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJasper Huijsmans <jbhuijsmans@home.nl>2004-08-22 16:55:47 +0000
committerJasper Huijsmans <jbhuijsmans@home.nl>2004-08-22 16:55:47 +0000
commit995497be3a739f1418a13df20fce088eb5937b4c (patch)
tree2938e2a2a194b07701c3879bb7617e5d102c0140
parent7a70d948b04bffb0211c19e400e11a880d298152 (diff)
This is better, should be temporary until I find out what's wrong.
(Old svn revision: 4108)
-rw-r--r--panel/add-control-dialog.c4
-rw-r--r--panel/controls.c11
-rw-r--r--panel/controls_dialog.c11
-rw-r--r--panel/item.c11
-rw-r--r--panel/item_dialog.c33
-rw-r--r--panel/main.c13
-rw-r--r--panel/panel.c23
7 files changed, 58 insertions, 48 deletions
diff --git a/panel/add-control-dialog.c b/panel/add-control-dialog.c
index bf5677de..7bd27af0 100644
--- a/panel/add-control-dialog.c
+++ b/panel/add-control-dialog.c
@@ -29,6 +29,10 @@
#include "add-control-dialog.h"
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
+
typedef struct
{
Panel *panel;
diff --git a/panel/controls.c b/panel/controls.c
index 5bd7c751..a0331cf7 100644
--- a/panel/controls.c
+++ b/panel/controls.c
@@ -62,8 +62,9 @@
#define UNLOAD_TIMEOUT 30000 /* 30 secs */
-/* make sure translations are taken from the panel not some plugin */
-#define dg_(s) dgettext (PACKAGE, s)
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
typedef struct _ControlClassInfo ControlClassInfo;
@@ -792,12 +793,12 @@ get_control_menu (void)
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_Properties..."));
+ mi = gtk_menu_item_new_with_mnemonic (_("_Properties..."));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (edit_control), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_Remove"));
+ mi = gtk_menu_item_new_with_mnemonic (_("_Remove"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (remove_control), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
@@ -806,7 +807,7 @@ get_control_menu (void)
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic(dg_("Add _new item"));
+ mi = gtk_menu_item_new_with_mnemonic(_("Add _new item"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (run_add_control_dialog),
NULL);
diff --git a/panel/controls_dialog.c b/panel/controls_dialog.c
index c6e377c0..5e7654be 100644
--- a/panel/controls_dialog.c
+++ b/panel/controls_dialog.c
@@ -41,8 +41,9 @@
#define BORDER 6
-/* make sure translations are taken from the panel not some plugin */
-#define dg_(s) dgettext (PACKAGE, s)
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
static GtkWidget *cdialog = NULL;
@@ -88,7 +89,7 @@ add_position_option (GtkBox *box, Control *control)
gtk_widget_show (hbox);
gtk_box_pack_start (box, hbox, FALSE, FALSE, 0);
- label = gtk_label_new (dg_("Position:"));
+ label = gtk_label_new (_("Position:"));
gtk_misc_set_alignment (GTK_MISC (label), 0, 0.5);
gtk_widget_show (label);
gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
@@ -148,7 +149,7 @@ controls_dialog (Control * control)
gtk_dialog_set_has_separator (dlg, FALSE);
- gtk_window_set_title (GTK_WINDOW (dlg), dg_("Item properties"));
+ gtk_window_set_title (GTK_WINDOW (dlg), _("Item properties"));
button = gtk_button_new_from_stock (GTK_STOCK_REMOVE);
gtk_widget_show (button);
@@ -200,7 +201,7 @@ retry:
pp = groups_get_popup (control->index);
if (!(control->with_popup) || !pp || pp->items == NULL ||
- xfce_confirm (dg_("Removing the item will also remove "
+ xfce_confirm (_("Removing the item will also remove "
"its popup menu."),
GTK_STOCK_REMOVE, NULL))
{
diff --git a/panel/item.c b/panel/item.c
index e9822574..c7e812e0 100644
--- a/panel/item.c
+++ b/panel/item.c
@@ -42,8 +42,9 @@
#include "item_dialog.h"
#include "settings.h"
-/* make sure translations are taken from the panel not some plugin */
-#define dg_(s) dgettext (PACKAGE, s)
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
static gboolean popup_from_timeout = FALSE;
static int popup_timeout_id = 0;
@@ -466,7 +467,7 @@ item_apply_config (Item * item)
}
else
{
- add_tooltip (item->button, dg_("Click mouse button 3 to change item"));
+ add_tooltip (item->button, _("Click mouse button 3 to change item"));
}
}
@@ -489,12 +490,12 @@ void
create_addtomenu_item (Item * mi)
{
mi->button =
- xfce_menubutton_new_with_stock_icon (dg_("Add launcher"),
+ xfce_menubutton_new_with_stock_icon (_("Add launcher"),
GTK_STOCK_ADD);
gtk_widget_show (mi->button);
gtk_button_set_relief (GTK_BUTTON (mi->button), GTK_RELIEF_NONE);
- add_tooltip (mi->button, dg_("Add new item"));
+ add_tooltip (mi->button, _("Add new item"));
/* signals */
dnd_set_drag_dest (mi->button);
diff --git a/panel/item_dialog.c b/panel/item_dialog.c
index 84328591..ccd40fb1 100644
--- a/panel/item_dialog.c
+++ b/panel/item_dialog.c
@@ -51,8 +51,9 @@
#define PREVIEW_SIZE 48
-/* make sure translations are taken from the panel not some plugin */
-#define dg_(s) dgettext (PACKAGE, s)
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
typedef struct _ItemDialog ItemDialog;
@@ -151,7 +152,7 @@ command_browse_cb (GtkWidget *w, CommandOptions *opts)
text = gtk_entry_get_text (GTK_ENTRY (opts->command_entry));
- file = select_file_name (dg_("Select command"), text,
+ file = select_file_name (_("Select command"), text,
gtk_widget_get_toplevel (opts->base));
if (file)
@@ -294,7 +295,7 @@ create_command_options (GtkSizeGroup *sg)
gtk_widget_show (hbox);
gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, TRUE, 0);
- w = gtk_label_new (dg_("Command:"));
+ w = gtk_label_new (_("Command:"));
gtk_misc_set_alignment (GTK_MISC (w), 0, 0.5);
gtk_widget_show (w);
gtk_box_pack_start (GTK_BOX (hbox), w, FALSE, FALSE, 0);
@@ -353,7 +354,7 @@ create_command_options (GtkSizeGroup *sg)
/* terminal */
opts->term_checkbutton = w =
- gtk_check_button_new_with_mnemonic (dg_("Run in _terminal"));
+ gtk_check_button_new_with_mnemonic (_("Run in _terminal"));
gtk_widget_show (w);
gtk_box_pack_start (GTK_BOX (hbox), w, FALSE, FALSE, 0);
@@ -372,7 +373,7 @@ create_command_options (GtkSizeGroup *sg)
gtk_size_group_add_widget (sg, w);
opts->sn_checkbutton = w =
- gtk_check_button_new_with_mnemonic (dg_("Use startup _notification"));
+ gtk_check_button_new_with_mnemonic (_("Use startup _notification"));
gtk_widget_show (w);
gtk_box_pack_start (GTK_BOX (hbox), w, FALSE, FALSE, 0);
@@ -566,7 +567,7 @@ create_icon_option_menu (void)
menu = gtk_menu_new ();
- mi = gtk_menu_item_new_with_label (dg_("Other Icon"));
+ mi = gtk_menu_item_new_with_label (_("Other Icon"));
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
@@ -605,7 +606,7 @@ icon_browse_cb (GtkWidget *w, IconOptions *opts)
text = gtk_entry_get_text (GTK_ENTRY (opts->icon_entry));
- file = select_file_with_preview (dg_("Select command"), text,
+ file = select_file_with_preview (_("Select command"), text,
gtk_widget_get_toplevel (opts->base));
if (file && g_file_test (file, G_FILE_TEST_EXISTS) &&
@@ -676,7 +677,7 @@ create_icon_preview_frame (IconOptions *opts)
gtk_widget_show (frame);
eventbox = gtk_event_box_new ();
- add_tooltip (eventbox, dg_("Drag file onto this frame to change the icon"));
+ add_tooltip (eventbox, _("Drag file onto this frame to change the icon"));
gtk_widget_show (eventbox);
gtk_container_add (GTK_CONTAINER (frame), eventbox);
@@ -962,7 +963,7 @@ add_caption_option (GtkBox *box, ItemDialog *idlg, GtkSizeGroup *sg)
gtk_widget_show (hbox);
gtk_box_pack_start (box, hbox, FALSE, TRUE, 0);
- label = gtk_label_new (dg_("Caption:"));
+ label = gtk_label_new (_("Caption:"));
gtk_misc_set_alignment (GTK_MISC (label), 0, 0.5);
gtk_size_group_add_widget (sg, label);
gtk_widget_show (label);
@@ -991,7 +992,7 @@ add_tooltip_option (GtkBox *box, ItemDialog *idlg, GtkSizeGroup *sg)
gtk_widget_show (hbox);
gtk_box_pack_start (box, hbox, FALSE, TRUE, 0);
- label = gtk_label_new (dg_("Tooltip:"));
+ label = gtk_label_new (_("Tooltip:"));
gtk_misc_set_alignment (GTK_MISC (label), 0, 0.5);
gtk_size_group_add_widget (sg, label);
gtk_widget_show (label);
@@ -1019,7 +1020,7 @@ static inline void
add_menu_option (GtkBox *box, ItemDialog *idlg, GtkSizeGroup *sg)
{
idlg->menu_checkbutton =
- gtk_check_button_new_with_label (dg_("Attach menu to launcher"));
+ gtk_check_button_new_with_label (_("Attach menu to launcher"));
gtk_widget_show (idlg->menu_checkbutton);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (idlg->menu_checkbutton),
idlg->item->with_popup);
@@ -1200,7 +1201,7 @@ add_position_option (GtkBox *box, Item *item, int num_items)
gtk_widget_show (hbox);
gtk_box_pack_start (box, hbox, FALSE, FALSE, 0);
- label = gtk_label_new (dg_("Position:"));
+ label = gtk_label_new (_("Position:"));
gtk_misc_set_alignment (GTK_MISC (label), 0, 0.5);
gtk_widget_show (label);
gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
@@ -1234,13 +1235,13 @@ edit_menu_item_dialog (Item * mi)
menudialog = gtk_dialog_new ();
dlg = GTK_DIALOG (menudialog);
- gtk_window_set_title (GTK_WINDOW (dlg), dg_("Change menu item"));
+ gtk_window_set_title (GTK_WINDOW (dlg), _("Change menu item"));
gtk_window_set_position (GTK_WINDOW (dlg), GTK_WIN_POS_CENTER);
gtk_dialog_set_has_separator (dlg, FALSE);
/* add buttons */
- remove = xfce_create_mixed_button (GTK_STOCK_REMOVE, dg_("_Remove"));
+ remove = xfce_create_mixed_button (GTK_STOCK_REMOVE, _("_Remove"));
gtk_widget_show (remove);
gtk_dialog_add_action_widget (dlg, remove, GTK_RESPONSE_CANCEL);
@@ -1252,7 +1253,7 @@ edit_menu_item_dialog (Item * mi)
gtk_button_box_set_child_secondary (GTK_BUTTON_BOX(dlg->action_area),
remove, TRUE);
- header = xfce_create_header (NULL, dg_("Launcher"));
+ header = xfce_create_header (NULL, _("Launcher"));
gtk_container_set_border_width (GTK_CONTAINER (GTK_BIN (header)->child),
BORDER);
gtk_widget_set_size_request (header, -1, 32);
diff --git a/panel/main.c b/panel/main.c
index 7995ee27..15f99400 100644
--- a/panel/main.c
+++ b/panel/main.c
@@ -62,8 +62,9 @@
"style \"popupbutton\" { GtkWidget::focus-padding = 0 }\n" \
"class \"XfceTogglebutton\" style \"popupbutton\"\n"
-/* make sure translations are taken from the panel not some plugin */
-#define dg_(s) dgettext (PACKAGE, s)
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
/* signal handling */
typedef enum
@@ -119,7 +120,7 @@ quit (gboolean force)
logout_session (client_session);
return;
}
- else if (!xfce_confirm (dg_("Are you sure you want to exit?"),
+ else if (!xfce_confirm (_("Are you sure you want to exit?"),
GTK_STOCK_QUIT, NULL))
{
return;
@@ -326,7 +327,7 @@ main (int argc, char **argv)
(strequal (argv[1], "-v") || strequal (argv[1], "--version") ||
strequal (argv[1], "-h") || strequal (argv[1], "--help")))
{
- g_print (dg_("\n"
+ g_print (_("\n"
" The Xfce Panel\n"
" Version %s\n\n"
" Part of the Xfce Desktop Environment\n"
@@ -395,12 +396,12 @@ main (int argc, char **argv)
#if DEBUG
if (!session_managed)
{
- g_message (dg_("%s: Successfully started without session management"),
+ g_message (_("%s: Successfully started without session management"),
PACKAGE);
}
else
{
- g_message (dg_("%s: Successfully started with session management"),
+ g_message (_("%s: Successfully started with session management"),
PACKAGE);
}
#endif
diff --git a/panel/panel.c b/panel/panel.c
index 107e21b9..985ad3ce 100644
--- a/panel/panel.c
+++ b/panel/panel.c
@@ -45,8 +45,9 @@
#define SNAP_WIDTH 25
-/* make sure translations are taken from the panel not some plugin */
-#define dg_(s) dgettext (PACKAGE, s)
+/* Make sure translations are taken from the panel and not from some plugin */
+#undef _
+#define _(s) dgettext (PACKAGE, s)
/* typedefs *
* -------- */
@@ -554,7 +555,7 @@ get_handle_menu (void)
menu = gtk_menu_new ();
- mi = gtk_menu_item_new_with_label(dg_("Xfce Panel"));
+ mi = gtk_menu_item_new_with_label(_("Xfce Panel"));
gtk_widget_show (mi);
gtk_widget_set_sensitive (mi, FALSE);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
@@ -563,7 +564,7 @@ get_handle_menu (void)
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic(dg_("Add _new item"));
+ mi = gtk_menu_item_new_with_mnemonic(_("Add _new item"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (run_add_control_dialog),
NULL);
@@ -573,17 +574,17 @@ get_handle_menu (void)
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_Properties..."));
+ mi = gtk_menu_item_new_with_mnemonic (_("_Properties..."));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (edit_prefs), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_About Xfce"));
+ mi = gtk_menu_item_new_with_mnemonic (_("_About Xfce"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (do_info), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_Help"));
+ mi = gtk_menu_item_new_with_mnemonic (_("_Help"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (do_help), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
@@ -592,12 +593,12 @@ get_handle_menu (void)
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_Lock screen"));
+ mi = gtk_menu_item_new_with_mnemonic (_("_Lock screen"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (lock_screen), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("_Restart"));
+ mi = gtk_menu_item_new_with_mnemonic (_("_Restart"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (restart_panel), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
@@ -606,7 +607,7 @@ get_handle_menu (void)
gtk_widget_show (mi);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
- mi = gtk_menu_item_new_with_mnemonic (dg_("E_xit"));
+ mi = gtk_menu_item_new_with_mnemonic (_("E_xit"));
gtk_widget_show (mi);
g_signal_connect (mi, "activate", G_CALLBACK (exit_panel), NULL);
gtk_menu_shell_append (GTK_MENU_SHELL (menu), mi);
@@ -956,7 +957,7 @@ create_panel_window (Panel * p)
w = gtk_window_new (GTK_WINDOW_TOPLEVEL);
window = GTK_WINDOW (w);
- gtk_window_set_title (window, dg_("Xfce Panel"));
+ gtk_window_set_title (window, _("Xfce Panel"));
gtk_window_set_decorated (window, FALSE);
gtk_window_set_resizable (window, FALSE);
gtk_window_stick (window);