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

util: Added a few missing 'static' attributes for functions

This commit is contained in:
Christophe CURIS
2013-05-12 00:24:53 +02:00
committed by Carlos R. Mafra
parent d517d5cac0
commit 549cefc47b
12 changed files with 34 additions and 34 deletions

View File

@@ -54,7 +54,7 @@ char *FontOptions[] = {
extern char *__progname;
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [-h] [-v] [--keep-xlfd] <style_file>\n", __progname);
if (print_usage) {

View File

@@ -135,7 +135,7 @@ static char *mapSlantToName(str * slant)
}
}
char *xlfdToFc(const char *xlfd, const char *useFamily, Bool keepXLFD)
static char *xlfdToFc(const char *xlfd, const char *useFamily, Bool keepXLFD)
{
str *tokens, *family, *weight, *slant;
char *name, buf[64];

View File

@@ -34,7 +34,7 @@
extern char *__progname;
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [-h] [-v] [file]\n", __progname);
if (print_usage) {

View File

@@ -138,7 +138,7 @@ WMPropList *PixmapPath = NULL;
char *ThemePath = NULL;
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [-t] [-p] [-h] [-v] [file]\n", __progname);
if (print_usage) {
@@ -165,7 +165,7 @@ static Bool isFontOption(const char *option)
return False;
}
void findCopyFile(const char *dir, const char *file)
static void findCopyFile(const char *dir, const char *file)
{
char *fullPath;
@@ -179,7 +179,7 @@ void findCopyFile(const char *dir, const char *file)
free(fullPath);
}
void makeThemePack(WMPropList * style, const char *themeName)
static void makeThemePack(WMPropList * style, const char *themeName)
{
WMPropList *keys;
WMPropList *key;

View File

@@ -34,7 +34,7 @@
extern char *__progname;
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [-h] [-v] [file]\n", __progname);
if (print_usage) {

View File

@@ -110,7 +110,7 @@ static Bool isFontOption(const char *option)
* that qualifies the external references to be absolute, possibly
* pending further expansion
*/
void hackPathInTexture(WMPropList * texture, const char *prefix)
static void hackPathInTexture(WMPropList * texture, const char *prefix)
{
WMPropList *type;
char *t;
@@ -158,7 +158,7 @@ void hackPathInTexture(WMPropList * texture, const char *prefix)
}
}
void hackPaths(WMPropList * style, const char *prefix)
static void hackPaths(WMPropList * style, const char *prefix)
{
WMPropList *keys;
WMPropList *key;
@@ -263,7 +263,7 @@ static WMPropList *getColor(WMPropList * texture)
* IconTitleColor
* IconTitleBack
*/
void hackStyle(WMPropList * style)
static void hackStyle(WMPropList * style)
{
WMPropList *keys, *tmp;
int foundIconTitle = 0, foundResizebarBack = 0;
@@ -350,7 +350,7 @@ void hackStyle(WMPropList * style)
}
}
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [OPTIONS] FILE\n", __progname);
if (print_usage) {

View File

@@ -41,7 +41,7 @@
extern char *__progname;
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [OPTIONS] <domain> <key>\n", __progname);
if (print_usage) {

View File

@@ -41,7 +41,7 @@
extern char *__progname;
void print_help(int print_usage, int exitval)
static void print_help(int print_usage, int exitval)
{
printf("Usage: %s [OPTIONS] <domain> <key> <value>\n", __progname);
if (print_usage) {

View File

@@ -275,7 +275,7 @@ static void update(void *d)
data->tid = WMAddTimerHandler(data->refreshrate, update, data);
}
void resizedWindow(void *d, WMNotification * notif)
static void resizedWindow(void *d, WMNotification * notif)
{
BufferData *data = (BufferData *) d;
WMView *view = (WMView *) WMGetNotificationObject(notif);
@@ -286,7 +286,7 @@ void resizedWindow(void *d, WMNotification * notif)
resizeBufferData(data, size.width, size.height, data->magfactor);
}
void closeWindow(WMWidget * w, void *d)
static void closeWindow(WMWidget * w, void *d)
{
BufferData *data = (BufferData *) d;

View File

@@ -96,7 +96,7 @@ typedef struct BackgroundTexture {
int height;
} BackgroundTexture;
void initXinerama(void)
static void initXinerama(void)
{
xineInfo.screens = NULL;
xineInfo.count = 0;
@@ -140,7 +140,7 @@ void initXinerama(void)
#endif /* XINERAMA */
}
RImage *loadImage(RContext * rc, const char *file)
static RImage *loadImage(RContext * rc, const char *file)
{
char *path;
RImage *image;
@@ -257,7 +257,7 @@ applyImage(RContext * rc, BackgroundTexture * texture, RImage * image, char type
}
}
BackgroundTexture *parseTexture(RContext * rc, char *text)
static BackgroundTexture *parseTexture(RContext * rc, char *text)
{
BackgroundTexture *texture = NULL;
WMPropList *texarray;
@@ -687,7 +687,7 @@ BackgroundTexture *parseTexture(RContext * rc, char *text)
return NULL;
}
void freeTexture(BackgroundTexture * texture)
static void freeTexture(BackgroundTexture * texture)
{
if (texture->solid) {
unsigned long pixel[1];
@@ -705,7 +705,7 @@ void freeTexture(BackgroundTexture * texture)
wfree(texture);
}
void setupTexture(RContext * rc, BackgroundTexture ** textures, int *maxTextures, int workspace, char *texture)
static void setupTexture(RContext * rc, BackgroundTexture ** textures, int *maxTextures, int workspace, char *texture)
{
BackgroundTexture *newTexture = NULL;
int i;
@@ -758,7 +758,7 @@ void setupTexture(RContext * rc, BackgroundTexture ** textures, int *maxTextures
*maxTextures = workspace;
}
Pixmap duplicatePixmap(Pixmap pixmap, int width, int height)
static Pixmap duplicatePixmap(Pixmap pixmap, int width, int height)
{
Display *tmpDpy;
Pixmap copyP;
@@ -789,7 +789,7 @@ static int dummyErrorHandler(Display * dpy, XErrorEvent * err)
return 0;
}
void setPixmapProperty(Pixmap pixmap)
static void setPixmapProperty(Pixmap pixmap)
{
static Atom prop = 0;
Atom type;
@@ -826,7 +826,7 @@ void setPixmapProperty(Pixmap pixmap)
XFlush(dpy);
}
void changeTexture(BackgroundTexture * texture)
static void changeTexture(BackgroundTexture * texture)
{
if (!texture) {
return;
@@ -850,7 +850,7 @@ void changeTexture(BackgroundTexture * texture)
}
}
int readmsg(int fd, char *buffer, int size)
static int readmsg(int fd, char *buffer, int size)
{
int count;
@@ -876,7 +876,7 @@ int readmsg(int fd, char *buffer, int size)
* n is 4 bytes
* size = 4 bytes for length of the message data
*/
void helperLoop(RContext * rc)
static void helperLoop(RContext * rc)
{
BackgroundTexture *textures[WORKSPACE_COUNT];
int maxTextures = 0;
@@ -974,7 +974,7 @@ void helperLoop(RContext * rc)
}
}
void updateDomain(const char *domain, const char *key, const char *texture)
static void updateDomain(const char *domain, const char *key, const char *texture)
{
char *program = "wdwrite";
@@ -1043,7 +1043,7 @@ static WMPropList *getValueForKey(const char *domain, const char *keyName)
return val;
}
char *getPixmapPath(const char *domain)
static char *getPixmapPath(const char *domain)
{
WMPropList *val;
char *ptr, *data;
@@ -1094,7 +1094,7 @@ char *getPixmapPath(const char *domain)
return data;
}
char *getFullPixmapPath(const char *file)
static char *getFullPixmapPath(const char *file)
{
char *tmp;
@@ -1127,7 +1127,7 @@ void wAbort(void)
exit(1);
}
void print_help(void)
static void print_help(void)
{
printf("Usage: %s [options] [image]\n", __progname);
puts("Sets the workspace background to the specified image or a texture and");
@@ -1155,7 +1155,7 @@ void print_help(void)
puts(" -h, --help show this help and exit");
}
void changeTextureForWorkspace(const char *domain, char *texture, int workspace)
static void changeTextureForWorkspace(const char *domain, char *texture, int workspace)
{
WMPropList *array, *val;
char *value;

View File

@@ -33,7 +33,7 @@
extern char *__progname;
void print_help(void)
static void print_help(void)
{
printf("Usage: %s [OPTIONS] [FILE]\n", __progname);
puts("Copies data from FILE or stdin into X cut buffer.");

View File

@@ -37,7 +37,7 @@
extern char *__progname;
void print_help(void)
static void print_help(void)
{
printf("Usage: %s [OPTIONS] [FILE]\n", __progname);
puts("Copies data from X selection or cutbuffer to FILE or stdout.");
@@ -49,7 +49,7 @@ void print_help(void)
puts(" -v, --version output version information and exit");
}
Time getTimestamp(Display * dpy, Window win)
static Time getTimestamp(Display * dpy, Window win)
{
XEvent ev;
@@ -81,7 +81,7 @@ Time getTimestamp(Display * dpy, Window win)
return ev.xproperty.time;
}
char *fetchSelection(Display * dpy, const char *selection, const char *progName)
static char *fetchSelection(Display * dpy, const char *selection, const char *progName)
{
Atom selatom = XInternAtom(dpy, selection, False);
Atom clipatom = XInternAtom(dpy, "CLIPBOARD", False);