| 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 "chrome/browser/ui/views/notifications/balloon_view_host.h" | 5 #include "chrome/browser/ui/views/notifications/balloon_view_host.h" |
| 6 | 6 |
| 7 #include "chrome/browser/notifications/balloon.h" | 7 #include "chrome/browser/notifications/balloon.h" |
| 8 #include "content/browser/renderer_host/render_view_host.h" | 8 #include "content/browser/renderer_host/render_view_host.h" |
| 9 #include "content/browser/renderer_host/render_widget_host_view.h" | 9 #include "content/browser/renderer_host/render_widget_host_view.h" |
| 10 #include "content/browser/tab_contents/tab_contents.h" | 10 #include "content/browser/tab_contents/tab_contents.h" |
| 11 #include "content/public/browser/content_browser_client.h" | 11 #include "content/public/browser/content_browser_client.h" |
| 12 #include "ui/views/widget/widget.h" | 12 #include "views/widget/widget.h" |
| 13 | 13 |
| 14 #if defined(TOUCH_UI) && !defined(USE_AURA) | 14 #if defined(TOUCH_UI) && !defined(USE_AURA) |
| 15 #include "chrome/browser/renderer_host/render_widget_host_view_views.h" | 15 #include "chrome/browser/renderer_host/render_widget_host_view_views.h" |
| 16 #endif | 16 #endif |
| 17 | 17 |
| 18 class BalloonViewHostView : public views::NativeViewHost { | 18 class BalloonViewHostView : public views::NativeViewHost { |
| 19 public: | 19 public: |
| 20 explicit BalloonViewHostView(BalloonViewHost* host) | 20 explicit BalloonViewHostView(BalloonViewHost* host) |
| 21 : host_(host), | 21 : host_(host), |
| 22 initialized_(false) { | 22 initialized_(false) { |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 RenderWidgetHostView* render_widget_host_view = | 55 RenderWidgetHostView* render_widget_host_view = |
| 56 tab_contents_->render_view_host()->view(); | 56 tab_contents_->render_view_host()->view(); |
| 57 #if defined(TOUCH_UI) && !defined(USE_AURA) | 57 #if defined(TOUCH_UI) && !defined(USE_AURA) |
| 58 RenderWidgetHostViewViews* view_views = | 58 RenderWidgetHostViewViews* view_views = |
| 59 static_cast<RenderWidgetHostViewViews*>(render_widget_host_view); | 59 static_cast<RenderWidgetHostViewViews*>(render_widget_host_view); |
| 60 native_host_->AttachToView(view_views); | 60 native_host_->AttachToView(view_views); |
| 61 #else | 61 #else |
| 62 native_host_->Attach(render_widget_host_view->GetNativeView()); | 62 native_host_->Attach(render_widget_host_view->GetNativeView()); |
| 63 #endif | 63 #endif |
| 64 } | 64 } |
| OLD | NEW |