문제

I'm very new when it comes to Mac OS development and have some experience with Objective C for iOS and need some help getting started on a new project. I need to create something that listens for a drive mount and then lists the files from the drive in a list on the app. Unfortunately, there seems to be very limited tutorials on the subject and I just need help getting this off the line.

I've heard limited things about NSWorkspace but haven't found any tutorials on how to use that.

Also, If it helps, I'm looking for a DICOM-specific filetype (.dcm).

도움이 되었습니까?

해결책

You'll want to listen for the NSWorkspaceDidMountNotification notification, which is issued by the shared NSWorkspace's NSNotificationCenter.

This is pretty straightforward Cocoa stuff. These references may help:

Receiving Workspace Notifications

Notification Programming Topics

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top