windowmatches: Resurrect USE_ICON_IMAGE_FOR_CLIENT_() macros

This commit is contained in:
Kim Woelders 2019-12-25 16:18:29 +01:00
parent 4bedde9c1b
commit 36763cc7e2
2 changed files with 5 additions and 22 deletions

View File

@ -626,35 +626,23 @@ __MATCH_WINDOW __BGN;\
__END
#define USE_ICON_IMAGE_FOR_CLIENT_TITLE(title, image) \
__ICLASS __BGN;\
__NAME image"_ICLASS";\
__NORMAL image;\
__END;\
__MATCH_WINDOW __BGN;\
__NAME image"_MATCH";\
__USE_ICON image"_ICLASS";\
__USE_ICON image;\
__HAS_TITLE title;\
__END
#define USE_ICON_IMAGE_FOR_CLIENT_NAME(name, image) \
__ICLASS __BGN;\
__NAME image"_ICLASS";\
__NORMAL image;\
__END;\
__MATCH_WINDOW __BGN;\
__NAME image"_MATCH";\
__USE_ICON image"_ICLASS";\
__USE_ICON image;\
__HAS_NAME name;\
__END
#define USE_ICON_IMAGE_FOR_CLIENT_CLASS(class, image) \
__ICLASS __BGN;\
__NAME image"_ICLASS";\
__NORMAL image;\
__END;\
__MATCH_WINDOW __BGN;\
__NAME image"_MATCH";\
__USE_ICON image"_ICLASS";\
__USE_ICON image;\
__HAS_CLASS class;\
__END

View File

@ -1,6 +1,6 @@
/*
* Copyright (C) 2000-2007 Carsten Haitzler, Geoff Harrison and various contributors
* Copyright (C) 2005-2018 Kim Woelders
* Copyright (C) 2005-2019 Kim Woelders
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
@ -244,15 +244,10 @@ WindowMatchConfigLoad(FILE * fs)
break;
case WINDOWMATCH_ICON:
#if 0 /* This has not been active since at least 0.16.5 */
if (!wm)
break;
wm->icon = ImageclassFind(s2, 0);
if (!wm->icon)
break;
wm->args = Estrdup(s2);
wm->op = MATCH_OP_ICON;
wm->icon->ref_count++;
#endif
break;
case WINDOWMATCH_DESKTOP: