mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 12:28:22 +01:00
wIconUpdate removed image argument
The argument image is not used in any call, so can be removed.
This commit is contained in:
committed by
Carlos R. Mafra
parent
c24499f6ad
commit
4093d24625
@@ -154,7 +154,7 @@ void create_appicon_for_application(WApplication *wapp, WWindow *wwin)
|
||||
if (!wapp->app_icon) {
|
||||
/* Create the icon */
|
||||
wapp->app_icon = wAppIconCreate(wapp->main_window_desc);
|
||||
wIconUpdate(wapp->app_icon->icon, NULL);
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
|
||||
/* Now, paint the icon */
|
||||
if (!WFLAGP(wapp->main_window_desc, no_appicon))
|
||||
@@ -999,7 +999,7 @@ static void create_appicon_from_dock(WWindow *wwin, WApplication *wapp, Window m
|
||||
wapp->app_icon->icon->icon_win = mainw->wm_hints->icon_window;
|
||||
|
||||
/* Update the icon images */
|
||||
wIconUpdate(wapp->app_icon->icon, NULL);
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
|
||||
@@ -472,12 +472,12 @@ void wClientCheckProperty(WWindow * wwin, XPropertyEvent * event)
|
||||
|| (wwin->wm_hints->flags & IconWindowHint)) {
|
||||
WApplication *wapp;
|
||||
|
||||
if (wwin->flags.miniaturized && wwin->icon) {
|
||||
wIconUpdate(wwin->icon, NULL);
|
||||
}
|
||||
if (wwin->flags.miniaturized && wwin->icon)
|
||||
wIconUpdate(wwin->icon);
|
||||
|
||||
wapp = wApplicationOf(wwin->main_window);
|
||||
if (wapp && wapp->app_icon) {
|
||||
wIconUpdate(wapp->app_icon->icon, NULL);
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -542,7 +542,7 @@ static void keepIconsCallback(WMenu *menu, WMenuEntry *entry)
|
||||
aicon->icon->shadowed = 0;
|
||||
|
||||
/* Update the icon images */
|
||||
wIconUpdate(aicon->icon, NULL);
|
||||
wIconUpdate(aicon->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(aicon);
|
||||
@@ -1942,7 +1942,7 @@ Bool wDockAttachIcon(WDock *dock, WAppIcon *icon, int x, int y, Bool update_icon
|
||||
|
||||
/* Update the icon images */
|
||||
if (lupdate_icon)
|
||||
wIconUpdate(icon->icon, NULL);
|
||||
wIconUpdate(icon->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(icon);
|
||||
@@ -2096,7 +2096,7 @@ static Bool moveIconBetweenDocks(WDock *src, WDock *dest, WAppIcon *icon, int x,
|
||||
|
||||
/* Update the icon images */
|
||||
if (update_icon)
|
||||
wIconUpdate(icon->icon, NULL);
|
||||
wIconUpdate(icon->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(icon);
|
||||
@@ -2173,7 +2173,7 @@ void wDockDetach(WDock *dock, WAppIcon *icon)
|
||||
|
||||
/* Update the icon images */
|
||||
if (update_icon)
|
||||
wIconUpdate(icon->icon, NULL);
|
||||
wIconUpdate(icon->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(icon);
|
||||
|
||||
12
src/icon.c
12
src/icon.c
@@ -93,7 +93,7 @@ static void tileObserver(void *self, WMNotification *notif)
|
||||
{
|
||||
WIcon *icon = (WIcon *) self;
|
||||
|
||||
wIconUpdate(icon, NULL);
|
||||
wIconUpdate(icon);
|
||||
|
||||
XClearArea(dpy, icon->core->window, 0, 0, 1, 1, True);
|
||||
}
|
||||
@@ -314,7 +314,7 @@ void wIconChangeTitle(WIcon *icon, char *new_title)
|
||||
icon->icon_name = new_title;
|
||||
|
||||
if (changed)
|
||||
wIconUpdate(icon, NULL);
|
||||
wIconUpdate(icon);
|
||||
else
|
||||
wIconPaint(icon);
|
||||
}
|
||||
@@ -573,13 +573,10 @@ void set_icon_image_from_image(WIcon *icon, RImage *image)
|
||||
icon->file_image = image;
|
||||
}
|
||||
|
||||
void wIconUpdate(WIcon *icon, RImage *image)
|
||||
void wIconUpdate(WIcon *icon)
|
||||
{
|
||||
WWindow *wwin = NULL;
|
||||
|
||||
if (image) {
|
||||
icon->file_image = image;
|
||||
} else {
|
||||
if (icon && icon->owner)
|
||||
wwin = icon->owner;
|
||||
|
||||
@@ -602,7 +599,6 @@ void wIconUpdate(WIcon *icon, RImage *image)
|
||||
/* Get the Pixmap from the user */
|
||||
get_rimage_icon_from_user_icon(icon);
|
||||
}
|
||||
}
|
||||
|
||||
update_icon_pixmap(icon);
|
||||
}
|
||||
@@ -897,5 +893,5 @@ void set_icon_image_from_database(WIcon *icon, char *wm_instance, char *wm_class
|
||||
wfree(file);
|
||||
}
|
||||
|
||||
wIconUpdate(icon, NULL);
|
||||
wIconUpdate(icon);
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ WIcon *icon_create_for_wwindow(WWindow *wwin);
|
||||
void set_icon_image_from_database(WIcon *icon, char *wm_instance, char *wm_class, char *command);
|
||||
void wIconDestroy(WIcon *icon);
|
||||
void wIconPaint(WIcon *icon);
|
||||
void wIconUpdate(WIcon *icon, RImage *image);
|
||||
void wIconUpdate(WIcon *icon);
|
||||
void wIconSelect(WIcon *icon);
|
||||
void wIconChangeTitle(WIcon *icon, char *new_title);
|
||||
void update_icon_pixmap(WIcon *icon);
|
||||
|
||||
@@ -769,7 +769,7 @@ static void applySettings(WMButton *button, InspectorPanel *panel)
|
||||
set_icon_image_from_image(wapp->app_icon->icon, image);
|
||||
update_icon_pixmap(wapp->app_icon->icon);
|
||||
} else {
|
||||
wIconUpdate(wapp->app_icon->icon, NULL);
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -781,7 +781,7 @@ static void applySettings(WMButton *button, InspectorPanel *panel)
|
||||
set_icon_image_from_image(wwin->icon, image);
|
||||
update_icon_pixmap(wwin->icon);
|
||||
} else {
|
||||
wIconUpdate(wwin->icon, NULL);
|
||||
wIconUpdate(wwin->icon);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -468,12 +468,12 @@ static void updateIconImage(WWindow *wwin)
|
||||
|
||||
/* Refresh the Window Icon */
|
||||
if (wwin->icon)
|
||||
wIconUpdate(wwin->icon, NULL);
|
||||
wIconUpdate(wwin->icon);
|
||||
|
||||
/* Refresh the application icon */
|
||||
WApplication *app = wApplicationOf(wwin->main_window);
|
||||
if (app && app->app_icon) {
|
||||
wIconUpdate(app->app_icon->icon, NULL);
|
||||
wIconUpdate(app->app_icon->icon);
|
||||
wAppIconPaint(app->app_icon);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user