From: Rodolfo García Peñas (kix) Date: Sat, 10 Nov 2012 19:25:14 +0000 (+0100) Subject: wAppIconPaint argument removed X-Git-Tag: wmaker-0.95.4~48 X-Git-Url: https://repo.or.cz/w/wmaker-crm.git/commitdiff_plain/cc1503a2f0bd9b60cede1330c6d48e984932b47d wAppIconPaint argument removed This patch removes the wAppIconPaint() Bool flag, because now it is always False. --- diff --git a/src/actions.c b/src/actions.c index e168c566..7dceaffe 100644 --- a/src/actions.c +++ b/src/actions.c @@ -1545,7 +1545,7 @@ void wHideApplication(WApplication *wapp) #ifdef HIDDENDOT if (wapp->app_icon) - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); #endif } @@ -1673,7 +1673,7 @@ void wUnhideApplication(WApplication *wapp, Bool miniwindows, Bool bringToCurren wArrangeIcons(scr, True); #ifdef HIDDENDOT - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); #endif } diff --git a/src/appicon.c b/src/appicon.c index 8e8c22b6..329bd6e3 100644 --- a/src/appicon.c +++ b/src/appicon.c @@ -257,7 +257,7 @@ void removeAppIconFor(WApplication *wapp) wIconUpdate(wapp->app_icon->icon); /* Paint it */ - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); } else if (wapp->app_icon->docked) { wapp->app_icon->running = 0; wDockDetach(wapp->app_icon->dock, wapp->app_icon); @@ -375,7 +375,7 @@ static void updateDockNumbers(WScreen * scr) } #endif /* WS_INDICATOR */ -void wAppIconPaint(WAppIcon *aicon, Bool update_icon) +void wAppIconPaint(WAppIcon *aicon) { WApplication *wapp; WScreen *scr = aicon->icon->core->screen_ptr; @@ -385,9 +385,6 @@ void wAppIconPaint(WAppIcon *aicon, Bool update_icon) else wapp = NULL; - if (update_icon) - wIconUpdate(aicon->icon); - wIconPaint(aicon->icon); # ifdef WS_INDICATOR @@ -520,9 +517,7 @@ static void setIconCallback(WMenu *menu, WMenuEntry *entry) _("Could not open specified icon file"), _("OK"), NULL, NULL); } else { wDefaultChangeIcon(scr, icon->wm_instance, icon->wm_class, file); - /* The image was updated previously at wIconChangeImageFile, - * so we don't need update it here again */ - wAppIconPaint(icon, False); + wAppIconPaint(icon); } if (file) wfree(file); @@ -630,7 +625,7 @@ static void openApplicationMenu(WApplication * wapp, int x, int y) static void iconExpose(WObjDescriptor *desc, XEvent *event) { - wAppIconPaint(desc->parent, False); + wAppIconPaint(desc->parent); } static void iconDblClick(WObjDescriptor *desc, XEvent *event) @@ -997,7 +992,7 @@ void create_appicon_from_dock(WWindow *wwin, WApplication *wapp, Window main_win wIconUpdate(wapp->app_icon->icon); /* Paint it */ - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); save_appicon(wapp->app_icon, True); } } diff --git a/src/appicon.h b/src/appicon.h index f6eabd6d..6f72c8e4 100644 --- a/src/appicon.h +++ b/src/appicon.h @@ -74,7 +74,7 @@ WAppIcon *wAppIconCreateForDock(WScreen *scr, char *command, char *wm_instance, void create_appicon_from_dock(WWindow *wwin, WApplication *wapp, Window main_window); void wAppIconDestroy(WAppIcon *aicon); -void wAppIconPaint(WAppIcon *aicon, Bool update_icon); +void wAppIconPaint(WAppIcon *aicon); void wAppIconMove(WAppIcon *aicon, int x, int y); void makeAppIconFor(WApplication * wapp); void removeAppIconFor(WApplication * wapp); diff --git a/src/application.c b/src/application.c index 274cff6b..7c52fa0d 100644 --- a/src/application.c +++ b/src/application.c @@ -215,7 +215,7 @@ void wApplicationActivate(WApplication *wapp) #ifdef NEWAPPICON if (wapp->app_icon) { wIconSetHighlited(wapp->app_icon->icon, True); - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); } #endif } @@ -225,7 +225,7 @@ void wApplicationDeactivate(WApplication *wapp) #ifdef NEWAPPICON if (wapp->app_icon) { wIconSetHighlited(wapp->app_icon->icon, False); - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); } #endif } diff --git a/src/client.c b/src/client.c index f21b90cb..3287306b 100644 --- a/src/client.c +++ b/src/client.c @@ -478,9 +478,7 @@ void wClientCheckProperty(WWindow * wwin, XPropertyEvent * event) wapp = wApplicationOf(wwin->main_window); if (wapp && wapp->app_icon) { wIconUpdate(wapp->app_icon->icon); - /* The icon was updated in wIconUpdate, so we don't - * need update it again here */ - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); } } diff --git a/src/defaults.c b/src/defaults.c index 3c7d6b5c..5e48d12d 100644 --- a/src/defaults.c +++ b/src/defaults.c @@ -1130,9 +1130,7 @@ void wDefaultUpdateIcons(WScreen *scr) if ((file && aicon->icon->file && strcmp(file, aicon->icon->file) != 0) || (file && !aicon->icon->file)) { wIconChangeImageFile(aicon->icon, file); - /* The image was updated previously at wIconChangeImageFile, - * so we don't need update it here again */ - wAppIconPaint(aicon, False); + wAppIconPaint(aicon); } aicon = aicon->next; } diff --git a/src/dock.c b/src/dock.c index 6c343774..d7d5c538 100644 --- a/src/dock.c +++ b/src/dock.c @@ -544,7 +544,7 @@ static void keepIconsCallback(WMenu *menu, WMenuEntry *entry) wIconUpdate(aicon->icon); /* Paint it */ - wAppIconPaint(aicon, False); + wAppIconPaint(aicon); } } save_appicon(aicon, True); @@ -1154,7 +1154,7 @@ static void dockIconPaint(WAppIcon *btn) if (btn == btn->icon->core->screen_ptr->clip_icon) { wClipIconPaint(btn); } else { - wAppIconPaint(btn, False); + wAppIconPaint(btn); save_appicon(btn, True); } } @@ -1941,7 +1941,7 @@ Bool wDockAttachIcon(WDock *dock, WAppIcon *icon, int x, int y, Bool update_icon wIconUpdate(icon->icon); /* Paint it */ - wAppIconPaint(icon, False); + wAppIconPaint(icon); /* Save it */ save_appicon(icon, True); @@ -2092,7 +2092,7 @@ static Bool moveIconBetweenDocks(WDock *src, WDock *dest, WAppIcon *icon, int x, wIconUpdate(icon->icon); /* Paint it */ - wAppIconPaint(icon, False); + wAppIconPaint(icon); return True; } @@ -2169,7 +2169,7 @@ void wDockDetach(WDock *dock, WAppIcon *icon) wIconUpdate(icon->icon); /* Paint it */ - wAppIconPaint(icon, False); + wAppIconPaint(icon); if (wPreferences.auto_arrange_icons) wArrangeIcons(dock->screen_ptr, True); @@ -2916,7 +2916,7 @@ void wDockTrackWindowLaunch(WDock *dock, Window window) wLowerFrame(aicon->icon->core); XMapWindow(dpy, aicon->icon->core->window); aicon->launching = 1; - wAppIconPaint(aicon, False); + wAppIconPaint(aicon); SlideWindow(aicon->icon->core->window, x0, y0, icon->x_pos, icon->y_pos); XUnmapWindow(dpy, aicon->icon->core->window); wAppIconDestroy(aicon); @@ -3992,7 +3992,7 @@ int wClipMakeIconOmnipresent(WAppIcon *aicon, int omnipresent) } } - wAppIconPaint(aicon, False); + wAppIconPaint(aicon); return status; } diff --git a/src/dockedapp.c b/src/dockedapp.c index d14bd3b6..6c6d1f05 100644 --- a/src/dockedapp.c +++ b/src/dockedapp.c @@ -177,12 +177,10 @@ static void panelBtnCallback(WMWidget * self, void *data) } else { WAppIcon *aicon = panel->editedIcon; - /* The image was updated in wIconChangeImageFile, - * so we don't need udpate it at wAppIconPaint */ if (aicon == aicon->icon->core->screen_ptr->clip_icon) wClipIconPaint(aicon); else - wAppIconPaint(aicon, False); + wAppIconPaint(aicon); wDefaultChangeIcon(panel->wwin->screen_ptr, aicon->wm_instance, aicon->wm_class, text); } diff --git a/src/winspector.c b/src/winspector.c index 808a76fc..25e13b28 100644 --- a/src/winspector.c +++ b/src/winspector.c @@ -790,9 +790,7 @@ static void applySettings(WMButton *button, InspectorPanel *panel) if (file) wfree(file); - /* The image was updated in wIconChangeImageFile, - * so we don't need udpate it at wAppIconPaint */ - wAppIconPaint(wapp->app_icon, False); + wAppIconPaint(wapp->app_icon); } } diff --git a/src/wmspec.c b/src/wmspec.c index 43eb12e9..b3dfb8b6 100644 --- a/src/wmspec.c +++ b/src/wmspec.c @@ -474,8 +474,7 @@ static void updateIconImage(WWindow *wwin) WApplication *app = wApplicationOf(wwin->main_window); if (app && app->app_icon) { wIconUpdate(app->app_icon->icon); - /* Icon was updated in wIconUpdate, so we don't need update it again */ - wAppIconPaint(app->app_icon, False); + wAppIconPaint(app->app_icon); } } diff --git a/src/workspace.c b/src/workspace.c index 6a386c13..7b62798b 100644 --- a/src/workspace.c +++ b/src/workspace.c @@ -594,7 +594,7 @@ void wWorkspaceForceChange(WScreen * scr, int workspace) wArrangeIcons(scr, False); if (scr->dock) - wAppIconPaint(scr->dock->icon_array[0], False); + wAppIconPaint(scr->dock->icon_array[0]); if (scr->clip_icon) { if (scr->workspaces[workspace]->clip->auto_collapse ||