2
UILocalNotification을 만들어 사용자 지정 사운드를 재생할 수는 있지만 전화를 진동시키지는 못합니까?소리와 진동이없는 UILocalNotification 만들기
편집 : 이것은 UILocalNotification을 만드는 데 사용한 코드입니다. 작동하지만 전화가 진동합니다. 휴대 전화가 진동하는 것을 원하지 않지만 소리를 내고 싶습니다. 당신이 소리를 원하는 경우 사용자가 일반 설정에 가서 장애인 진동 스스로하지 않는
UILocalNotification *notif = [[UILocalNotification alloc] init];
notif.fireDate = [NSDate dateWithTimeIntervalSinceNow:seconds];
notif.timeZone = [NSTimeZone defaultTimeZone];
//notif.alertBody = alertMessage;
//notif.alertAction = @"Show me";
notif.soundName = soundName;
notif.applicationIconBadgeNumber = 0;
NSDictionary *userDict = [NSDictionary dictionaryWithObject:soundName forKey:kCurrentSound];
notif.userInfo = userDict;
[[UIApplication sharedApplication] scheduleLocalNotification:notif];
[notif release];