我試圖在越獄的iPhone上的iTunes目錄中獲取自定義鈴聲的名稱。我可以成功列出自定義鈴聲,但他們重新顯示爲HWYH1.m4r
,這是iTunes重命名文件的內容,但我知道這是解密歌曲實際名稱的一種方法。來自plist詞典的UITableView KEYS,iOS
NSMutableDictionary *custDict = [[NSMutableDictionary alloc] initWithContentsOfFile:@"/iPhoneOS/private/var/mobile/Media/iTunes_Control/iTunes/Ringtones.plist"];
NSMutableDictionary *dictionary = [custDict objectForKey:@"Ringtones"];
NSMutableArray *customRingtone = [[dictionary objectForKey:@"Name"] objectAtIndex:indexPath.row];
NSLog(@"name: %@",[customRingtone objectAtIndex:indexPath.row]);
cell.textLabel.text = [customRingtone objectAtIndex:indexPath.row];
dictionary
將返回:
"YBRZ.m4r" =
{
GUID = 17A52A505A42D076;
Name = "Wild West";
"Total Time" = 5037;
};
cell.textLabel.text
將返回:name: (null)
那麼...你的問題是什麼? – 2009-12-29 01:39:01
我怎樣才能cell.textLabel =從陣列的名字? – WrightsCS 2009-12-29 01:48:54