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

Side by Side Diff: views/widget/native_widget_aura.cc

Issue 7976020: Wires up mouse capture code for aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Tweaks Created 9 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
« ui/aura/window.cc ('K') | « views/widget/native_widget_aura.h ('k') | no next file » | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "views/widget/native_widget_aura.h" 5 #include "views/widget/native_widget_aura.h"
6 6
7 #include "ui/aura/event.h" 7 #include "ui/aura/event.h"
8 #include "ui/aura/window.h" 8 #include "ui/aura/window.h"
9 #include "ui/gfx/canvas.h" 9 #include "ui/gfx/canvas.h"
10 #include "ui/gfx/compositor/layer.h" 10 #include "ui/gfx/compositor/layer.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 return false; 142 return false;
143 } 143 }
144 144
145 void NativeWidgetAura::SendNativeAccessibilityEvent( 145 void NativeWidgetAura::SendNativeAccessibilityEvent(
146 View* view, 146 View* view,
147 ui::AccessibilityTypes::Event event_type) { 147 ui::AccessibilityTypes::Event event_type) {
148 NOTIMPLEMENTED(); 148 NOTIMPLEMENTED();
149 } 149 }
150 150
151 void NativeWidgetAura::SetMouseCapture() { 151 void NativeWidgetAura::SetMouseCapture() {
152 NOTIMPLEMENTED(); 152 window_->SetCapture();
153 } 153 }
154 154
155 void NativeWidgetAura::ReleaseMouseCapture() { 155 void NativeWidgetAura::ReleaseMouseCapture() {
156 NOTIMPLEMENTED(); 156 window_->ReleaseCapture();
157 } 157 }
158 158
159 bool NativeWidgetAura::HasMouseCapture() const { 159 bool NativeWidgetAura::HasMouseCapture() const {
160 //NOTIMPLEMENTED(); 160 return window_->HasCapture();
161 return false;
162 } 161 }
163 162
164 InputMethod* NativeWidgetAura::CreateInputMethod() { 163 InputMethod* NativeWidgetAura::CreateInputMethod() {
165 NOTIMPLEMENTED(); 164 NOTIMPLEMENTED();
166 return NULL; 165 return NULL;
167 } 166 }
168 167
169 void NativeWidgetAura::CenterWindow(const gfx::Size& size) { 168 void NativeWidgetAura::CenterWindow(const gfx::Size& size) {
170 NOTIMPLEMENTED(); 169 NOTIMPLEMENTED();
171 } 170 }
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
404 } 403 }
405 404
406 int NativeWidgetAura::GetNonClientComponent(const gfx::Point& point) const { 405 int NativeWidgetAura::GetNonClientComponent(const gfx::Point& point) const {
407 return delegate_->GetNonClientComponent(point); 406 return delegate_->GetNonClientComponent(point);
408 } 407 }
409 408
410 bool NativeWidgetAura::OnMouseEvent(aura::MouseEvent* event) { 409 bool NativeWidgetAura::OnMouseEvent(aura::MouseEvent* event) {
411 return delegate_->OnMouseEvent(MouseEvent(event)); 410 return delegate_->OnMouseEvent(MouseEvent(event));
412 } 411 }
413 412
413 void NativeWidgetAura::OnCaptureGained() {
414 }
415
416 void NativeWidgetAura::OnCaptureLost() {
417 delegate_->OnMouseCaptureLost();
418 }
419
414 void NativeWidgetAura::OnPaint(gfx::Canvas* canvas) { 420 void NativeWidgetAura::OnPaint(gfx::Canvas* canvas) {
415 delegate_->OnNativeWidgetPaint(canvas); 421 delegate_->OnNativeWidgetPaint(canvas);
416 } 422 }
417 423
418 void NativeWidgetAura::OnWindowDestroying() { 424 void NativeWidgetAura::OnWindowDestroying() {
419 delegate_->OnNativeWidgetDestroying(); 425 delegate_->OnNativeWidgetDestroying();
420 } 426 }
421 427
422 void NativeWidgetAura::OnWindowDestroyed() { 428 void NativeWidgetAura::OnWindowDestroyed() {
423 window_ = NULL; 429 window_ = NULL;
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
497 } 503 }
498 504
499 // static 505 // static
500 bool NativeWidgetPrivate::IsMouseButtonDown() { 506 bool NativeWidgetPrivate::IsMouseButtonDown() {
501 NOTIMPLEMENTED(); 507 NOTIMPLEMENTED();
502 return false; 508 return false;
503 } 509 }
504 510
505 } // namespace internal 511 } // namespace internal
506 } // namespace views 512 } // namespace views
OLDNEW
« ui/aura/window.cc ('K') | « views/widget/native_widget_aura.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698