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

Side by Side Diff: ash/utility/screenshot_controller.cc

Issue 2237433002: ash: Use stl utilities from the base namespace (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 4 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
« no previous file with comments | « ash/test/test_session_state_delegate.cc ('k') | ash/wm/screen_pinning_controller.cc » ('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 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 "ash/utility/screenshot_controller.h" 5 #include "ash/utility/screenshot_controller.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 8
9 #include "ash/common/shell_window_ids.h" 9 #include "ash/common/shell_window_ids.h"
10 #include "ash/display/mouse_cursor_event_filter.h" 10 #include "ash/display/mouse_cursor_event_filter.h"
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 } 329 }
330 Cancel(); 330 Cancel();
331 } 331 }
332 332
333 void ScreenshotController::Cancel() { 333 void ScreenshotController::Cancel() {
334 mode_ = NONE; 334 mode_ = NONE;
335 root_window_ = nullptr; 335 root_window_ = nullptr;
336 SetSelectedWindow(nullptr); 336 SetSelectedWindow(nullptr);
337 screenshot_delegate_ = nullptr; 337 screenshot_delegate_ = nullptr;
338 display::Screen::GetScreen()->RemoveObserver(this); 338 display::Screen::GetScreen()->RemoveObserver(this);
339 STLDeleteValues(&layers_); 339 base::STLDeleteValues(&layers_);
340 cursor_setter_.reset(); 340 cursor_setter_.reset();
341 EnableMouseWarp(true); 341 EnableMouseWarp(true);
342 } 342 }
343 343
344 void ScreenshotController::Update(const ui::LocatedEvent& event) { 344 void ScreenshotController::Update(const ui::LocatedEvent& event) {
345 // Update may happen without MaybeStart() if the partial screenshot session 345 // Update may happen without MaybeStart() if the partial screenshot session
346 // starts when dragging. 346 // starts when dragging.
347 if (!root_window_) 347 if (!root_window_)
348 MaybeStart(event); 348 MaybeStart(event);
349 DCHECK(layers_.find(root_window_) != layers_.end()); 349 DCHECK(layers_.find(root_window_) != layers_.end());
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
503 503
504 void ScreenshotController::OnDisplayMetricsChanged( 504 void ScreenshotController::OnDisplayMetricsChanged(
505 const display::Display& display, 505 const display::Display& display,
506 uint32_t changed_metrics) {} 506 uint32_t changed_metrics) {}
507 507
508 void ScreenshotController::OnWindowDestroying(aura::Window* window) { 508 void ScreenshotController::OnWindowDestroying(aura::Window* window) {
509 SetSelectedWindow(nullptr); 509 SetSelectedWindow(nullptr);
510 } 510 }
511 511
512 } // namespace ash 512 } // namespace ash
OLDNEW
« no previous file with comments | « ash/test/test_session_state_delegate.cc ('k') | ash/wm/screen_pinning_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698