| OLD | NEW |
| 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 6645 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6656 | 6656 |
| 6657 WebView* webView = webViewHelper.webView(); | 6657 WebView* webView = webViewHelper.webView(); |
| 6658 webViewHelper.resize(WebSize(800, 800)); | 6658 webViewHelper.resize(WebSize(800, 800)); |
| 6659 webView->updateAllLifecyclePhases(); | 6659 webView->updateAllLifecyclePhases(); |
| 6660 | 6660 |
| 6661 Document* document = toWebLocalFrameImpl(webView->mainFrame())->frame()->doc
ument(); | 6661 Document* document = toWebLocalFrameImpl(webView->mainFrame())->frame()->doc
ument(); |
| 6662 LayoutBlock* container = toLayoutBlock(document->getElementById("container")
->layoutObject()); | 6662 LayoutBlock* container = toLayoutBlock(document->getElementById("container")
->layoutObject()); |
| 6663 LayoutBox* percentHeightInAnonymous = toLayoutBox(document->getElementById("
percent-height-in-anonymous")->layoutObject()); | 6663 LayoutBox* percentHeightInAnonymous = toLayoutBox(document->getElementById("
percent-height-in-anonymous")->layoutObject()); |
| 6664 LayoutBox* percentHeightDirectChild = toLayoutBox(document->getElementById("
percent-height-direct-child")->layoutObject()); | 6664 LayoutBox* percentHeightDirectChild = toLayoutBox(document->getElementById("
percent-height-direct-child")->layoutObject()); |
| 6665 | 6665 |
| 6666 EXPECT_TRUE(LayoutBlock::hasPercentHeightDescendant(percentHeightInAnonymous
)); | 6666 EXPECT_TRUE(container->hasPercentHeightDescendant(percentHeightInAnonymous))
; |
| 6667 EXPECT_TRUE(LayoutBlock::hasPercentHeightDescendant(percentHeightDirectChild
)); | 6667 EXPECT_TRUE(container->hasPercentHeightDescendant(percentHeightDirectChild))
; |
| 6668 | 6668 |
| 6669 ASSERT_TRUE(container->percentHeightDescendants()); | 6669 ASSERT_TRUE(container->percentHeightDescendants()); |
| 6670 ASSERT_TRUE(container->hasPercentHeightDescendants()); | 6670 ASSERT_TRUE(container->hasPercentHeightDescendants()); |
| 6671 EXPECT_EQ(2U, container->percentHeightDescendants()->size()); | 6671 EXPECT_EQ(2U, container->percentHeightDescendants()->size()); |
| 6672 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightInA
nonymous)); | 6672 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightInA
nonymous)); |
| 6673 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightDir
ectChild)); | 6673 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightDir
ectChild)); |
| 6674 | 6674 |
| 6675 LayoutBlock* anonymousBlock = percentHeightInAnonymous->containingBlock(); | 6675 LayoutBlock* anonymousBlock = percentHeightInAnonymous->containingBlock(); |
| 6676 EXPECT_TRUE(anonymousBlock->isAnonymous()); | 6676 EXPECT_TRUE(anonymousBlock->isAnonymous()); |
| 6677 EXPECT_FALSE(anonymousBlock->hasPercentHeightDescendants()); | 6677 EXPECT_FALSE(anonymousBlock->hasPercentHeightDescendants()); |
| (...skipping 1727 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8405 } | 8405 } |
| 8406 | 8406 |
| 8407 TEST_F(WebFrameVisibilityChangeTest, RemoteFrameParentVisibilityChange) | 8407 TEST_F(WebFrameVisibilityChangeTest, RemoteFrameParentVisibilityChange) |
| 8408 { | 8408 { |
| 8409 swapLocalFrameToRemoteFrame(); | 8409 swapLocalFrameToRemoteFrame(); |
| 8410 executeScriptOnMainFrame(WebScriptSource("document.querySelector('iframe').p
arentElement.style.display = 'none';")); | 8410 executeScriptOnMainFrame(WebScriptSource("document.querySelector('iframe').p
arentElement.style.display = 'none';")); |
| 8411 EXPECT_FALSE(remoteFrameClient()->isVisible()); | 8411 EXPECT_FALSE(remoteFrameClient()->isVisible()); |
| 8412 } | 8412 } |
| 8413 | 8413 |
| 8414 } // namespace blink | 8414 } // namespace blink |
| OLD | NEW |