From ed3b9fe2854c6c5063a347986d5672eadef5ff0d Mon Sep 17 00:00:00 2001 From: Bent Hillerkus <29630575+benthillerkus@users.noreply.github.com> Date: Thu, 31 Mar 2022 22:53:58 +0200 Subject: [PATCH] fix(plugin): call `update` on icon after changing tooltip --- windows/betrayal_plugin.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/windows/betrayal_plugin.cpp b/windows/betrayal_plugin.cpp index b8d8f17..0d24b38 100644 --- a/windows/betrayal_plugin.cpp +++ b/windows/betrayal_plugin.cpp @@ -234,6 +234,7 @@ namespace Betrayal } icon->set_tooltip(tooltip); + icon->update(); result->Success(flutter::EncodableValue(true)); }; @@ -279,7 +280,7 @@ namespace Betrayal }; #pragma warning(disable : 4244) - // https://cs.github.com/openjdk/jdk/blob/6013d09e82693a1c07cf0bf6daffd95114b3cbfa/src/java.desktop/windows/native/libawt/windows/awt_TrayIcon.cpp#L649 + // https://cs.github.com/openjdk/jdk/blob/6013d09e82693a1c07cf0bf6daffd95114b3cbfa/src/java.desktop/windows/native/libawt/windows/awt_TrayIcon.cpp#L649 HICON CreateIconFromBytes(HWND hWnd, int width, int height, uint32_t *bytes, TrayIcon *icon) {