6
6
#import " FlutterRTCMediaStream.h"
7
7
#import " FlutterRTCPeerConnection.h"
8
8
#import " FlutterRTCVideoRenderer.h"
9
- #import " FlutterRTCMediaRecorder.h"
10
9
#import " FlutterRTCFrameCryptor.h"
11
10
#if TARGET_OS_IPHONE
11
+ #import " FlutterRTCMediaRecorder.h"
12
12
#import " FlutterRTCVideoPlatformViewFactory.h"
13
13
#import " FlutterRTCVideoPlatformViewController.h"
14
14
#endif
@@ -1507,8 +1507,9 @@ - (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result {
1507
1507
message: [NSString stringWithFormat: @" Error: peerConnection not found!" ]
1508
1508
details: nil ]);
1509
1509
}
1510
+ #if TARGET_OS_IOS
1510
1511
} else if ([@" startRecordToFile" isEqualToString: call.method]){
1511
- # if TARGET_OS_IOS
1512
+
1512
1513
NSDictionary * argsMap = call.arguments ;
1513
1514
NSNumber * recorderId = argsMap[@" recorderId" ];
1514
1515
NSString * path = argsMap[@" path" ];
@@ -1527,10 +1528,7 @@ - (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result {
1527
1528
];
1528
1529
}
1529
1530
result (nil );
1530
- #endif
1531
-
1532
1531
} else if ([@" stopRecordToFile" isEqualToString: call.method]) {
1533
- #if TARGET_OS_IOS
1534
1532
NSDictionary * argsMap = call.arguments ;
1535
1533
NSNumber * recorderId = argsMap[@" recorderId" ];
1536
1534
FlutterRTCMediaRecorder* recorder = self.recorders [recorderId];
@@ -1542,7 +1540,7 @@ - (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result {
1542
1540
message: [NSString stringWithFormat: @" Error: recorder with id %@ not found!" ,recorderId]
1543
1541
details: nil ]);
1544
1542
}
1545
- #endif
1543
+ #endif
1546
1544
} else {
1547
1545
[self handleFrameCryptorMethodCall: call result: result];
1548
1546
}
0 commit comments