Skip to content

Commit

Permalink
* [ios] bugfix rootView information coordinate
Browse files Browse the repository at this point in the history
  • Loading branch information
acton393 committed Jan 9, 2017
1 parent 63f1bf4 commit 7313703
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ios/sdk/WeexSDK/Sources/Module/WXDomModule.m
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,8 @@ - (void)getComponentRect:(NSString*)ref callback:(WXModuleKeepAliveCallback)call
[self performBlockOnComponentMananger:^(WXComponentManager * manager) {
NSMutableDictionary * callbackRsp = [[NSMutableDictionary alloc] init];
UIView *rootView = manager.weexInstance.rootView;
CGRect rootRect = [rootView.superview convertRect:rootView.frame toView:rootView.superview.superview];
CGRect rootRect = [rootView convertRect:rootView.frame toView:rootView];
rootRect.origin = CGPointZero;
CGFloat scaleFactor = self.weexInstance.pixelScaleFactor;
if ([ref isEqualToString:@"viewport"]) {
[callbackRsp setObject:@(true) forKey:@"result"];
Expand Down

0 comments on commit 7313703

Please # to comment.