Skip to content

Commit

Permalink
Adding function to test if a playlist is smart.
Browse files Browse the repository at this point in the history
Removing misplaced semicolon.
  • Loading branch information
kgn committed Dec 6, 2010
1 parent 79b6bd6 commit 9186d92
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions ETPlaylist.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
- (NSString *)name;
- (DescType) specialKind;
- (BOOL) isSpecialKind;
- (BOOL) isSmart;
- (BOOL) isCached;

- (unsigned long long) parentPlaylistId;
Expand Down
7 changes: 6 additions & 1 deletion ETPlaylist.m
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,16 @@ - (NSString *)name
}


- (DescType) specialKind;
- (DescType) specialKind
{
return [self getPropertyAsEnumForDesc:ET_PLAYLIST_PROP_SPECIAL_KIND];
}

- (BOOL) isSmart
{
return [self getPropertyAsIntegerForDesc:ET_PLAYLIST_PROP_SMART];
}

- (NSArray *)tracks
{
return [[self trackEnumerator] allObjects];
Expand Down
1 change: 1 addition & 0 deletions EyeTunesEventCodes.h
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,7 @@ enum {
#define ET_PLAYLIST_PROP_TIME 'pTim' // utxt (r)
#define ET_PLAYLIST_PROP_VISIBLE 'pvis' // bool (r)
#define ET_PLAYLIST_PROP_PARENT 'pPlP' // <property name="parent" code="pPlP" type="playlist" access="r" description="folder which contains this playlist (if any)"/>
#define ET_PLAYLIST_PROP_SMART 'pSmt' // bool (r)
// generic playlist properies ---

// -- special playlists --
Expand Down

0 comments on commit 9186d92

Please sign in to comment.