fix(iOS): Adds missing silent hardware declaration to header file (#1319)
* Fixes Issue #1140 Fixes https://github.com/react-native-community/react-native-webview/issues/1140 Based on a solution found at: https://stackoverflow.com/questions/56460362/how-to-force-wkwebview-to-ignore-hardware-silent-switch-on-ios I changed the code found in the linked source from Swift to Objective-C, as required by this project. WARNING: I haven't used Swift before and very limited experience with Objective-C. - For me this seems to work, but it is not the cleanest solution in my opinion. - It might also be possible to play generated sound (i.e. using oscillator) instead of hardcoding the silent base64 mp3 data. - Maybe ignoring silence switch should only be done if a parameter is supplied * fixes import path * adds documentation for ignoreSilentHardwareSwitch * adds ignoreSilentHardwareSwitch parameter * reverting back to old import path * Update Guide.md * adds missing variable Co-authored-by: Dominik Beste <dominik.beste@gmail.com>
This commit is contained in:
parent
5c6d137067
commit
2b4d752c32
|
@ -59,6 +59,7 @@
|
||||||
@property (nonatomic, assign) BOOL showsHorizontalScrollIndicator;
|
@property (nonatomic, assign) BOOL showsHorizontalScrollIndicator;
|
||||||
@property (nonatomic, assign) BOOL showsVerticalScrollIndicator;
|
@property (nonatomic, assign) BOOL showsVerticalScrollIndicator;
|
||||||
@property (nonatomic, assign) BOOL directionalLockEnabled;
|
@property (nonatomic, assign) BOOL directionalLockEnabled;
|
||||||
|
@property (nonatomic, assign) BOOL ignoreSilentHardwareSwitch;
|
||||||
@property (nonatomic, copy) NSString * _Nullable allowingReadAccessToURL;
|
@property (nonatomic, copy) NSString * _Nullable allowingReadAccessToURL;
|
||||||
|
|
||||||
+ (void)setClientAuthenticationCredential:(nullable NSURLCredential*)credential;
|
+ (void)setClientAuthenticationCredential:(nullable NSURLCredential*)credential;
|
||||||
|
|
Loading…
Reference in New Issue