File tree Expand file tree Collapse file tree 2 files changed +9
-10
lines changed Expand file tree Collapse file tree 2 files changed +9
-10
lines changed Original file line number Diff line number Diff line change 12
12
#define kCustomProtocolScheme @" wvjbscheme"
13
13
#define kQueueHasMessage @" __WVJB_QUEUE_MESSAGE__"
14
14
15
- #if TARGET_OS_IPHONE && defined(__IPHONE_5_0) && (__IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_5_0)
16
- #define WVJB_WEAK_FALLBACK weak
17
- #elif TARGET_OS_MAC && defined(__MAC_10_7) && (__MAC_OS_X_VERSION_MAX_ALLOWED >= __MAC_10_7)
18
- #define WVJB_WEAK_FALLBACK weak
19
- #else
20
- #define WVJB_WEAK_FALLBACK unsafe_unretained
21
- #endif
22
-
23
15
#if defined __MAC_OS_X_VERSION_MAX_ALLOWED
24
16
#import < WebKit/WebKit.h>
25
17
#define WVJB_PLATFORM_OSX
Original file line number Diff line number Diff line change 8
8
9
9
#import " WebViewJavascriptBridge.h"
10
10
11
+ #if __has_feature(objc_arc_weak)
12
+ #define WVJB_WEAK __weak
13
+ #else
14
+ #define WVJB_WEAK __unsafe_unretained
15
+ #endif
16
+
17
+
11
18
@implementation WebViewJavascriptBridge {
12
- __weak WVJB_WEBVIEW_TYPE* _webView;
13
- __weak id _webViewDelegate;
19
+ WVJB_WEAK WVJB_WEBVIEW_TYPE* _webView;
20
+ WVJB_WEAK id _webViewDelegate;
14
21
NSMutableArray * _startupMessageQueue;
15
22
NSMutableDictionary * _responseCallbacks;
16
23
NSMutableDictionary * _messageHandlers;
You can’t perform that action at this time.
0 commit comments