mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-20 21:08:08 +01:00
only scale down icons (not up)
This commit is contained in:
@@ -194,7 +194,7 @@ static void addIconForWindow(WSwitchPanel *panel, WWindow *wwin, int iconWidth)
|
||||
if (!image && panel->defIcon)
|
||||
image= RRetainImage(panel->defIcon);
|
||||
|
||||
if (image && (abs(image->width - iconWidth) > 2 || abs(image->height - iconWidth) > 2)) {
|
||||
if (image && ((image->width - iconWidth) > 2 || (image->height - iconWidth) > 2)) {
|
||||
RImage *nimage;
|
||||
nimage= RScaleImage(image, iconWidth, (image->height * iconWidth / image->width));
|
||||
RReleaseImage(image);
|
||||
|
||||
Reference in New Issue
Block a user