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

Side by Side Diff: third_party/WebKit/Source/web/WebLocalFrameImpl.cpp

Issue 1565893004: Sets a transparent background for out-of-process subframes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: compile Created 4 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 1629 matching lines...) Expand 10 before | Expand all | Expand 10 after
1640 void WebLocalFrameImpl::createFrameView() 1640 void WebLocalFrameImpl::createFrameView()
1641 { 1641 {
1642 TRACE_EVENT0("blink", "WebLocalFrameImpl::createFrameView"); 1642 TRACE_EVENT0("blink", "WebLocalFrameImpl::createFrameView");
1643 1643
1644 ASSERT(frame()); // If frame() doesn't exist, we probably didn't init proper ly. 1644 ASSERT(frame()); // If frame() doesn't exist, we probably didn't init proper ly.
1645 1645
1646 WebViewImpl* webView = viewImpl(); 1646 WebViewImpl* webView = viewImpl();
1647 1647
1648 bool isMainFrame = !parent(); 1648 bool isMainFrame = !parent();
1649 IntSize initialSize = (isMainFrame || !frameWidget()) ? webView->mainFrameSi ze() : (IntSize)frameWidget()->size(); 1649 IntSize initialSize = (isMainFrame || !frameWidget()) ? webView->mainFrameSi ze() : (IntSize)frameWidget()->size();
1650 bool isTransparent = !isMainFrame && parent()->isWebRemoteFrame() ? true : w ebView->isTransparent();
1650 1651
1651 frame()->createView(initialSize, webView->baseBackgroundColor(), webView->is Transparent()); 1652 frame()->createView(initialSize, webView->baseBackgroundColor(), isTranspare nt);
1652 if (webView->shouldAutoResize() && frame()->isLocalRoot()) 1653 if (webView->shouldAutoResize() && frame()->isLocalRoot())
1653 frame()->view()->enableAutoSizeMode(webView->minAutoSize(), webView->max AutoSize()); 1654 frame()->view()->enableAutoSizeMode(webView->minAutoSize(), webView->max AutoSize());
1654 1655
1655 frame()->view()->setInputEventsTransformForEmulation(m_inputEventsOffsetForE mulation, m_inputEventsScaleFactorForEmulation); 1656 frame()->view()->setInputEventsTransformForEmulation(m_inputEventsOffsetForE mulation, m_inputEventsScaleFactorForEmulation);
1656 frame()->view()->setDisplayMode(webView->displayMode()); 1657 frame()->view()->setDisplayMode(webView->displayMode());
1657 } 1658 }
1658 1659
1659 WebLocalFrameImpl* WebLocalFrameImpl::fromFrame(LocalFrame* frame) 1660 WebLocalFrameImpl* WebLocalFrameImpl::fromFrame(LocalFrame* frame)
1660 { 1661 {
1661 if (!frame) 1662 if (!frame)
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
2196 return WebSandboxFlags::None; 2197 return WebSandboxFlags::None;
2197 return static_cast<WebSandboxFlags>(frame()->loader().effectiveSandboxFlags( )); 2198 return static_cast<WebSandboxFlags>(frame()->loader().effectiveSandboxFlags( ));
2198 } 2199 }
2199 2200
2200 void WebLocalFrameImpl::forceSandboxFlags(WebSandboxFlags flags) 2201 void WebLocalFrameImpl::forceSandboxFlags(WebSandboxFlags flags)
2201 { 2202 {
2202 frame()->loader().forceSandboxFlags(static_cast<SandboxFlags>(flags)); 2203 frame()->loader().forceSandboxFlags(static_cast<SandboxFlags>(flags));
2203 } 2204 }
2204 2205
2205 } // namespace blink 2206 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/WebFrameWidgetImpl.cpp ('k') | third_party/WebKit/Source/web/WebViewFrameWidget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698