Changeset 294888 in webkit
- Timestamp:
- May 26, 2022, 12:50:46 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm
r294790 r294888 1603 1603 auto frame = WebCore::FloatSize(self.frame.size); 1604 1604 1605 auto minimumUnobscuredSize = frame - WebCore::FloatSize(maximumViewportInset.left + maximumViewportInset.right, maximumViewportInset.top + maximumViewportInset.bottom); 1605 auto maximumViewportInsetSize = WebCore::FloatSize(maximumViewportInset.left + maximumViewportInset.right, maximumViewportInset.top + maximumViewportInset.bottom); 1606 auto minimumUnobscuredSize = frame - maximumViewportInsetSize; 1606 1607 if (minimumUnobscuredSize.isEmpty()) { 1607 if (throwOnInvalidInput) { 1608 [NSException raise:NSInvalidArgumentException format:@"maximumViewportInset cannot be larger than frame"]; 1609 return; 1608 if (!maximumViewportInsetSize.isEmpty()) { 1609 if (throwOnInvalidInput) { 1610 [NSException raise:NSInvalidArgumentException format:@"maximumViewportInset cannot be larger than frame"]; 1611 return; 1612 } 1613 1614 RELEASE_LOG_ERROR(ViewportSizing, "maximumViewportInset cannot be larger than frame"); 1610 1615 } 1611 1616 1612 RELEASE_LOG_ERROR(ViewportSizing, "maximumViewportInset cannot be larger than frame");1613 1617 minimumUnobscuredSize = frame; 1614 1618 } 1615 1619 1616 auto maximumUnobscuredSize = frame - WebCore::FloatSize(minimumViewportInset.left + minimumViewportInset.right, minimumViewportInset.top + minimumViewportInset.bottom); 1620 auto minimumViewportInsetSize = WebCore::FloatSize(minimumViewportInset.left + minimumViewportInset.right, minimumViewportInset.top + minimumViewportInset.bottom); 1621 auto maximumUnobscuredSize = frame - minimumViewportInsetSize; 1617 1622 if (maximumUnobscuredSize.isEmpty()) { 1618 if (throwOnInvalidInput) { 1619 [NSException raise:NSInvalidArgumentException format:@"minimumViewportInset cannot be larger than frame"]; 1620 return; 1623 if (!minimumViewportInsetSize.isEmpty()) { 1624 if (throwOnInvalidInput) { 1625 [NSException raise:NSInvalidArgumentException format:@"minimumViewportInset cannot be larger than frame"]; 1626 return; 1627 } 1628 1629 RELEASE_LOG_ERROR(ViewportSizing, "minimumViewportInset cannot be larger than frame"); 1621 1630 } 1622 1631 1623 RELEASE_LOG_ERROR(ViewportSizing, "minimumViewportInset cannot be larger than frame");1624 1632 maximumUnobscuredSize = frame; 1625 1633 }
Note:
See TracChangeset
for help on using the changeset viewer.