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

Unified Diff: ash/common/wm/forwarding_layer_delegate.h

Issue 2383263002: Generalize layer mirroring for phantom windows (Closed)
Patch Set: Rebase Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/aura/wm_window_aura.cc ('k') | ash/common/wm/forwarding_layer_delegate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/wm/forwarding_layer_delegate.h
diff --git a/ash/common/wm/forwarding_layer_delegate.h b/ash/common/wm/forwarding_layer_delegate.h
deleted file mode 100644
index 7c68f185a10d658c7b92e6e7f58c15bc8fcb7d9c..0000000000000000000000000000000000000000
--- a/ash/common/wm/forwarding_layer_delegate.h
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef ASH_COMMON_WM_FORWARDING_LAYER_DELEGATE_H_
-#define ASH_COMMON_WM_FORWARDING_LAYER_DELEGATE_H_
-
-#include "base/macros.h"
-#include "base/scoped_observer.h"
-#include "ui/compositor/layer_delegate.h"
-#include "ui/compositor/layer_observer.h"
-
-namespace ui {
-class Layer;
-}
-
-namespace ash {
-
-class WmWindow;
-
-namespace wm {
-
-// A layer delegate to paint the content of a recreated layer by delegating
-// the paint request to the original delegate. It is a delegate of the recreated
-// layer and an observer of the original layer.
-class ForwardingLayerDelegate : public ui::LayerDelegate,
- public ui::LayerObserver {
- public:
- ForwardingLayerDelegate(ui::Layer* new_layer, ui::Layer* original_layer);
- ~ForwardingLayerDelegate() override;
-
- // ui:LayerDelegate:
- void OnPaintLayer(const ui::PaintContext& context) override;
- void OnDelegatedFrameDamage(const gfx::Rect& damage_rect_in_dip) override;
- void OnDeviceScaleFactorChanged(float device_scale_factor) override;
-
- // ui::LayerObserver:
- void DidPaintLayer(ui::Layer* layer, const gfx::Rect& rect) override;
- void SurfaceChanged(ui::Layer* layer) override;
- void LayerDestroyed(ui::Layer* layer) override;
-
- private:
- // The layer for which |this| is the delegate.
- ui::Layer* client_layer_;
-
- // The layer that was recreated to replace |new_layer_|.
- ui::Layer* original_layer_;
-
- ScopedObserver<ui::Layer, ui::LayerObserver> scoped_observer_;
-
- DISALLOW_COPY_AND_ASSIGN(ForwardingLayerDelegate);
-};
-
-} // namespace wm
-} // namespace ash
-
-#endif // ASH_COMMON_WM_FORWARDING_LAYER_DELEGATE_H_
« no previous file with comments | « ash/aura/wm_window_aura.cc ('k') | ash/common/wm/forwarding_layer_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698