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

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

Issue 27030009: Revert "Make compositingState explicit (re-land #2 with bogus ASSERT removed)" (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix build error Created 7 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « Source/web/LinkHighlight.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) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 // all the way to the WebLayer. 285 // all the way to the WebLayer.
286 Element* scrollableElement = m_webViewImpl->mainFrameImpl()->frame()->docume nt()->getElementById("scrollable"); 286 Element* scrollableElement = m_webViewImpl->mainFrameImpl()->frame()->docume nt()->getElementById("scrollable");
287 ASSERT(scrollableElement); 287 ASSERT(scrollableElement);
288 288
289 RenderObject* renderer = scrollableElement->renderer(); 289 RenderObject* renderer = scrollableElement->renderer();
290 ASSERT_TRUE(renderer->isBoxModelObject()); 290 ASSERT_TRUE(renderer->isBoxModelObject());
291 ASSERT_TRUE(renderer->hasLayer()); 291 ASSERT_TRUE(renderer->hasLayer());
292 292
293 RenderLayer* layer = toRenderBoxModelObject(renderer)->layer(); 293 RenderLayer* layer = toRenderBoxModelObject(renderer)->layer();
294 ASSERT_TRUE(layer->usesCompositedScrolling()); 294 ASSERT_TRUE(layer->usesCompositedScrolling());
295 ASSERT_EQ(PaintsIntoOwnBacking, layer->compositingState()); 295 ASSERT_TRUE(layer->isComposited());
296 296
297 CompositedLayerMapping* compositedLayerMapping = layer->compositedLayerMappi ng(); 297 CompositedLayerMapping* compositedLayerMapping = layer->compositedLayerMappi ng();
298 ASSERT_TRUE(compositedLayerMapping->hasScrollingLayer()); 298 ASSERT_TRUE(compositedLayerMapping->hasScrollingLayer());
299 ASSERT(compositedLayerMapping->scrollingContentsLayer()); 299 ASSERT(compositedLayerMapping->scrollingContentsLayer());
300 300
301 GraphicsLayer* graphicsLayer = compositedLayerMapping->scrollingContentsLaye r(); 301 GraphicsLayer* graphicsLayer = compositedLayerMapping->scrollingContentsLaye r();
302 ASSERT_EQ(layer->scrollableArea(), graphicsLayer->scrollableArea()); 302 ASSERT_EQ(layer->scrollableArea(), graphicsLayer->scrollableArea());
303 303
304 WebLayer* webScrollLayer = compositedLayerMapping->scrollingContentsLayer()- >platformLayer(); 304 WebLayer* webScrollLayer = compositedLayerMapping->scrollingContentsLayer()- >platformLayer();
305 ASSERT_TRUE(webScrollLayer->scrollable()); 305 ASSERT_TRUE(webScrollLayer->scrollable());
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 397
398 TEST_F(ScrollingCoordinatorChromiumTest, setupScrollbarLayerShouldNotCrash) 398 TEST_F(ScrollingCoordinatorChromiumTest, setupScrollbarLayerShouldNotCrash)
399 { 399 {
400 registerMockedHttpURLLoad("setup_scrollbar_layer_crash.html"); 400 registerMockedHttpURLLoad("setup_scrollbar_layer_crash.html");
401 navigateTo(m_baseURL + "setup_scrollbar_layer_crash.html"); 401 navigateTo(m_baseURL + "setup_scrollbar_layer_crash.html");
402 // This test document setup an iframe with scrollbars, then switch to 402 // This test document setup an iframe with scrollbars, then switch to
403 // an empty document by javascript. 403 // an empty document by javascript.
404 } 404 }
405 405
406 } // namespace 406 } // namespace
OLDNEW
« no previous file with comments | « Source/web/LinkHighlight.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698