Skip to content

Commit 4ee56ab

Browse files
TrueCrimeDevclaude
andcommitted
Notify on image-property changes in ResultViewModel
The Image, BadgeImage, and PreviewImage setters never raised PropertyChanged, even though the LoadImageAsync comments asserted that "modifying the property" was supposed to trigger the event. The notify call was lost in 2021 when the LazyAsync<ImageSource> wrapper was inlined (e8691c2). The bug usually hides because subsequent identical IcoPath lookups hit ImageCache synchronously in the getter, so the binding sees the loaded image on its first evaluation. But when a brand-new IcoPath comes in and the host doesn't virtualize the row out and back in (e.g., a single-result query like a chat plugin's "Ask" preview), the field is mutated post-await and the binding stays on LoadingImage forever. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 17184c4 commit 4ee56ab

1 file changed

Lines changed: 15 additions & 3 deletions

File tree

Flow.Launcher/ViewModel/ResultViewModel.cs

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,11 @@ public ImageSource Image
175175

176176
return _image;
177177
}
178-
private set => _image = value;
178+
private set
179+
{
180+
_image = value;
181+
OnPropertyChanged();
182+
}
179183
}
180184

181185
public ImageSource BadgeImage
@@ -190,7 +194,11 @@ public ImageSource BadgeImage
190194

191195
return _badgeImage;
192196
}
193-
private set => _badgeImage = value;
197+
private set
198+
{
199+
_badgeImage = value;
200+
OnPropertyChanged();
201+
}
194202
}
195203

196204
public ImageSource PreviewImage
@@ -205,7 +213,11 @@ public ImageSource PreviewImage
205213

206214
return _previewImage;
207215
}
208-
private set => _previewImage = value;
216+
private set
217+
{
218+
_previewImage = value;
219+
OnPropertyChanged();
220+
}
209221
}
210222

211223
/// <summary>

0 commit comments

Comments
 (0)