| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- //
- // webRtcPlayerViewController+AppDelegate.m
- // 双子星云手机
- //
- // Created by xd h on 2024/9/18.
- //
- #import "webRtcPlayerViewController+AppDelegate.h"
- @implementation webRtcPlayerViewController (AppDelegate)
- #pragma mark - UIApplication Delegate
- - (void)applicationWillResignActive:(NSNotification *)notification
- {
- //HLog(@"11111");
- }
- - (void)applicationDidEnterBackground:(NSNotification *)notification {
- // app进入后台时
- [self pauseStream];
- }
- - (void)applicationDidBecomeActive:(NSNotification *)notification
- {
- if(!ksharedAppDelegate.isDidShowPwdType){
- [self resumeStream];
- }
- }
- - (void)applicationWillTerminate:(UIApplication *)application {
- // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
-
- [self.mediaStream disconnect];
- }
- #pragma mark 云机停止拉流
- - (void)pauseStream
- {
- [self.mediaStream pauseStream];
- }
- #pragma mark 云机唤醒拉流
- - (void)resumeStream
- {
- [self.mediaStream resumeStream];
- }
- #pragma mark 输入密码完成
- - (void)didInpuPwdOkFun
- {
- [self resumeStream];
- }
- @end
|