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

Side by Side Diff: sky/engine/core/frame/FrameView.cpp

Issue 737523002: Sky: Move iframe geometry updates to FrameView::updateLayout instead of (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: . Created 6 years, 1 month 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
« no previous file with comments | « sky/engine/core/frame/FrameView.h ('k') | sky/engine/core/rendering/RenderIFrame.h » ('j') | 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) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Dirk Mueller <mueller@kde.org> 5 * 2000 Dirk Mueller <mueller@kde.org>
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com)
8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * Copyright (C) 2009 Google Inc. All rights reserved. 9 * Copyright (C) 2009 Google Inc. All rights reserved.
10 * 10 *
(...skipping 940 matching lines...) Expand 10 before | Expand all | Expand 10 after
951 { 951 {
952 m_nodeToDraw = node; 952 m_nodeToDraw = node;
953 } 953 }
954 954
955 void FrameView::updateLayoutAndStyleForPainting() 955 void FrameView::updateLayoutAndStyleForPainting()
956 { 956 {
957 // Updating layout can run script, which can tear down the FrameView. 957 // Updating layout can run script, which can tear down the FrameView.
958 RefPtr<FrameView> protector(this); 958 RefPtr<FrameView> protector(this);
959 959
960 updateLayoutAndStyleIfNeededRecursive(); 960 updateLayoutAndStyleIfNeededRecursive();
961 updateIFramesAfterLayout();
961 962
962 if (RenderView* view = renderView()) { 963 if (RenderView* view = renderView()) {
963 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Up dateLayerTree", TRACE_EVENT_SCOPE_PROCESS, "frame", m_frame.get()); 964 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Up dateLayerTree", TRACE_EVENT_SCOPE_PROCESS, "frame", m_frame.get());
964 view->compositor()->updateIfNeededRecursive(); 965 view->compositor()->updateIfNeededRecursive();
965 966
966 updateCompositedSelectionBoundsIfNeeded(); 967 updateCompositedSelectionBoundsIfNeeded();
967 968
968 invalidateTreeIfNeededRecursive(); 969 invalidateTreeIfNeededRecursive();
969 } 970 }
970 971
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
1111 1112
1112 void FrameView::setLayoutSizeInternal(const IntSize& size) 1113 void FrameView::setLayoutSizeInternal(const IntSize& size)
1113 { 1114 {
1114 if (m_layoutSize == size) 1115 if (m_layoutSize == size)
1115 return; 1116 return;
1116 1117
1117 m_layoutSize = size; 1118 m_layoutSize = size;
1118 contentsResized(); 1119 contentsResized();
1119 } 1120 }
1120 1121
1122 void FrameView::addIFrame(RenderIFrame* iframe)
1123 {
1124 m_iframes.add(iframe);
1125 }
1126
1127 void FrameView::removeIFrame(RenderIFrame* iframe)
1128 {
1129 m_iframes.remove(iframe);
esprehn 2014/11/17 20:07:49 I don't think you need this change, we should trac
Matt Perry 2014/11/17 20:18:17 Done.
1130 }
1131
1132 void FrameView::updateIFramesAfterLayout()
1133 {
1134 for (auto& iframe: m_iframes)
1135 iframe->updateWidgetBounds();
1136 }
1137
1121 } // namespace blink 1138 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/frame/FrameView.h ('k') | sky/engine/core/rendering/RenderIFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698