From f2ada31c1a4fa379c1b89a3f8a0c80a8f659b2e5 Mon Sep 17 00:00:00 2001 From: Todd Zullinger Date: Wed, 30 Jul 2008 15:27:34 +0000 Subject: Rename unk146 to explicit_flag in Itdb_Track now that it's purpose is known git-svn-id: https://gtkpod.svn.sf.net/svnroot/gtkpod/libgpod/trunk@2073 f01d2545-417e-4e96-918e-98f8d0dbbcb6 --- src/itdb.h | 5 +++-- src/itdb_itunesdb.c | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/itdb.h b/src/itdb.h index c5f1866..49d2d3c 100644 --- a/src/itdb.h +++ b/src/itdb.h @@ -833,8 +833,9 @@ struct _Itdb_Track files are 0x0029, WAV files are 0x0. itdb will attempt to set this value when adding a track. */ - guint16 unk146; /* unknown, but appears to be 1 if played at - least once in iTunes and 0 otherwise. */ + guint16 explicit_flag;/* If this flag is set to 1, the track is shown as + explicit content in iTunes. Otherwise set this flag + to 0.*/ guint32 unk148; /* unknown - used for Apple Store DRM songs (always 0x01010100?), zero otherwise */ guint32 unk152; /* unknown */ diff --git a/src/itdb_itunesdb.c b/src/itdb_itunesdb.c index e8d7e9b..2f45320 100644 --- a/src/itdb_itunesdb.c +++ b/src/itdb_itunesdb.c @@ -2309,7 +2309,7 @@ static glong get_mhit (FImport *fimp, glong mhit_seek) track->time_released = device_time_mac_to_time_t (fimp->itdb->device, track->time_released); track->unk144 = get16lint (cts, seek+144); - track->unk146 = get16lint (cts, seek+146); + track->explicit_flag = get16lint (cts, seek+146); track->unk148 = get32lint (cts, seek+148); track->unk152 = get32lint (cts, seek+152); } @@ -3607,7 +3607,7 @@ static void mk_mhit (WContents *cts, Itdb_Track *track) mac_time = device_time_time_t_to_mac (track->itdb->device, track->time_released); put32lint (cts, mac_time); put16lint (cts, track->unk144); - put16lint (cts, track->unk146); + put16lint (cts, track->explicit_flag); put32lint (cts, track->unk148); put32lint (cts, track->unk152); /* since iTunesDB version 0x0c */ -- cgit