zserge / tray

Cross-platform, super tiny C99 implementation of a system tray icon with a popup menu.
MIT License
493 stars 84 forks source link

compatible with new Obj-C runtime #14

Open wormyrocks opened 4 years ago

wormyrocks commented 4 years ago

If you can't use -DOBJC_OLD_DISPATCH_PROTOTYPES=1 for whatever reason, I have a patch with objc_MsgSend calls updated to use the syntax compatible with newer versions of Xcode.

This makes the code really ugly so I won't submit it as a pull request, but it works in a pinch. There may be a better way to handle this but this was a sledgehammer approach, I'm no obj-c developer.

There are also a few more fixes for newer versions of macOS upstream in my branch, but this is the one I sense might be the most helpful to other people.

https://github.com/wormyrocks/tray/blob/83fd0df977fc5365713b1eedfcd499c92695bfb6/tray.h