From 991d014e0db6d1c0ca833cd968ece0887a1353f6 Mon Sep 17 00:00:00 2001 From: mrefaat Date: Wed, 17 Feb 2016 10:49:09 -0800 Subject: [ios] removed The CGRect zero check -drawViewHierarchyInRect Not needed any more after ios 7 is dropped BUG=421213 Review URL: https://codereview.chromium.org/1705793002 Cr-Commit-Position: refs/heads/master@{#375932} --- ios/chrome/browser/snapshots/snapshot_manager.mm | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'ios') diff --git a/ios/chrome/browser/snapshots/snapshot_manager.mm b/ios/chrome/browser/snapshots/snapshot_manager.mm index f14b46f..71c61f6 100644 --- a/ios/chrome/browser/snapshots/snapshot_manager.mm +++ b/ios/chrome/browser/snapshots/snapshot_manager.mm @@ -68,13 +68,8 @@ BOOL ViewHierarchyContainsWKWebView(UIView* view) { CGContextSaveGState(context); CGContextTranslateCTM(context, 0, overlay.yOffset); if (useDrawViewHierarchy) { - CGRect overlayRect = overlay.view.bounds; - // TODO(crbug.com/421213): The 0 check is needed for a UIKit crash on - // iOS 7. This can be removed once iOS 7 is dropped. - if (overlayRect.size.width > 0 && overlayRect.size.height > 0) { - [overlay.view drawViewHierarchyInRect:overlay.view.bounds - afterScreenUpdates:YES]; - } + [overlay.view drawViewHierarchyInRect:overlay.view.bounds + afterScreenUpdates:YES]; } else { [[overlay.view layer] renderInContext:context]; } -- cgit v1.1