Learn how to create a delegate class to handle the behavior of the table view.
- [Instructor] We are in the home stretch.…There's really just one more class that I need to create…in order to make my table work.…So let me go up to CharacterGUI, right click,…select add, new file.…Then I'm going to call this class inventoryTableDelegate.…This class is going to be responsible for…all the behavior of our table.…As before, it has a specific inheritance requirement…so let me come up to the using section…and I'll type in using AppKit just like I did before.…
And next let's fix our inheritance.…This is going to inherit from NSTableViewDelegate.…There are a few moving parts in a Delegate class…and it may not be obvious what these parts do…until we get to the very end.…So with that in mind, I'm going to type all of our code in,…but I probably won't do a lot of commentary…until we actually have all of it in there.…So let's start off with private constant.…
Constant, we haven't mentioned those yet.…A constant is like a variable except it can't change.…You initialize it on the line where you create it.…
AuthorBruce Van Horn
- Exploring C# on a Mac
- Creating a reusable code library
- Classes and properties
- Loops, arrays, and lists
- Creating a console app
- Creating a command-line app
- Creating a Mac desktop app
- Creating a UI with view controllers and actions
Skill Level Beginner
New Features Xamarin and Visual Studio 2017with Kevin Ford1h 44m Intermediate
Docker for .NET Developers with Visual Studiowith Lee Brandt46m 52s Intermediate
1. C# on the Mac?
2. Getting Started with C#
3. Deeper into C#
4. Creating a Mac App
Next steps3m 14s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.