Make a File Browser
In this chapter, you are going to create a simple file browser using NSFileManager and NSTreeController, as shown in Figure 13.3
Figure 13.3 The file browser
Create a new "Cocoa Application" project called Remover. Besides browsing, your app will allow the user to delete files and directories.
To represent the information about one directory entry, which may be a file or a directory, you will create a class called DirEntry. You will also be adding an NSTreeController, and the RemoverAppDelegate has already been created by the Xcode template. The class diagram is shown in Figure 13.4
Figure 13.4 Class diagram for Remover app ...
Get Advanced Mac OS X Programming: The Big Nerd Ranch Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.