| 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 6685 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6696 | 6696 |
| 6697 WebView* webView = webViewHelper.webView(); | 6697 WebView* webView = webViewHelper.webView(); |
| 6698 webView->resize(WebSize(800, 800)); | 6698 webView->resize(WebSize(800, 800)); |
| 6699 webView->updateAllLifecyclePhases(); | 6699 webView->updateAllLifecyclePhases(); |
| 6700 | 6700 |
| 6701 Document* document = toWebLocalFrameImpl(webView->mainFrame())->frame()->doc
ument(); | 6701 Document* document = toWebLocalFrameImpl(webView->mainFrame())->frame()->doc
ument(); |
| 6702 LayoutBlock* container = toLayoutBlock(document->getElementById("container")
->layoutObject()); | 6702 LayoutBlock* container = toLayoutBlock(document->getElementById("container")
->layoutObject()); |
| 6703 LayoutBox* percentHeightInAnonymous = toLayoutBox(document->getElementById("
percent-height-in-anonymous")->layoutObject()); | 6703 LayoutBox* percentHeightInAnonymous = toLayoutBox(document->getElementById("
percent-height-in-anonymous")->layoutObject()); |
| 6704 LayoutBox* percentHeightDirectChild = toLayoutBox(document->getElementById("
percent-height-direct-child")->layoutObject()); | 6704 LayoutBox* percentHeightDirectChild = toLayoutBox(document->getElementById("
percent-height-direct-child")->layoutObject()); |
| 6705 | 6705 |
| 6706 EXPECT_TRUE(LayoutBlock::hasPercentHeightDescendant(percentHeightInAnonymous
)); | 6706 EXPECT_TRUE(container->hasPercentHeightDescendant(percentHeightInAnonymous))
; |
| 6707 EXPECT_TRUE(LayoutBlock::hasPercentHeightDescendant(percentHeightDirectChild
)); | 6707 EXPECT_TRUE(container->hasPercentHeightDescendant(percentHeightDirectChild))
; |
| 6708 | 6708 |
| 6709 ASSERT_TRUE(container->percentHeightDescendants()); | 6709 ASSERT_TRUE(container->percentHeightDescendants()); |
| 6710 ASSERT_TRUE(container->hasPercentHeightDescendants()); | 6710 ASSERT_TRUE(container->hasPercentHeightDescendants()); |
| 6711 EXPECT_EQ(2U, container->percentHeightDescendants()->size()); | 6711 EXPECT_EQ(2U, container->percentHeightDescendants()->size()); |
| 6712 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightInA
nonymous)); | 6712 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightInA
nonymous)); |
| 6713 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightDir
ectChild)); | 6713 EXPECT_TRUE(container->percentHeightDescendants()->contains(percentHeightDir
ectChild)); |
| 6714 | 6714 |
| 6715 LayoutBlock* anonymousBlock = percentHeightInAnonymous->containingBlock(); | 6715 LayoutBlock* anonymousBlock = percentHeightInAnonymous->containingBlock(); |
| 6716 EXPECT_TRUE(anonymousBlock->isAnonymous()); | 6716 EXPECT_TRUE(anonymousBlock->isAnonymous()); |
| 6717 EXPECT_FALSE(anonymousBlock->hasPercentHeightDescendants()); | 6717 EXPECT_FALSE(anonymousBlock->hasPercentHeightDescendants()); |
| (...skipping 1729 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8447 } | 8447 } |
| 8448 | 8448 |
| 8449 TEST_F(WebFrameVisibilityChangeTest, RemoteFrameParentVisibilityChange) | 8449 TEST_F(WebFrameVisibilityChangeTest, RemoteFrameParentVisibilityChange) |
| 8450 { | 8450 { |
| 8451 swapLocalFrameToRemoteFrame(); | 8451 swapLocalFrameToRemoteFrame(); |
| 8452 executeScriptOnMainFrame(WebScriptSource("document.querySelector('iframe').p
arentElement.style.display = 'none';")); | 8452 executeScriptOnMainFrame(WebScriptSource("document.querySelector('iframe').p
arentElement.style.display = 'none';")); |
| 8453 EXPECT_FALSE(remoteFrameClient()->isVisible()); | 8453 EXPECT_FALSE(remoteFrameClient()->isVisible()); |
| 8454 } | 8454 } |
| 8455 | 8455 |
| 8456 } // namespace blink | 8456 } // namespace blink |
| OLD | NEW |