Accessing the system tray icon RRS feed

  • Question

  • I've been programming a desktop application with ruby/tk. Using the win32api gem, I've managed to hide and set my program icon to work in the system tray. The icon is displayed succesfully and the texttip works etc.

    Now I'd like for the app window to maximize when the tray icon is clicked, or show a menu, but I have no idea how to reference this icon. I used the win32api gem to a) minimize (or hide) the current window via ShowWindow() and b) to create an icon in the system tray with Shell_NotifyIconA().

    Now I want to access the window again via the icon. How can this be achieved?

    • Moved by Marvin_Guo Wednesday, March 18, 2015 1:33 AM Ruby Related
    Sunday, March 8, 2015 7:15 AM


  • Hello simon,

    According to your description, it seems that this issue seems to be related with Rube development with win32api, for this, I think the Ruby forum is proper for it:



    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Proposed as answer by Leo (Apple) Yang Tuesday, March 10, 2015 6:34 AM
    • Marked as answer by Just Karl Tuesday, March 31, 2015 7:58 PM
    Monday, March 9, 2015 8:32 AM