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

Side by Side Diff: ash/wm/gestures/two_finger_drag_handler.cc

Issue 14297013: Cleanup: Remove unnecessary ".get()" from scoped_ptrs<>. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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
« no previous file with comments | « ash/wm/gestures/shelf_gesture_handler.cc ('k') | ash/wm/image_cursors.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 (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 "ash/wm/gestures/two_finger_drag_handler.h" 5 #include "ash/wm/gestures/two_finger_drag_handler.h"
6 6
7 #include "ash/wm/window_resizer.h" 7 #include "ash/wm/window_resizer.h"
8 #include "ash/wm/window_util.h" 8 #include "ash/wm/window_util.h"
9 #include "ash/wm/workspace/snap_sizer.h" 9 #include "ash/wm/workspace/snap_sizer.h"
10 #include "ui/aura/client/window_types.h" 10 #include "ui/aura/client/window_types.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 target->AddObserver(this); 100 target->AddObserver(this);
101 window_resizer_ = CreateWindowResizer(target, 101 window_resizer_ = CreateWindowResizer(target,
102 event.details().bounding_box().CenterPoint(), HTCAPTION); 102 event.details().bounding_box().CenterPoint(), HTCAPTION);
103 return true; 103 return true;
104 } 104 }
105 } 105 }
106 106
107 return false; 107 return false;
108 } 108 }
109 109
110 if (!window_resizer_.get()) { 110 if (!window_resizer_) {
111 // Consume all two-finger gestures on a normal window. 111 // Consume all two-finger gestures on a normal window.
112 return event.details().touch_points() == 2 && 112 return event.details().touch_points() == 2 &&
113 target->type() == aura::client::WINDOW_TYPE_NORMAL && 113 target->type() == aura::client::WINDOW_TYPE_NORMAL &&
114 wm::IsWindowNormal(target); 114 wm::IsWindowNormal(target);
115 } 115 }
116 116
117 if (target != window_resizer_->GetTarget()) 117 if (target != window_resizer_->GetTarget())
118 return false; 118 return false;
119 119
120 switch (event.type()) { 120 switch (event.type()) {
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 bool visible) { 186 bool visible) {
187 Reset(); 187 Reset();
188 } 188 }
189 189
190 void TwoFingerDragHandler::OnWindowDestroying(aura::Window* window) { 190 void TwoFingerDragHandler::OnWindowDestroying(aura::Window* window) {
191 Reset(); 191 Reset();
192 } 192 }
193 193
194 } // namespace internal 194 } // namespace internal
195 } // namespace ash 195 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/gestures/shelf_gesture_handler.cc ('k') | ash/wm/image_cursors.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698