OLD | NEW |
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 #ifndef CONTENT_BROWSER_TAB_CONTENTS_TAB_CONTENTS_VIEW_WIN_H_ | 5 #ifndef CONTENT_BROWSER_TAB_CONTENTS_TAB_CONTENTS_VIEW_WIN_H_ |
6 #define CONTENT_BROWSER_TAB_CONTENTS_TAB_CONTENTS_VIEW_WIN_H_ | 6 #define CONTENT_BROWSER_TAB_CONTENTS_TAB_CONTENTS_VIEW_WIN_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "content/browser/tab_contents/tab_contents_view_helper.h" | 9 #include "content/browser/tab_contents/tab_contents_view_helper.h" |
10 #include "content/public/browser/web_contents_view.h" | 10 #include "content/public/browser/web_contents_view.h" |
11 #include "ui/base/win/window_impl.h" | 11 #include "ui/base/win/window_impl.h" |
12 | 12 |
13 class RenderWidgetHostViewWin; | 13 class RenderWidgetHostViewWin; |
14 | 14 |
15 // An implementation of WebContentsView for Windows. | 15 // An implementation of WebContentsView for Windows. |
16 class TabContentsViewWin : public content::WebContentsView, | 16 class TabContentsViewWin : public content::WebContentsView, |
17 public ui::WindowImpl { | 17 public ui::WindowImpl { |
18 public: | 18 public: |
19 // TODO(jam): make this take a WebContents once it's created from content. | 19 // TODO(jam): make this take a TabContents once it's created from content. |
20 explicit TabContentsViewWin(content::WebContents* web_contents); | 20 explicit TabContentsViewWin(content::WebContents* web_contents); |
21 virtual ~TabContentsViewWin(); | 21 virtual ~TabContentsViewWin(); |
22 | 22 |
23 void SetParent(HWND parent); | 23 void SetParent(HWND parent); |
24 | 24 |
25 BEGIN_MSG_MAP_EX(TabContentsViewWin) | 25 BEGIN_MSG_MAP_EX(TabContentsViewWin) |
26 MESSAGE_HANDLER(WM_WINDOWPOSCHANGED, OnWindowPosChanged) | 26 MESSAGE_HANDLER(WM_WINDOWPOSCHANGED, OnWindowPosChanged) |
27 END_MSG_MAP() | 27 END_MSG_MAP() |
28 | 28 |
29 // Overridden from WebContentsView: | 29 // Overridden from WebContentsView: |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 | 96 |
97 RenderWidgetHostViewWin* view_; | 97 RenderWidgetHostViewWin* view_; |
98 | 98 |
99 // Common implementations of some WebContentsView methods. | 99 // Common implementations of some WebContentsView methods. |
100 TabContentsViewHelper tab_contents_view_helper_; | 100 TabContentsViewHelper tab_contents_view_helper_; |
101 | 101 |
102 DISALLOW_COPY_AND_ASSIGN(TabContentsViewWin); | 102 DISALLOW_COPY_AND_ASSIGN(TabContentsViewWin); |
103 }; | 103 }; |
104 | 104 |
105 #endif // CONTENT_BROWSER_TAB_CONTENTS_TAB_CONTENTS_VIEW_WIN_H_ | 105 #endif // CONTENT_BROWSER_TAB_CONTENTS_TAB_CONTENTS_VIEW_WIN_H_ |
OLD | NEW |