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

Unified Diff: chrome/browser/android/compositor/layer/content_layer.h

Issue 2499863002: Simplify content_layer attachment and viewporting logic. (Closed)
Patch Set: Fix clang error Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/android/compositor/layer/content_layer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/compositor/layer/content_layer.h
diff --git a/chrome/browser/android/compositor/layer/content_layer.h b/chrome/browser/android/compositor/layer/content_layer.h
index 0a894e1e22cabe02ca43d2a6f9c357e4015cbe89..67360632091a3e0d38bc763dfc3c318e7395b2a6 100644
--- a/chrome/browser/android/compositor/layer/content_layer.h
+++ b/chrome/browser/android/compositor/layer/content_layer.h
@@ -8,7 +8,6 @@
#include <memory>
#include "base/macros.h"
-#include "cc/output/filter_operations.h"
#include "chrome/browser/android/compositor/layer/layer.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/geometry/size.h"
@@ -36,10 +35,8 @@ class ContentLayer : public Layer {
bool should_override_content_alpha,
float content_alpha_override,
float saturation,
- const gfx::Rect& desired_bounds,
- const gfx::Size& content_size);
- bool ShowingLiveLayer() { return !static_attached_ && content_attached_; }
- gfx::Size GetContentSize();
+ bool should_clip,
+ const gfx::Rect& clip);
scoped_refptr<cc::Layer> layer() override;
@@ -50,18 +47,11 @@ class ContentLayer : public Layer {
private:
void SetContentLayer(scoped_refptr<cc::Layer> layer);
void SetStaticLayer(scoped_refptr<ThumbnailLayer> layer);
- void ClipContentLayer(scoped_refptr<cc::Layer> content_layer,
- gfx::Rect clipping);
- void ClipStaticLayer(scoped_refptr<ThumbnailLayer> static_layer,
- gfx::Rect clipping);
+ // This is an intermediate shim layer whose children are
+ // both the static and content layers (or either, or none, depending on which
+ // is available).
scoped_refptr<cc::Layer> layer_;
- scoped_refptr<ThumbnailLayer> static_layer_;
- bool content_attached_;
- bool static_attached_;
-
- cc::FilterOperations static_filter_operations_;
- cc::FilterOperations content_filter_operations_;
TabContentManager* tab_content_manager_;
« no previous file with comments | « no previous file | chrome/browser/android/compositor/layer/content_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698