简体   繁体   中英

How to use NSBrowserDelegate on 10.5

I have a question: When I was running the sample code SimpleCocoaBrowser , I received a crash report about the NSBrowserDelegate , which I discovered can only be used after 10.6. So how can I use an NSBrowser in 10.5? Just use the NSBrowser without NSBrowserDelegate ?

by the way, my english is bad...

thx

Not entirely sure what kind of crash you have experienced, but NSBrowser has always (since 10.0) had a delegate. It is just that the NSBrowserDelegate became a formal protocol in OS X 10.6.

If you don't want to use the NSBrowserDelegate explicitly, you can just not declare your delegate to conform to it, and it should still work.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM