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

Unified Diff: include/views/SkOSWindow_Android.h

Issue 2099693002: Revert of Remove Android SampleApp (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 6 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 | « gyp/tools.gyp ('k') | include/views/SkWindow.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/views/SkOSWindow_Android.h
diff --git a/include/views/SkOSWindow_Android.h b/include/views/SkOSWindow_Android.h
new file mode 100644
index 0000000000000000000000000000000000000000..234e65c256093ca86a2df1c63a164f659e6893f7
--- /dev/null
+++ b/include/views/SkOSWindow_Android.h
@@ -0,0 +1,53 @@
+/*
+ * Copyright 2011 Skia
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#ifndef SkOSWindow_Android_DEFINED
+#define SkOSWindow_Android_DEFINED
+
+#include "SkWindow.h"
+
+#include <EGL/egl.h>
+
+struct SkAndroidWindow {
+ EGLDisplay fDisplay;
+ EGLSurface fSurface;
+ EGLContext fContext;
+};
+
+class SkOSWindow : public SkWindow {
+public:
+ SkOSWindow(void*);
+ ~SkOSWindow();
+
+ enum SkBackEndTypes {
+ kNone_BackEndType,
+ kNativeGL_BackEndType,
+ };
+
+ bool attach(SkBackEndTypes attachType, int msaaSampleCount, bool deepColor,
+ AttachmentInfo* info);
+ void release();
+ void present();
+ bool makeFullscreen() { return true; }
+ void closeWindow();
+ void setVsync(bool);
+ bool destroyRequested() { return fDestroyRequested; }
+
+protected:
+ // overrides from SkWindow
+ virtual void onHandleInval(const SkIRect&);
+ virtual void onSetTitle(const char title[]);
+
+private:
+ SkAndroidWindow fWindow;
+ ANativeWindow* fNativeWindow;
+ bool fDestroyRequested;
+
+ typedef SkWindow INHERITED;
+};
+
+#endif
« no previous file with comments | « gyp/tools.gyp ('k') | include/views/SkWindow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698