mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 20:38:08 +01:00
wClipIconPaint appicon argument removed
Because the wClipIconPaint() function is specific to paint the clip, it knows where is the clip (wks_info.clip_icon), so the argument is not needed. Signed-off-by: Rodolfo García Peñas (kix) <kix@kix.es>
This commit is contained in:
committed by
Carlos R. Mafra
parent
2103fe390b
commit
014bc52531
@@ -1228,7 +1228,7 @@ void wDefaultUpdateIcons(WScreen *scr)
|
||||
}
|
||||
|
||||
if (!wPreferences.flags.noclip || wPreferences.flags.clip_merged_in_dock)
|
||||
wClipIconPaint(w_global.clip.icon);
|
||||
wClipIconPaint();
|
||||
|
||||
for (dc = scr->drawers; dc != NULL; dc = dc->next)
|
||||
wDrawerIconPaint(dc->adrawer->icon_array[0]);
|
||||
|
||||
13
src/dock.c
13
src/dock.c
@@ -1363,8 +1363,9 @@ void wDockDestroy(WDock *dock)
|
||||
wfree(dock);
|
||||
}
|
||||
|
||||
void wClipIconPaint(WAppIcon *aicon)
|
||||
void wClipIconPaint(void)
|
||||
{
|
||||
WAppIcon *aicon = w_global.clip.icon;
|
||||
WScreen *scr = aicon->icon->core->screen_ptr;
|
||||
WWorkspace *workspace = w_global.workspace.array[w_global.workspace.current];
|
||||
WMColor *color;
|
||||
@@ -1408,13 +1409,13 @@ void wClipIconPaint(WAppIcon *aicon)
|
||||
|
||||
static void clipIconExpose(WObjDescriptor *desc, XEvent *event)
|
||||
{
|
||||
wClipIconPaint(desc->parent);
|
||||
wClipIconPaint();
|
||||
}
|
||||
|
||||
static void dockIconPaint(WAppIcon *btn)
|
||||
{
|
||||
if (btn == w_global.clip.icon) {
|
||||
wClipIconPaint(btn);
|
||||
wClipIconPaint();
|
||||
} else if (wIsADrawer(btn)) {
|
||||
wDrawerIconPaint(btn);
|
||||
} else {
|
||||
@@ -3861,7 +3862,7 @@ static void handleClipChangeWorkspace(WScreen *scr, XEvent *event)
|
||||
clip->lclip_button_pushed = direction == CLIP_REWIND;
|
||||
clip->rclip_button_pushed = direction == CLIP_FORWARD;
|
||||
|
||||
wClipIconPaint(w_global.clip.icon);
|
||||
wClipIconPaint();
|
||||
done = 0;
|
||||
while (!done) {
|
||||
WMMaskEvent(dpy, ExposureMask | ButtonMotionMask | ButtonReleaseMask | ButtonPressMask, &ev);
|
||||
@@ -3876,7 +3877,7 @@ static void handleClipChangeWorkspace(WScreen *scr, XEvent *event)
|
||||
direction = new_dir;
|
||||
clip->lclip_button_pushed = direction == CLIP_REWIND;
|
||||
clip->rclip_button_pushed = direction == CLIP_FORWARD;
|
||||
wClipIconPaint(w_global.clip.icon);
|
||||
wClipIconPaint();
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -3908,7 +3909,7 @@ static void handleClipChangeWorkspace(WScreen *scr, XEvent *event)
|
||||
wWorkspaceChange(scr, w_global.workspace.count - 1);
|
||||
}
|
||||
|
||||
wClipIconPaint(w_global.clip.icon);
|
||||
wClipIconPaint();
|
||||
}
|
||||
|
||||
static void iconMouseDown(WObjDescriptor *desc, XEvent *event)
|
||||
|
||||
@@ -96,7 +96,7 @@ void wDockLaunchWithState(WDock *dock, WAppIcon *btn, WSavedState *state);
|
||||
int wDockReceiveDNDDrop(WScreen *scr, XEvent *event);
|
||||
#endif
|
||||
|
||||
void wClipIconPaint(WAppIcon *aicon);
|
||||
void wClipIconPaint(void);
|
||||
void wClipSaveState(WScreen *scr);
|
||||
WMPropList *wClipSaveWorkspaceState(WScreen *scr, int workspace);
|
||||
WAppIcon *wClipRestoreState(WScreen *scr, WMPropList *clip_state);
|
||||
|
||||
@@ -178,7 +178,7 @@ static void panelBtnCallback(WMWidget * self, void *data)
|
||||
|
||||
// Cf dock.c:dockIconPaint(WAppIcon *aicon)?
|
||||
if (aicon == w_global.clip.icon)
|
||||
wClipIconPaint(aicon);
|
||||
wClipIconPaint();
|
||||
else if (wIsADrawer(aicon))
|
||||
wDrawerIconPaint(aicon);
|
||||
else
|
||||
|
||||
@@ -624,7 +624,7 @@ void wWorkspaceForceChange(WScreen * scr, int workspace)
|
||||
XMapWindow(dpy, w_global.clip.icon->icon->core->window);
|
||||
}
|
||||
else if (w_global.clip.icon != NULL) {
|
||||
wClipIconPaint(w_global.clip.icon);
|
||||
wClipIconPaint();
|
||||
}
|
||||
wScreenUpdateUsableArea(scr);
|
||||
wNETWMUpdateDesktop(scr);
|
||||
@@ -700,7 +700,7 @@ void wWorkspaceRename(WScreen *scr, int workspace, const char *name)
|
||||
}
|
||||
|
||||
if (w_global.clip.icon)
|
||||
wClipIconPaint(w_global.clip.icon);
|
||||
wClipIconPaint();
|
||||
|
||||
WMPostNotificationName(WMNWorkspaceNameChanged, scr, (void *)(uintptr_t) workspace);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user