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

Side by Side Diff: trunk/src/ui/ozone/demo/egl_demo.cc

Issue 410873003: Revert 284850 "aura: Use PlatformWindow from WindowTreeHostWin." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/at_exit.h" 5 #include "base/at_exit.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/message_loop/message_loop.h" 7 #include "base/message_loop/message_loop.h"
8 #include "ui/gfx/geometry/size.h" 8 #include "ui/gfx/geometry/size.h"
9 #include "ui/gl/gl_bindings.h" 9 #include "ui/gl/gl_bindings.h"
10 #include "ui/gl/gl_context.h" 10 #include "ui/gl/gl_context.h"
(...skipping 30 matching lines...) Expand all
41 virtual void OnCloseRequest() OVERRIDE {} 41 virtual void OnCloseRequest() OVERRIDE {}
42 virtual void OnClosed() OVERRIDE {} 42 virtual void OnClosed() OVERRIDE {}
43 virtual void OnWindowStateChanged( 43 virtual void OnWindowStateChanged(
44 ui::PlatformWindowState new_state) OVERRIDE {} 44 ui::PlatformWindowState new_state) OVERRIDE {}
45 virtual void OnLostCapture() OVERRIDE {} 45 virtual void OnLostCapture() OVERRIDE {}
46 virtual void OnAcceleratedWidgetAvailable( 46 virtual void OnAcceleratedWidgetAvailable(
47 gfx::AcceleratedWidget widget) OVERRIDE { 47 gfx::AcceleratedWidget widget) OVERRIDE {
48 CHECK_NE(widget, gfx::kNullAcceleratedWidget); 48 CHECK_NE(widget, gfx::kNullAcceleratedWidget);
49 widget_ = widget; 49 widget_ = widget;
50 } 50 }
51 virtual void OnActivationChanged(bool active) OVERRIDE {}
52 51
53 private: 52 private:
54 scoped_ptr<ui::PlatformWindow> platform_window_; 53 scoped_ptr<ui::PlatformWindow> platform_window_;
55 gfx::AcceleratedWidget widget_; 54 gfx::AcceleratedWidget widget_;
56 55
57 DISALLOW_COPY_AND_ASSIGN(DemoWindow); 56 DISALLOW_COPY_AND_ASSIGN(DemoWindow);
58 }; 57 };
59 58
60 int main(int argc, char** argv) { 59 int main(int argc, char** argv) {
61 CommandLine::Init(argc, argv); 60 CommandLine::Init(argc, argv);
(...skipping 30 matching lines...) Expand all
92 glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); 91 glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
93 float fraction = static_cast<float>(i) / iterations; 92 float fraction = static_cast<float>(i) / iterations;
94 glClearColor(1 - fraction, fraction, 0.0, 1.0); 93 glClearColor(1 - fraction, fraction, 0.0, 1.0);
95 94
96 if (!surface->SwapBuffers()) 95 if (!surface->SwapBuffers())
97 LOG(FATAL) << "Failed to swap buffers"; 96 LOG(FATAL) << "Failed to swap buffers";
98 } 97 }
99 98
100 return 0; 99 return 0;
101 } 100 }
OLDNEW
« no previous file with comments | « trunk/src/ui/aura/window_tree_host_win.cc ('k') | trunk/src/ui/platform_window/platform_window_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698