diff options
Diffstat (limited to 'internal/notify/service.go')
| -rw-r--r-- | internal/notify/service.go | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/internal/notify/service.go b/internal/notify/service.go index 86918d4..a2bf103 100644 --- a/internal/notify/service.go +++ b/internal/notify/service.go @@ -120,7 +120,16 @@ func (s *Service) Notify(appName string, replacesID uint32, appIcon, summary, bo if r, ok := ImageDataFromHints(hints); ok { raw = r } else if path, ok := ImagePathFromHints(hints); ok { - n.Image = ResolveIcon(path) + resolved := ResolveIcon(path) + // An icon-like content image (a theme name, an SVG, a small raster) is + // the app icon clients like kitty send through this hint; a larger + // raster is a screenshot and stays the balloon preview. An app_icon + // already provided keeps the slot. + if IsIconImage(path, resolved) && n.Icon == "" { + n.Icon = resolved + } else { + n.Image = resolved + } } else if r, ok := IconDataFromHints(hints); ok { raw = r } |
