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

Side by Side Diff: ui/compositor/compositor.cc

Issue 11475017: Revert 171569 as it broke some browser_tests on win_aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years 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
« no previous file with comments | « ui/compositor/compositor.h ('k') | ui/gfx/native_widget_types.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ui/compositor/compositor.h" 5 #include "ui/compositor/compositor.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <deque> 8 #include <deque>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 context->makeContextCurrent(); 185 context->makeContextCurrent();
186 gfx::GLContext* gl_context = gfx::GLContext::GetCurrent(); 186 gfx::GLContext* gl_context = gfx::GLContext::GetCurrent();
187 bool vsync = !command_line->HasSwitch(switches::kDisableGpuVsync); 187 bool vsync = !command_line->HasSwitch(switches::kDisableGpuVsync);
188 gl_context->SetSwapInterval(vsync ? 1 : 0); 188 gl_context->SetSwapInterval(vsync ? 1 : 0);
189 gl_context->ReleaseCurrent(NULL); 189 gl_context->ReleaseCurrent(NULL);
190 } 190 }
191 return context; 191 return context;
192 } 192 }
193 193
194 Texture::Texture(bool flipped, const gfx::Size& size, float device_scale_factor) 194 Texture::Texture(bool flipped, const gfx::Size& size, float device_scale_factor)
195 : size_(size), 195 : flipped_(flipped),
196 flipped_(flipped), 196 size_(size),
197 device_scale_factor_(device_scale_factor) { 197 device_scale_factor_(device_scale_factor) {
198 } 198 }
199 199
200 Texture::~Texture() { 200 Texture::~Texture() {
201 } 201 }
202 202
203 CompositorLock::CompositorLock(Compositor* compositor) 203 CompositorLock::CompositorLock(Compositor* compositor)
204 : compositor_(compositor) { 204 : compositor_(compositor) {
205 MessageLoop::current()->PostDelayedTask( 205 MessageLoop::current()->PostDelayedTask(
206 FROM_HERE, 206 FROM_HERE,
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 597
598 COMPOSITOR_EXPORT void DisableTestCompositor() { 598 COMPOSITOR_EXPORT void DisableTestCompositor() {
599 test_compositor_enabled = false; 599 test_compositor_enabled = false;
600 } 600 }
601 601
602 COMPOSITOR_EXPORT bool IsTestCompositorEnabled() { 602 COMPOSITOR_EXPORT bool IsTestCompositorEnabled() {
603 return test_compositor_enabled; 603 return test_compositor_enabled;
604 } 604 }
605 605
606 } // namespace ui 606 } // namespace ui
OLDNEW
« no previous file with comments | « ui/compositor/compositor.h ('k') | ui/gfx/native_widget_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698