arcam / CocoaUPnP

CocoaUPnP is a logical progression of upnpx; designed to be easy, modern and block-based.
MIT License
85 stars 40 forks source link

How do use it in a macOS app? Thanks! #42

Closed FrontierApp closed 7 years ago

FrontierApp commented 7 years ago

How do use it in a macOS app? Thanks!

squarefrog commented 7 years ago

Should be the same as in iOS, although I haven't personally tried. Add the framework using CocoaPods and follow along using the documentation.

FrontierApp commented 7 years ago

Thanks for your reply. I have tried it with pod. However, I got the message that it does not support osx. Can you please update the podspec?

https://github.com/CocoaPods/Specs/blob/master/Specs/3/8/f/CocoaUPnP/1.1.0/CocoaUPnP.podspec.json

Thanks!

FrontierApp commented 7 years ago

In addition, when I try integrating it into my macOS app, I got the following error:

Use of undeclared identifier 'UIApplicationDidEnterBackgroundNotification' Use of undeclared identifier 'UIApplicationDidBecomeActiveNotification'

They both depend on iOS. Thanks.

squarefrog commented 7 years ago

You'd need to find a similar notification for macOS. Otherwise your app will keep searching for new UPnP devices all the time. That may or may not be what you want.

FrontierApp commented 7 years ago

Thanks for your reply!

Hopefully it can support macOS via pod some day.

On Sep 29, 2017, at 09:48, Paul Williamson notifications@github.com<mailto:notifications@github.com> wrote:

Should be the same as in iOS, although I haven't personally tried. Add the framework using CocoaPods and follow along using the documentation.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/arcam/CocoaUPnP/issues/42#issuecomment-333131166, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AeB_hq81ELqRCKlIOjcl0Jn1HOOaLk_oks5snPU3gaJpZM4Poos2.

squarefrog commented 7 years ago

Feel free to create a Pull Request