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

Side by Side Diff: ui/aura/root_window.cc

Issue 23882007: Explicit initialization of aura::Env for browser shell. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Removed unnecessary call Created 7 years, 3 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 (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/aura/root_window.h" 5 #include "ui/aura/root_window.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 gesture_recognizer_(ui::GestureRecognizer::Create(this)), 153 gesture_recognizer_(ui::GestureRecognizer::Create(this)),
154 synthesize_mouse_move_(false), 154 synthesize_mouse_move_(false),
155 waiting_on_compositing_end_(false), 155 waiting_on_compositing_end_(false),
156 draw_on_compositing_end_(false), 156 draw_on_compositing_end_(false),
157 defer_draw_scheduling_(false), 157 defer_draw_scheduling_(false),
158 move_hold_count_(0), 158 move_hold_count_(0),
159 held_event_factory_(this), 159 held_event_factory_(this),
160 repostable_event_factory_(this) { 160 repostable_event_factory_(this) {
161 SetName("RootWindow"); 161 SetName("RootWindow");
162 162
163 Env::CreateInstance();
dnicoara 2013/09/10 19:15:00 On OZONE builds this is needed since the minimal_s
Ben Goodger (Google) 2013/09/10 19:21:03 Why not? Not sure I like this.
dnicoara 2013/09/10 19:56:55 minimal_shell doesn't perform any aura calls, so i
163 compositor_.reset(new ui::Compositor(this, host_->GetAcceleratedWidget())); 164 compositor_.reset(new ui::Compositor(this, host_->GetAcceleratedWidget()));
164 DCHECK(compositor_.get()); 165 DCHECK(compositor_.get());
165 compositor_->AddObserver(this); 166 compositor_->AddObserver(this);
166 167
167 prop_.reset(new ui::ViewProp(host_->GetAcceleratedWidget(), 168 prop_.reset(new ui::ViewProp(host_->GetAcceleratedWidget(),
168 kRootWindowForAcceleratedWidget, 169 kRootWindowForAcceleratedWidget,
169 this)); 170 this));
170 } 171 }
171 172
172 RootWindow::~RootWindow() { 173 RootWindow::~RootWindow() {
(...skipping 1073 matching lines...) Expand 10 before | Expand all | Expand 10 after
1246 } 1247 }
1247 1248
1248 gfx::Transform RootWindow::GetInverseRootTransform() const { 1249 gfx::Transform RootWindow::GetInverseRootTransform() const {
1249 float scale = ui::GetDeviceScaleFactor(layer()); 1250 float scale = ui::GetDeviceScaleFactor(layer());
1250 gfx::Transform transform; 1251 gfx::Transform transform;
1251 transform.Scale(1.0f / scale, 1.0f / scale); 1252 transform.Scale(1.0f / scale, 1.0f / scale);
1252 return transformer_->GetInverseTransform() * transform; 1253 return transformer_->GetInverseTransform() * transform;
1253 } 1254 }
1254 1255
1255 } // namespace aura 1256 } // namespace aura
OLDNEW
« ui/aura/env.cc ('K') | « ui/aura/env.cc ('k') | ui/aura/test/aura_test_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698