5 // Created by Alex Rozanski on 08/01/2010.
6 // Copyright 2010 Alex Rozanski http://perspx.com
8 // Adapted to VLC media player by Felix Paul Kühne
11 #import <Cocoa/Cocoa.h>
13 /*An example of a class that could be used to represent a Source List Item
15 Provides a title, an identifier, and an icon to be shown, as well as a badge value and a property to determine
16 whether the current item has a badge or not (`badgeValue` is set to -1 if no badge is shown)
18 Used to form a hierarchical model of SourceListItem instances – similar to the Source List tree structure
19 and easily accessible by the data source with the "children" property
21 SourceListItem *parent
22 - SourceListItem *child1;
23 - SourceListItem *child2;
24 - SourceListItem *childOfChild2;
25 - SourceListItem *anotherChildOfChild2;
26 - SourceListItem *child3;
30 @interface SideBarItem : NSObject {
39 @property (nonatomic, copy) NSString *title;
40 @property (nonatomic, copy) NSString *identifier;
41 @property (nonatomic, retain) NSImage *icon;
42 @property NSInteger badgeValue;
44 @property (nonatomic, copy) NSArray *children;
47 + (id)itemWithTitle:(NSString*)aTitle identifier:(NSString*)anIdentifier;
48 + (id)itemWithTitle:(NSString*)aTitle identifier:(NSString*)anIdentifier icon:(NSImage*)anIcon;