mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-29 18:02:34 +01:00
WINGs: Marked args as unused for compiler in Notification callback code
The mechanism of Notifications in the WINGs toolkit is relying on callbacks to dispatch notifications, which means having a fixed argument list for the handling function. It is then correct to not use all the arguments, so this patch adds the appropriate stuff to avoid a false report from compiler. Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
committed by
Carlos R. Mafra
parent
58961dce72
commit
fed1bf4de3
@@ -2321,6 +2321,9 @@ static void grayBrightnessTextFieldCallback(void *observerData, WMNotification *
|
|||||||
int value;
|
int value;
|
||||||
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
||||||
|
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) notification;
|
||||||
|
|
||||||
value = atoi(WMGetTextFieldText(panel->grayBrightnessT));
|
value = atoi(WMGetTextFieldText(panel->grayBrightnessT));
|
||||||
if (value > 100)
|
if (value > 100)
|
||||||
value = 100;
|
value = 100;
|
||||||
@@ -2375,6 +2378,9 @@ static void rgbTextFieldCallback(void *observerData, WMNotification * notificati
|
|||||||
int n;
|
int n;
|
||||||
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
||||||
|
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) notification;
|
||||||
|
|
||||||
value[0] = atoi(WMGetTextFieldText(panel->rgbRedT));
|
value[0] = atoi(WMGetTextFieldText(panel->rgbRedT));
|
||||||
value[1] = atoi(WMGetTextFieldText(panel->rgbGreenT));
|
value[1] = atoi(WMGetTextFieldText(panel->rgbGreenT));
|
||||||
value[2] = atoi(WMGetTextFieldText(panel->rgbBlueT));
|
value[2] = atoi(WMGetTextFieldText(panel->rgbBlueT));
|
||||||
@@ -2449,6 +2455,9 @@ static void cmykTextFieldCallback(void *observerData, WMNotification * notificat
|
|||||||
double scale;
|
double scale;
|
||||||
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
||||||
|
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) notification;
|
||||||
|
|
||||||
value[0] = atoi(WMGetTextFieldText(panel->cmykCyanT));
|
value[0] = atoi(WMGetTextFieldText(panel->cmykCyanT));
|
||||||
value[1] = atoi(WMGetTextFieldText(panel->cmykMagentaT));
|
value[1] = atoi(WMGetTextFieldText(panel->cmykMagentaT));
|
||||||
value[2] = atoi(WMGetTextFieldText(panel->cmykYellowT));
|
value[2] = atoi(WMGetTextFieldText(panel->cmykYellowT));
|
||||||
@@ -2534,6 +2543,9 @@ static void hsbTextFieldCallback(void *observerData, WMNotification * notificati
|
|||||||
int n;
|
int n;
|
||||||
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
W_ColorPanel *panel = (W_ColorPanel *) observerData;
|
||||||
|
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) notification;
|
||||||
|
|
||||||
value[0] = atoi(WMGetTextFieldText(panel->hsbHueT));
|
value[0] = atoi(WMGetTextFieldText(panel->hsbHueT));
|
||||||
value[1] = atoi(WMGetTextFieldText(panel->hsbSaturationT));
|
value[1] = atoi(WMGetTextFieldText(panel->hsbSaturationT));
|
||||||
value[2] = atoi(WMGetTextFieldText(panel->hsbBrightnessT));
|
value[2] = atoi(WMGetTextFieldText(panel->hsbBrightnessT));
|
||||||
|
|||||||
@@ -92,6 +92,9 @@ static void updateDoubleBufferPixmap(WMList * lPtr)
|
|||||||
|
|
||||||
static void realizeObserver(void *self, WMNotification * not)
|
static void realizeObserver(void *self, WMNotification * not)
|
||||||
{
|
{
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) not;
|
||||||
|
|
||||||
updateDoubleBufferPixmap(self);
|
updateDoubleBufferPixmap(self);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -49,6 +49,9 @@ static void makeKnobPixmap(Slider * sPtr);
|
|||||||
|
|
||||||
static void realizeObserver(void *self, WMNotification * not)
|
static void realizeObserver(void *self, WMNotification * not)
|
||||||
{
|
{
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) not;
|
||||||
|
|
||||||
makeKnobPixmap(self);
|
makeKnobPixmap(self);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -351,6 +351,9 @@ static void handleViewResized(void *self, WMNotification * notification)
|
|||||||
{
|
{
|
||||||
WMSplitView *sPtr = (WMSplitView *) self;
|
WMSplitView *sPtr = (WMSplitView *) self;
|
||||||
|
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) notification;
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
printf("---- (handleViewResized - 1) ----\n");
|
printf("---- (handleViewResized - 1) ----\n");
|
||||||
dumpSubviews(sPtr);
|
dumpSubviews(sPtr);
|
||||||
|
|||||||
@@ -307,6 +307,9 @@ static void selectionNotification(void *observerData, WMNotification * notificat
|
|||||||
|
|
||||||
static void realizeObserver(void *self, WMNotification * not)
|
static void realizeObserver(void *self, WMNotification * not)
|
||||||
{
|
{
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) not;
|
||||||
|
|
||||||
W_CreateIC(((TextField *) self)->view);
|
W_CreateIC(((TextField *) self)->view);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -95,6 +95,9 @@ static void realizeWindow(WMWindow * win);
|
|||||||
|
|
||||||
static void realizeObserver(void *self, WMNotification * not)
|
static void realizeObserver(void *self, WMNotification * not)
|
||||||
{
|
{
|
||||||
|
/* Parameter not used, but tell the compiler that it is ok */
|
||||||
|
(void) not;
|
||||||
|
|
||||||
realizeWindow(self);
|
realizeWindow(self);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user