Contextual menu from macOS dock icon

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Contextual menu from macOS dock icon

Mat Kelly
Hello,
I would like to use wxPython to produce a menu when the application's Dock icon is right-clicked in macOS.

I have scoured the web and this mailing list but have only seen mention of changing the icon, not adding a contextual menu.

Is this possible with wxPython? If so, can someone provide me a fundamental example?

Thank you,
Mat

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/wxpython-users/9ff20477-f79b-4373-a2cf-9c7142f90d23%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Contextual menu from macOS dock icon

Robin Dunn
On Tuesday, May 21, 2019 at 10:02:31 AM UTC-7, Mat Kelly wrote:
Hello,
I would like to use wxPython to produce a menu when the application's Dock icon is right-clicked in macOS.

I have scoured the web and this mailing list but have only seen mention of changing the icon, not adding a contextual menu.

Is this possible with wxPython? If so, can someone provide me a fundamental example?


Yes. Read through the demo application to see how it is done there. Look at the DemoTaskbarIcon class.

--
Robin


--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/wxpython-users/0521e5b7-8ba3-4285-9712-d1b8f16d56f9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.