判断是否静音:
- -
( BOOL)isMuted - {
-
CFStringRef route; -
UInt32 routeSize = sizeof(CFStringRef); -
-
OSStatus status = AudioSessionGetProperty(kAudioSessionProperty_AudioRoute, &routeSize, &route); -
if (status == kAudioSessionNoError) -
{ -
if (route == NULL || !CFStringGetLength(route)) -
return TRUE; -
} -
-
return FALSE;