| OLD | NEW |
| 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 "content/browser/renderer_host/render_widget_host_view_aura.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "content/browser/renderer_host/backing_store_skia.h" | 8 #include "content/browser/renderer_host/backing_store_skia.h" |
| 9 #include "content/browser/renderer_host/web_input_event_aura.h" | 9 #include "content/browser/renderer_host/web_input_event_aura.h" |
| 10 #include "content/browser/renderer_host/render_widget_host.h" | 10 #include "content/browser/renderer_host/render_widget_host.h" |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 void RenderWidgetHostViewAura::SetBounds(const gfx::Rect& rect) { | 88 void RenderWidgetHostViewAura::SetBounds(const gfx::Rect& rect) { |
| 89 window_->SetBounds(rect); | 89 window_->SetBounds(rect); |
| 90 host_->WasResized(); | 90 host_->WasResized(); |
| 91 } | 91 } |
| 92 | 92 |
| 93 gfx::NativeView RenderWidgetHostViewAura::GetNativeView() const { | 93 gfx::NativeView RenderWidgetHostViewAura::GetNativeView() const { |
| 94 return window_; | 94 return window_; |
| 95 } | 95 } |
| 96 | 96 |
| 97 gfx::NativeViewId RenderWidgetHostViewAura::GetNativeViewId() const { | 97 gfx::NativeViewId RenderWidgetHostViewAura::GetNativeViewId() const { |
| 98 return NULL; | 98 return static_cast<gfx::NativeViewId>(NULL); |
| 99 } | 99 } |
| 100 | 100 |
| 101 void RenderWidgetHostViewAura::MovePluginWindows( | 101 void RenderWidgetHostViewAura::MovePluginWindows( |
| 102 const std::vector<webkit::npapi::WebPluginGeometry>& moves) { | 102 const std::vector<webkit::npapi::WebPluginGeometry>& moves) { |
| 103 // We don't support windowed plugins. | 103 // We don't support windowed plugins. |
| 104 } | 104 } |
| 105 | 105 |
| 106 void RenderWidgetHostViewAura::Focus() { | 106 void RenderWidgetHostViewAura::Focus() { |
| 107 window_->Focus(); | 107 window_->Focus(); |
| 108 } | 108 } |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 | 332 |
| 333 bool RenderWidgetHostViewAura::OnKeyEvent(aura::KeyEvent* event) { | 333 bool RenderWidgetHostViewAura::OnKeyEvent(aura::KeyEvent* event) { |
| 334 NativeWebKeyboardEvent webkit_event(event); | 334 NativeWebKeyboardEvent webkit_event(event); |
| 335 host_->ForwardKeyboardEvent(webkit_event); | 335 host_->ForwardKeyboardEvent(webkit_event); |
| 336 return true; | 336 return true; |
| 337 } | 337 } |
| 338 | 338 |
| 339 gfx::NativeCursor RenderWidgetHostViewAura::GetCursor(const gfx::Point& point) { | 339 gfx::NativeCursor RenderWidgetHostViewAura::GetCursor(const gfx::Point& point) { |
| 340 // TODO(beng): talk to beng before implementing this. | 340 // TODO(beng): talk to beng before implementing this. |
| 341 //NOTIMPLEMENTED(); | 341 //NOTIMPLEMENTED(); |
| 342 return NULL; | 342 return gfx::kNullCursor; |
| 343 } | 343 } |
| 344 | 344 |
| 345 int RenderWidgetHostViewAura::GetNonClientComponent( | 345 int RenderWidgetHostViewAura::GetNonClientComponent( |
| 346 const gfx::Point& point) const { | 346 const gfx::Point& point) const { |
| 347 return HTCLIENT; | 347 return HTCLIENT; |
| 348 } | 348 } |
| 349 | 349 |
| 350 bool RenderWidgetHostViewAura::OnMouseEvent(aura::MouseEvent* event) { | 350 bool RenderWidgetHostViewAura::OnMouseEvent(aura::MouseEvent* event) { |
| 351 if (event->type() == ui::ET_MOUSEWHEEL) | 351 if (event->type() == ui::ET_MOUSEWHEEL) |
| 352 host_->ForwardWheelEvent(content::MakeWebMouseWheelEvent(event)); | 352 host_->ForwardWheelEvent(content::MakeWebMouseWheelEvent(event)); |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 418 | 418 |
| 419 #if !defined(TOUCH_UI) | 419 #if !defined(TOUCH_UI) |
| 420 //////////////////////////////////////////////////////////////////////////////// | 420 //////////////////////////////////////////////////////////////////////////////// |
| 421 // RenderWidgetHostViewAura, private: | 421 // RenderWidgetHostViewAura, private: |
| 422 | 422 |
| 423 void RenderWidgetHostViewAura::UpdateCursorIfOverSelf() { | 423 void RenderWidgetHostViewAura::UpdateCursorIfOverSelf() { |
| 424 //NOTIMPLEMENTED(); | 424 //NOTIMPLEMENTED(); |
| 425 // TODO(beng): See RenderWidgetHostViewWin. | 425 // TODO(beng): See RenderWidgetHostViewWin. |
| 426 } | 426 } |
| 427 #endif | 427 #endif |
| OLD | NEW |