1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-19 04:20:27 +01:00

WINGs: add missing source files for translation

As pointed by the new check script, many source files were not in the list
used for translation.

Took opportunity to make translatable a few messages that could help user.

Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
Christophe CURIS
2015-01-20 22:03:50 +01:00
committed by Carlos R. Mafra
parent b266808331
commit 6000af3828
7 changed files with 68 additions and 13 deletions

View File

@@ -1,3 +1,4 @@
#include "wconfig.h"
#include "WINGsP.h" #include "WINGsP.h"
@@ -56,7 +57,7 @@ WMDragOperationType W_ActionToOperation(WMScreen * scr, Atom action)
} else { } else {
char *tmp = XGetAtomName(scr->display, action); char *tmp = XGetAtomName(scr->display, action);
wwarning("unknown XDND action %s ", tmp); wwarning(_("unknown XDND action %s"), tmp);
XFree(tmp); XFree(tmp);
return WDOperationCopy; return WDOperationCopy;
@@ -138,7 +139,7 @@ W_SendDnDClientMessage(Display * dpy, Window win, Atom message,
#endif #endif
if (!windowExists(dpy, win)) { if (!windowExists(dpy, win)) {
wwarning("xdnd message target %lu does no longer exist.", win); wwarning(_("target %lu for xdnd message no longer exists"), win);
return False; /* message not sent */ return False; /* message not sent */
} }
@@ -216,7 +217,7 @@ void W_HandleDNDClientMessage(WMView * toplevel, XClientMessageEvent * event)
return; return;
} }
} else { } else {
wwarning("received dnd enter msg with unsupported version %i", XDND_SOURCE_VERSION(info)); wwarning(_("unsupported version %i for xdnd enter message"), XDND_SOURCE_VERSION(info));
W_DragDestinationCancelDropOnEnter(toplevel, info); W_DragDestinationCancelDropOnEnter(toplevel, info);
return; return;
} }

View File

@@ -160,7 +160,7 @@ static void selectionLost(WMView * view, Atom selection, void *cdata)
(void) selection; (void) selection;
(void) cdata; (void) cdata;
wwarning("DND selection lost during drag operation..."); wwarning(_("XDND selection lost during drag operation..."));
} }
static void selectionDone(WMView * view, Atom selection, Atom target, void *cdata) static void selectionDone(WMView * view, Atom selection, Atom target, void *cdata)
@@ -755,7 +755,7 @@ static void storeDestinationProtocolVersion(WMDraggingInfo * info)
XFree(winXdndVersion); XFree(winXdndVersion);
} else { } else {
XDND_DEST_VERSION(info) = 0; XDND_DEST_VERSION(info) = 0;
wwarning("failed to read XDND version of drop target"); wwarning(_("could not get XDND version for target of drop"));
} }
} }
@@ -771,7 +771,7 @@ static void initMotionProcess(WMView * view, WMDraggingInfo * info, XEvent * eve
XDND_TIMESTAMP(info) = event->xmotion.time; XDND_TIMESTAMP(info) = event->xmotion.time;
if (!WMCreateSelectionHandler(view, scr->xdndSelectionAtom, CurrentTime, XDND_SELECTION_PROCS(info), NULL)) { if (!WMCreateSelectionHandler(view, scr->xdndSelectionAtom, CurrentTime, XDND_SELECTION_PROCS(info), NULL)) {
wwarning("could not get ownership or DND selection"); wwarning(_("could not get ownership or DND selection"));
return; return;
} }
@@ -1067,7 +1067,7 @@ static void dragSourceResponseTimeOut(void *source)
WMView *view = (WMView *) source; WMView *view = (WMView *) source;
WMDraggingInfo *info = &(W_VIEW_SCREEN(view)->dragInfo); WMDraggingInfo *info = &(W_VIEW_SCREEN(view)->dragInfo);
wwarning("delay for drag destination response expired"); wwarning(_("delay for drag destination response expired"));
sendLeaveMessage(info); sendLeaveMessage(info);
recolorCursor(info, False); recolorCursor(info, False);

View File

@@ -6,18 +6,68 @@ CLEANFILES = $(CATALOGS) WINGs.pot
EXTRA_DIST = bg.po ca.po cs.po de.po fr.po hu.po nl.po sk.po EXTRA_DIST = bg.po ca.po cs.po de.po fr.po hu.po nl.po sk.po
# WUtil files:
POTFILES = \ POTFILES = \
$(top_srcdir)/WINGs/array.c \
$(top_srcdir)/WINGs/bagtree.c \
$(top_srcdir)/WINGs/data.c \
$(top_srcdir)/WINGs/error.c \ $(top_srcdir)/WINGs/error.c \
$(top_srcdir)/WINGs/findfile.c \ $(top_srcdir)/WINGs/findfile.c \
$(top_srcdir)/WINGs/handlers.c \
$(top_srcdir)/WINGs/hashtable.c \
$(top_srcdir)/WINGs/memory.c \
$(top_srcdir)/WINGs/menuparser.c \
$(top_srcdir)/WINGs/menuparser_macros.c \
$(top_srcdir)/WINGs/misc.c \
$(top_srcdir)/WINGs/notification.c \
$(top_srcdir)/WINGs/proplist.c \ $(top_srcdir)/WINGs/proplist.c \
$(top_srcdir)/WINGs/string.c \
$(top_srcdir)/WINGs/tree.c \
$(top_srcdir)/WINGs/userdefaults.c \ $(top_srcdir)/WINGs/userdefaults.c \
$(top_srcdir)/WINGs/usleep.c \
$(top_srcdir)/WINGs/wapplication.c \
$(top_srcdir)/WINGs/wutil.c
# WINGs files:
POTFILES += \
$(top_srcdir)/WINGs/configuration.c \
$(top_srcdir)/WINGs/dragcommon.c \
$(top_srcdir)/WINGs/dragdestination.c \
$(top_srcdir)/WINGs/dragsource.c \
$(top_srcdir)/WINGs/selection.c \
$(top_srcdir)/WINGs/wappresource.c \
$(top_srcdir)/WINGs/wballoon.c \
$(top_srcdir)/WINGs/wbox.c \
$(top_srcdir)/WINGs/wbrowser.c \
$(top_srcdir)/WINGs/wbutton.c \
$(top_srcdir)/WINGs/wcolor.c \ $(top_srcdir)/WINGs/wcolor.c \
$(top_srcdir)/WINGs/wcolorpanel.c \ $(top_srcdir)/WINGs/wcolorpanel.c \
$(top_srcdir)/WINGs/wcolorwell.c \
$(top_srcdir)/WINGs/wevent.c \
$(top_srcdir)/WINGs/wfilepanel.c \ $(top_srcdir)/WINGs/wfilepanel.c \
$(top_srcdir)/WINGs/wframe.c \
$(top_srcdir)/WINGs/wfont.c \ $(top_srcdir)/WINGs/wfont.c \
$(top_srcdir)/WINGs/wfontpanel.c \ $(top_srcdir)/WINGs/wfontpanel.c \
$(top_srcdir)/WINGs/widgets.c \ $(top_srcdir)/WINGs/widgets.c \
$(top_srcdir)/WINGs/wruler.c $(top_srcdir)/WINGs/winputmethod.c \
$(top_srcdir)/WINGs/wlabel.c \
$(top_srcdir)/WINGs/wlist.c \
$(top_srcdir)/WINGs/wmenuitem.c \
$(top_srcdir)/WINGs/wmisc.c \
$(top_srcdir)/WINGs/wpanel.c \
$(top_srcdir)/WINGs/wpixmap.c \
$(top_srcdir)/WINGs/wpopupbutton.c \
$(top_srcdir)/WINGs/wprogressindicator.c \
$(top_srcdir)/WINGs/wruler.c \
$(top_srcdir)/WINGs/wscroller.c \
$(top_srcdir)/WINGs/wscrollview.c \
$(top_srcdir)/WINGs/wslider.c \
$(top_srcdir)/WINGs/wsplitview.c \
$(top_srcdir)/WINGs/wtabview.c \
$(top_srcdir)/WINGs/wtext.c \
$(top_srcdir)/WINGs/wtextfield.c \
$(top_srcdir)/WINGs/wview.c \
$(top_srcdir)/WINGs/wwindow.c
SUFFIXES = .po .mo SUFFIXES = .po .mo

View File

@@ -479,7 +479,7 @@ WMScreen *WMOpenScreen(const char *display)
Display *dpy = XOpenDisplay(display); Display *dpy = XOpenDisplay(display);
if (!dpy) { if (!dpy) {
wwarning("WINGs: could not open display %s", XDisplayName(display)); wwarning(_("WINGs: could not open display %s"), XDisplayName(display));
return NULL; return NULL;
} }

View File

@@ -1,6 +1,8 @@
#include <X11/Xlib.h> #include <X11/Xlib.h>
#include "wconfig.h"
#include "WINGsP.h" #include "WINGsP.h"
typedef struct W_IMContext { typedef struct W_IMContext {
@@ -60,7 +62,7 @@ void W_InitIM(W_Screen * scr)
cb.callback = destroyIM_cb; cb.callback = destroyIM_cb;
cb.client_data = (XPointer) scr; cb.client_data = (XPointer) scr;
if (XSetIMValues(scr->imctx->xim, XNDestroyCallback, &cb, NULL)) if (XSetIMValues(scr->imctx->xim, XNDestroyCallback, &cb, NULL))
wwarning("could not add destroy callback for input method"); wwarning(_("could not add destroy callback for XIM input method"));
XUnregisterIMInstantiateCallback(scr->display, NULL, NULL, NULL, instantiateIM_cb, (XPointer) scr); XUnregisterIMInstantiateCallback(scr->display, NULL, NULL, NULL, instantiateIM_cb, (XPointer) scr);
/* Get available input style */ /* Get available input style */
XGetIMValues(scr->imctx->xim, XNQueryInputStyle, &im_styles, NULL); XGetIMValues(scr->imctx->xim, XNQueryInputStyle, &im_styles, NULL);

View File

@@ -491,7 +491,7 @@ void WMSetTextFieldAlignment(WMTextField * tPtr, WMAlignment alignment)
tPtr->flags.alignment = alignment; tPtr->flags.alignment = alignment;
if (alignment != WALeft) { if (alignment != WALeft) {
wwarning("only left alignment is supported in textfields"); wwarning(_("only left alignment is supported in textfields"));
return; return;
} }

View File

@@ -1,6 +1,8 @@
#include <X11/Xmd.h> #include <X11/Xmd.h>
#include "wconfig.h"
#include "WINGsP.h" #include "WINGsP.h"
#include "GNUstep.h" #include "GNUstep.h"
@@ -155,7 +157,7 @@ static void setWindowTitle(WMWindow * win, const char *title)
result = XmbTextListToTextProperty(scr->display, (char **)&title, 1, XStdICCTextStyle, &property); result = XmbTextListToTextProperty(scr->display, (char **)&title, 1, XStdICCTextStyle, &property);
if (result == XNoMemory || result == XLocaleNotSupported) { if (result == XNoMemory || result == XLocaleNotSupported) {
wwarning("window title conversion error... using STRING encoding"); wwarning(_("window title conversion error... using STRING encoding"));
XStoreName(scr->display, win->view->window, title); XStoreName(scr->display, win->view->window, title);
} else { } else {
XSetWMName(scr->display, win->view->window, &property); XSetWMName(scr->display, win->view->window, &property);
@@ -176,7 +178,7 @@ static void setMiniwindowTitle(WMWindow * win, const char *title)
result = XmbTextListToTextProperty(scr->display, (char **)&title, 1, XStdICCTextStyle, &property); result = XmbTextListToTextProperty(scr->display, (char **)&title, 1, XStdICCTextStyle, &property);
if (result == XNoMemory || result == XLocaleNotSupported) { if (result == XNoMemory || result == XLocaleNotSupported) {
wwarning("icon title conversion error..using STRING encoding"); wwarning(_("icon title conversion error... using STRING encoding"));
XSetIconName(scr->display, win->view->window, title); XSetIconName(scr->display, win->view->window, title);
} else { } else {
XSetWMIconName(scr->display, win->view->window, &property); XSetWMIconName(scr->display, win->view->window, &property);