<!DOCTYPE html> <html> <head> <style type="text/css" media="screen"> iframe { margin: 20px; height: 200px; width: 200px; border: 1px solid black; } .composited { transform: translateZ(0); } </style> <script src="../../resources/run-after-layout-and-paint.js"></script> <script type="text/javascript" charset="utf-8"> function doTest() { if (window.testRunner) testRunner.waitUntilDone(); runAfterLayoutAndPaint(function() { document.getElementById('iframe').className = 'composited'; if (window.testRunner) testRunner.notifyDone(); }); } window.addEventListener('load', doTest, false); </script> </head> <body> <!-- Test with already-composited iframe contents, and iframe itself composited. --> <!-- You should see a green square, no red. --> <iframe id="iframe" scrolling="no" src="resources/red-green-subframe.html"></iframe> </body> </html>