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

Unified Diff: components/exo/surface_delegate.h

Issue 1412093006: components: Add Exosphere component. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove some ifdefs Created 5 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 | « components/exo/surface.cc ('k') | components/exo/surface_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/exo/surface_delegate.h
diff --git a/components/exo/surface_delegate.h b/components/exo/surface_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..bfda475fc5b18f78c361cf276b499cd8b1088b08
--- /dev/null
+++ b/components/exo/surface_delegate.h
@@ -0,0 +1,26 @@
+// Copyright 2015 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 COMPONENTS_EXO_SURFACE_DELEGATE_H_
+#define COMPONENTS_EXO_SURFACE_DELEGATE_H_
+
+namespace exo {
+
+// Handles events on surfaces in context-specific ways.
+class SurfaceDelegate {
+ public:
+ // Called when the surface is destroyed. The delegate can use this
+ // opportunity to delete itself if necessary.
+ virtual void OnSurfaceDestroying() = 0;
+
+ // Called when surface was requested to commit all double-buffered state.
+ virtual void OnSurfaceCommit() = 0;
+
+ protected:
+ virtual ~SurfaceDelegate() {}
+};
+
+} // namespace exo
+
+#endif // COMPONENTS_EXO_SURFACE_DELEGATE_H_
« no previous file with comments | « components/exo/surface.cc ('k') | components/exo/surface_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698