Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(55)

Side by Side Diff: Source/web/tests/WebFrameTest.cpp

Issue 1162623007: Removed redundant rect methods on FrameView (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/web/WebViewImpl.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 1786 matching lines...) Expand 10 before | Expand all | Expand 10 after
1797 int viewportHeightMinusScrollbar = viewportHeight; 1797 int viewportHeightMinusScrollbar = viewportHeight;
1798 1798
1799 if (view->verticalScrollbar() && !view->verticalScrollbar()->isOverlayScroll bar()) 1799 if (view->verticalScrollbar() && !view->verticalScrollbar()->isOverlayScroll bar())
1800 viewportWidthMinusScrollbar -= 15; 1800 viewportWidthMinusScrollbar -= 15;
1801 1801
1802 if (view->horizontalScrollbar() && !view->horizontalScrollbar()->isOverlaySc rollbar()) 1802 if (view->horizontalScrollbar() && !view->horizontalScrollbar()->isOverlaySc rollbar())
1803 viewportHeightMinusScrollbar -= 15; 1803 viewportHeightMinusScrollbar -= 15;
1804 1804
1805 webViewHelper.webView()->setPageScaleFactor(2); 1805 webViewHelper.webView()->setPageScaleFactor(2);
1806 1806
1807 IntSize unscaledSize = view->unscaledVisibleContentSize(IncludeScrollbars); 1807 IntSize unscaledSize = view->visibleContentSize(IncludeScrollbars);
1808 EXPECT_EQ(viewportWidth, unscaledSize.width()); 1808 EXPECT_EQ(viewportWidth, unscaledSize.width());
1809 EXPECT_EQ(viewportHeight, unscaledSize.height()); 1809 EXPECT_EQ(viewportHeight, unscaledSize.height());
1810 1810
1811 IntSize unscaledSizeMinusScrollbar = view->unscaledVisibleContentSize(Exclud eScrollbars); 1811 IntSize unscaledSizeMinusScrollbar = view->visibleContentSize(ExcludeScrollb ars);
1812 EXPECT_EQ(viewportWidthMinusScrollbar, unscaledSizeMinusScrollbar.width()); 1812 EXPECT_EQ(viewportWidthMinusScrollbar, unscaledSizeMinusScrollbar.width());
1813 EXPECT_EQ(viewportHeightMinusScrollbar, unscaledSizeMinusScrollbar.height()) ; 1813 EXPECT_EQ(viewportHeightMinusScrollbar, unscaledSizeMinusScrollbar.height()) ;
1814 1814
1815 IntSize frameViewSize = view->visibleContentRect().size(); 1815 IntSize frameViewSize = view->visibleContentRect().size();
1816 EXPECT_EQ(viewportWidthMinusScrollbar, frameViewSize.width()); 1816 EXPECT_EQ(viewportWidthMinusScrollbar, frameViewSize.width());
1817 EXPECT_EQ(viewportHeightMinusScrollbar, frameViewSize.height()); 1817 EXPECT_EQ(viewportHeightMinusScrollbar, frameViewSize.height());
1818 } 1818 }
1819 1819
1820 TEST_F(WebFrameTest, pageScaleFactorDoesNotApplyCssTransform) 1820 TEST_F(WebFrameTest, pageScaleFactorDoesNotApplyCssTransform)
1821 { 1821 {
(...skipping 5513 matching lines...) Expand 10 before | Expand all | Expand 10 after
7335 7335
7336 EXPECT_EQ(parent, firstFrame->parent()); 7336 EXPECT_EQ(parent, firstFrame->parent());
7337 EXPECT_EQ(parent, secondFrame->parent()); 7337 EXPECT_EQ(parent, secondFrame->parent());
7338 EXPECT_EQ(parent, thirdFrame->parent()); 7338 EXPECT_EQ(parent, thirdFrame->parent());
7339 EXPECT_EQ(parent, fourthFrame->parent()); 7339 EXPECT_EQ(parent, fourthFrame->parent());
7340 7340
7341 view->close(); 7341 view->close();
7342 } 7342 }
7343 7343
7344 } // namespace blink 7344 } // namespace blink
OLDNEW
« no previous file with comments | « Source/web/WebViewImpl.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698