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

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

Issue 2849173002: Set GPU rasterization trigger for OOPIFs (Closed)
Patch Set: Created 3 years, 7 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
« no previous file with comments | « no previous file | no next file » | 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) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 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 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after
1040 layer_tree_view_->CompositorAnimationHost()); 1040 layer_tree_view_->CompositorAnimationHost());
1041 } 1041 }
1042 1042
1043 if (WebDevToolsAgentImpl* dev_tools = local_root_->DevToolsAgentImpl()) 1043 if (WebDevToolsAgentImpl* dev_tools = local_root_->DevToolsAgentImpl())
1044 dev_tools->LayerTreeViewChanged(layer_tree_view_); 1044 dev_tools->LayerTreeViewChanged(layer_tree_view_);
1045 1045
1046 GetPage()->GetSettings().SetAcceleratedCompositingEnabled(layer_tree_view_); 1046 GetPage()->GetSettings().SetAcceleratedCompositingEnabled(layer_tree_view_);
1047 if (layer_tree_view_) { 1047 if (layer_tree_view_) {
1048 GetPage()->LayerTreeViewInitialized(*layer_tree_view_, 1048 GetPage()->LayerTreeViewInitialized(*layer_tree_view_,
1049 local_root_->GetFrame()->View()); 1049 local_root_->GetFrame()->View());
1050
1051 // TODO(kenrb): Currently GPU rasterization is always enabled for OOPIFs.
1052 // This is okay because it is only necessarily to set the trigger to false
1053 // for certain cases that affect the top-level frame, but it would be better
1054 // to be consistent with the top-level frame. Ideally the logic should
1055 // be moved from WebViewImpl into WebFrameWidget and used for all local
1056 // frame roots. https://crbug.com/712794
1057 layer_tree_view_->HeuristicsForGpuRasterizationUpdated(true);
1050 } 1058 }
1051 1059
1052 // FIXME: only unittests, click to play, Android priting, and printing (for 1060 // FIXME: only unittests, click to play, Android priting, and printing (for
1053 // headers and footers) make this assert necessary. We should make them not 1061 // headers and footers) make this assert necessary. We should make them not
1054 // hit this code and then delete allowsBrokenNullLayerTreeView. 1062 // hit this code and then delete allowsBrokenNullLayerTreeView.
1055 DCHECK(layer_tree_view_ || client_->AllowsBrokenNullLayerTreeView()); 1063 DCHECK(layer_tree_view_ || client_->AllowsBrokenNullLayerTreeView());
1056 } 1064 }
1057 1065
1058 void WebFrameWidgetImpl::SetIsAcceleratedCompositingActive(bool active) { 1066 void WebFrameWidgetImpl::SetIsAcceleratedCompositingActive(bool active) {
1059 // In the middle of shutting down; don't try to spin back up a compositor. 1067 // In the middle of shutting down; don't try to spin back up a compositor.
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
1178 return nullptr; 1186 return nullptr;
1179 } 1187 }
1180 1188
1181 LocalFrame* WebFrameWidgetImpl::FocusedLocalFrameAvailableForIme() const { 1189 LocalFrame* WebFrameWidgetImpl::FocusedLocalFrameAvailableForIme() const {
1182 if (!ime_accept_events_) 1190 if (!ime_accept_events_)
1183 return nullptr; 1191 return nullptr;
1184 return FocusedLocalFrameInWidget(); 1192 return FocusedLocalFrameInWidget();
1185 } 1193 }
1186 1194
1187 } // namespace blink 1195 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698