mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-24 23:22:30 +01:00
wmaker: add missing source files for translation
As pointed by the new script, a number of source file were not included in the list of files to check for translations. Took opportunity to make translatable a few of the messages. Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
committed by
Carlos R. Mafra
parent
6000af3828
commit
609b3c29a6
@@ -91,11 +91,11 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
char rtext[300];
|
||||
|
||||
if (sscanf(slist[*index], "%i %i %n", &command, &code, &pos) < 2 || command != wmBeginMenu) {
|
||||
wwarning("appmenu: bad menu entry \"%s\" in window %lx", slist[*index], win);
|
||||
wwarning(_("appmenu: bad menu entry \"%s\" in window %lx"), slist[*index], win);
|
||||
return NULL;
|
||||
}
|
||||
if (wstrlcpy(title, &slist[*index][pos], sizeof(title)) >= sizeof(title)) {
|
||||
wwarning("appmenu: menu command size exceeded in window %lx", win);
|
||||
wwarning(_("appmenu: menu command size exceeded in window %lx"), win);
|
||||
return NULL;
|
||||
}
|
||||
menu = wMenuCreateForApp(scr, title, *index == 1);
|
||||
@@ -107,7 +107,7 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
|
||||
if (sscanf(slist[*index], "%i", &command) != 1) {
|
||||
wMenuDestroy(menu, True);
|
||||
wwarning("appmenu: bad menu entry \"%s\" in window %lx", slist[*index], win);
|
||||
wwarning(_("appmenu: bad menu entry \"%s\" in window %lx"), slist[*index], win);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -123,7 +123,7 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
if (sscanf(slist[*index], "%i %i %i %i %n",
|
||||
&command, &ecode, &etag, &enab, &pos) != 4 || ecode != code) {
|
||||
wMenuDestroy(menu, True);
|
||||
wwarning("appmenu: bad menu entry \"%s\" in window %lx",
|
||||
wwarning(_("appmenu: bad menu entry \"%s\" in window %lx"),
|
||||
slist[*index], win);
|
||||
return NULL;
|
||||
}
|
||||
@@ -133,14 +133,14 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
if (sscanf(slist[*index], "%i %i %i %i %s %n",
|
||||
&command, &ecode, &etag, &enab, rtext, &pos) != 5 || ecode != code) {
|
||||
wMenuDestroy(menu, True);
|
||||
wwarning("appmenu: bad menu entry \"%s\" in window %lx",
|
||||
wwarning(_("appmenu: bad menu entry \"%s\" in window %lx"),
|
||||
slist[*index], win);
|
||||
return NULL;
|
||||
}
|
||||
wstrlcpy(title, &slist[*index][pos], sizeof(title));
|
||||
}
|
||||
if (!(data = malloc(sizeof(WAppMenuData)))) {
|
||||
wwarning("appmenu: out of memory making menu for window %lx", win);
|
||||
wwarning(_("appmenu: out of memory making menu for window %lx"), win);
|
||||
wMenuDestroy(menu, True);
|
||||
return NULL;
|
||||
}
|
||||
@@ -150,7 +150,7 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
entry = wMenuAddCallback(menu, title, notifyClient, data);
|
||||
if (!entry) {
|
||||
wMenuDestroy(menu, True);
|
||||
wwarning("appmenu: out of memory creating menu for window %lx", win);
|
||||
wwarning(_("appmenu: out of memory creating menu for window %lx"), win);
|
||||
free(data);
|
||||
return NULL;
|
||||
}
|
||||
@@ -169,7 +169,7 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
if (sscanf(slist[*index], "%i %i %i %i %i %n",
|
||||
&command, &ecode, &etag, &enab, &ncode, &pos) != 5 || ecode != code) {
|
||||
wMenuDestroy(menu, True);
|
||||
wwarning("appmenu: bad menu entry \"%s\" in window %lx", slist[*index], win);
|
||||
wwarning(_("appmenu: bad menu entry \"%s\" in window %lx"), slist[*index], win);
|
||||
|
||||
return NULL;
|
||||
}
|
||||
@@ -183,7 +183,7 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
if (!entry) {
|
||||
wMenuDestroy(menu, True);
|
||||
wMenuDestroy(submenu, True);
|
||||
wwarning("appmenu: out of memory creating menu for window %lx", win);
|
||||
wwarning(_("appmenu: out of memory creating menu for window %lx"), win);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -191,7 +191,7 @@ static WMenu *parseMenuCommand(WScreen * scr, Window win, char **slist, int coun
|
||||
|
||||
} else {
|
||||
wMenuDestroy(menu, True);
|
||||
wwarning("appmenu: bad menu entry \"%s\" in window %lx", slist[*index], win);
|
||||
wwarning(_("appmenu: bad menu entry \"%s\" in window %lx"), slist[*index], win);
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
@@ -215,7 +215,7 @@ WMenu *wAppMenuGet(WScreen * scr, Window window)
|
||||
}
|
||||
XFree(text_prop.value);
|
||||
if (strcmp(slist[0], "WMMenu 0") != 0) {
|
||||
wwarning("appmenu: unknown version of WMMenu in window %lx: %s", window, slist[0]);
|
||||
wwarning(_("appmenu: unknown version of WMMenu in window %lx: %s"), window, slist[0]);
|
||||
XFreeStringList(slist);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user