Index: xpra/platform/win32/win32_balloon.py =================================================================== --- xpra/platform/win32/win32_balloon.py (revision 17997) +++ xpra/platform/win32/win32_balloon.py (working copy) @@ -101,13 +101,23 @@ def notify(hwnd, app_id, title, message, timeout=5000, icon=None): - nid = PyNOTIFYICONDATA() + from xpra.platform.win32.win32_NotifyIcon import NOTIFYICONDATA, Shell_NotifyIcon + from xpra.platform.win32.common import GUID + from xpra.util import XPRA_GUID1, XPRA_GUID2, XPRA_GUID3, XPRA_GUID4 + from ctypes import sizeof + nid = NOTIFYICONDATA() + nid.cbSize = sizeof(NOTIFYICONDATA) nid.hWnd = hwnd nid.uID = app_id nid.uFlags = NIF_INFO - nid.guidItem = XPRA_GUID_BYTES - nid.szInfo = chop_string(message, 255, False) #prevent overflow - nid.szInfoTitle = chop_string(title, 63) + guid = GUID() + guid.Data1 = XPRA_GUID1 + guid.Data2 = XPRA_GUID2 + guid.Data3 = XPRA_GUID3 + guid.Data4 = XPRA_GUID4 + nid.guidItem = guid + nid.szInfo = chop_string(message, 255, False).decode() #prevent overflow + nid.szInfoTitle = chop_string(title, 63).decode() if timeout<=0: timeout = 5000 nid.uTimeoutOrVersion = timeout @@ -135,8 +145,8 @@ log.error(" %s", e) else: nid.dwInfoFlags = NIIF_USER - Shell_NotifyIcon = windll.shell32.Shell_NotifyIcon - Shell_NotifyIcon(NIM_MODIFY, nid.pack()) + #Shell_NotifyIcon = windll.shell32.Shell_NotifyIcon + Shell_NotifyIcon(NIM_MODIFY, nid) def main():