Skip to content
This repository has been archived by the owner on Jun 3, 2021. It is now read-only.

Commit

Permalink
[WEEX-484][iOS] Failure of parsing transform parameter when in third-…
Browse files Browse the repository at this point in the history
…party environment
  • Loading branch information
doumafang committed Jun 28, 2018
1 parent aebd432 commit 7f6ea01
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions ios/sdk/WeexSDK/Sources/Component/WXTransform.m
Original file line number Diff line number Diff line change
Expand Up @@ -260,16 +260,17 @@ - (void)parseTransform:(NSString *)cssValue
if ([self respondsToSelector:method]) {
@try {
id<WXConfigCenterProtocol> configCenter = [WXSDKEngine handlerForProtocol:@protocol(WXConfigCenterProtocol)];
BOOL parseTransformIfWaitUntilDone = NO;
if ([configCenter respondsToSelector:@selector(configForKey:defaultValue:isDefault:)]) {
BOOL parseTransformIfWaitUntilDone = [[configCenter configForKey:@"iOS_weex_ext_config.parseTransformIfWaitUntilDone" defaultValue:@(NO) isDefault:NULL] boolValue];
if (parseTransformIfWaitUntilDone) {
[self performSelectorOnMainThread:method withObject:value waitUntilDone:YES];
}
else{
IMP imp = [self methodForSelector:method];
void (*func)(id, SEL,NSArray *) = (void *)imp;
func(self, method,value);
}
parseTransformIfWaitUntilDone = [[configCenter configForKey:@"iOS_weex_ext_config.parseTransformIfWaitUntilDone" defaultValue:@(NO) isDefault:NULL] boolValue];
}
if (parseTransformIfWaitUntilDone) {
[self performSelectorOnMainThread:method withObject:value waitUntilDone:YES];
}
else{
IMP imp = [self methodForSelector:method];
void (*func)(id, SEL,NSArray *) = (void *)imp;
func(self, method,value);
}
}
@catch (NSException *exception) {
Expand Down

0 comments on commit 7f6ea01

Please sign in to comment.