[Resolved] QT/Mac Icon problem
I'd like to change my dock Icon during runtime. As I understand the only way to do that is to call something like on the QApplication:
@setWindowIcon(QIcon("my resource or file")); // which I set to a 512x512 png resource I have@
It works, but as a side effect, allt the windows in my application are now shown with an icon on the caption -- something I do not want. I just want the caption text on a given window.
Is there a way to suppress the projection of the application icon on the window caption and still change the dock icon dynamically at runtime?
Bypassing this would also work as the reason for the change of the dock icon is to add a "badge" onto it and remove that badge under certain conditions. Can such badge be drawn without having to call "SetWindowIcon"?
Did you see the "special section for MAC":http://developer.qt.nokia.com/doc/qt-4.8/appicon.html#setting-the-application-icon-on-mac-os-x ?
I did, but it doesn't answer my question of how to I change dock icons, or project information on a dock icon (similar to a new e-mail count on some mail applications) at runtime, and without defining an application icon, so that no icon is drawn on any of my window captions.
Eventually, what I ended up doing is actively forcing a blank QIcon onto all my windows (on Mac Only of course). That makes sure that even after the dock icon is changed, all my window captions remain with text only and no icon is shown.