mirror of
https://github.com/gryf/wmaker.git
synced 2026-10-06 09:20:34 +02:00
wIconStore(): do not save the icon if it exists
The function wIconStore() doesn't write a new file overwriting the previous icon if the icon file exists.
This commit is contained in:
1 parent
21fb6db616
commit
0db76b822d
1 file changed
+4
@@ -473,6 +473,10 @@ char *wIconStore(WIcon * icon)
|
||||
if (!path)
|
||||
return NULL;
|
||||
|
||||
/* If icon exists, exit */
|
||||
if (access(path, F_OK) == 0)
|
||||
return path;
|
||||
|
||||
if (wwin->net_icon_image) {
|
||||
image = RRetainImage(wwin->net_icon_image);
|
||||
} else if (wwin->wm_hints && (wwin->wm_hints->flags & IconPixmapHint)
|
||||
|
||||
Reference in new issue
Block a user