摘要:
转自 http://alldunne.org/2011/09/how-to-pause-or-end-a-uiview-animation-via-the-calayer/-(void)pauseLayer:(CALayer*)layer{ CFTimeInterval paused_time = [layer convertTime:CACurrentMediaTime() fromLayer:nil]; layer.speed = 0.0; layer.timeOffset = paused_time; }-(void)resumeLayer:(CALayer*)layer{ ... 阅读全文
摘要:
转自http://www.devdiv.com/home.php?mod=space&uid=66974&do=blog&id=6472这些天一直在纠结这个问题:在后台有音乐播放时,我用AVAudioRecorder进行录音,后台音乐被无情的停止了,直到最近才解决!解决方法如下:首先,在开始录音之前,设置[[AVAudioSessionsharedInstance]setActive:YESerror:nil];[[AVAudioSessionsharedInstance]setCategory:AVAudioSessionCategoryPlayAndRecorder 阅读全文