| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 VIEWS_WIDGET_WIDGET_WIN_H_ | 5 #ifndef VIEWS_WIDGET_WIDGET_WIN_H_ |
| 6 #define VIEWS_WIDGET_WIDGET_WIN_H_ | 6 #define VIEWS_WIDGET_WIDGET_WIN_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <atlbase.h> | 9 #include <atlbase.h> |
| 10 #include <atlapp.h> | 10 #include <atlapp.h> |
| 11 #include <atlcrack.h> | 11 #include <atlcrack.h> |
| 12 #include <atlmisc.h> | 12 #include <atlmisc.h> |
| 13 | 13 |
| 14 #include <string> | 14 #include <string> |
| 15 #include <vector> | 15 #include <vector> |
| 16 | 16 |
| 17 #include "app/win/window_impl.h" | |
| 18 #include "base/message_loop.h" | 17 #include "base/message_loop.h" |
| 19 #include "base/scoped_vector.h" | 18 #include "base/scoped_vector.h" |
| 20 #include "base/win/scoped_comptr.h" | 19 #include "base/win/scoped_comptr.h" |
| 20 #include "ui/base/win/window_impl.h" |
| 21 #include "views/focus/focus_manager.h" | 21 #include "views/focus/focus_manager.h" |
| 22 #include "views/layout_manager.h" | 22 #include "views/layout_manager.h" |
| 23 #include "views/widget/widget.h" | 23 #include "views/widget/widget.h" |
| 24 | 24 |
| 25 namespace app { | 25 namespace app { |
| 26 class ViewProp; | 26 class ViewProp; |
| 27 } | 27 } |
| 28 | 28 |
| 29 namespace gfx { | 29 namespace gfx { |
| 30 class CanvasSkia; | 30 class CanvasSkia; |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 // A Widget for a views hierarchy used to represent anything that can be | 67 // A Widget for a views hierarchy used to represent anything that can be |
| 68 // contained within an HWND, e.g. a control, a window, etc. Specializations | 68 // contained within an HWND, e.g. a control, a window, etc. Specializations |
| 69 // suitable for specific tasks, e.g. top level window, are derived from this. | 69 // suitable for specific tasks, e.g. top level window, are derived from this. |
| 70 // | 70 // |
| 71 // This Widget contains a RootView which owns the hierarchy of views within it. | 71 // This Widget contains a RootView which owns the hierarchy of views within it. |
| 72 // As long as views are part of this tree, they will be deleted automatically | 72 // As long as views are part of this tree, they will be deleted automatically |
| 73 // when the RootView is destroyed. If you remove a view from the tree, you are | 73 // when the RootView is destroyed. If you remove a view from the tree, you are |
| 74 // then responsible for cleaning up after it. | 74 // then responsible for cleaning up after it. |
| 75 // | 75 // |
| 76 /////////////////////////////////////////////////////////////////////////////// | 76 /////////////////////////////////////////////////////////////////////////////// |
| 77 class WidgetWin : public app::win::WindowImpl, | 77 class WidgetWin : public ui::WindowImpl, |
| 78 public Widget, | 78 public Widget, |
| 79 public MessageLoopForUI::Observer, | 79 public MessageLoopForUI::Observer, |
| 80 public FocusTraversable { | 80 public FocusTraversable { |
| 81 public: | 81 public: |
| 82 WidgetWin(); | 82 WidgetWin(); |
| 83 virtual ~WidgetWin(); | 83 virtual ~WidgetWin(); |
| 84 | 84 |
| 85 // Returns the Widget associated with the specified HWND (if any). | 85 // Returns the Widget associated with the specified HWND (if any). |
| 86 static WidgetWin* GetWidget(HWND hwnd); | 86 static WidgetWin* GetWidget(HWND hwnd); |
| 87 | 87 |
| (...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 593 int accessibility_view_events_index_; | 593 int accessibility_view_events_index_; |
| 594 | 594 |
| 595 ViewProps props_; | 595 ViewProps props_; |
| 596 | 596 |
| 597 DISALLOW_COPY_AND_ASSIGN(WidgetWin); | 597 DISALLOW_COPY_AND_ASSIGN(WidgetWin); |
| 598 }; | 598 }; |
| 599 | 599 |
| 600 } // namespace views | 600 } // namespace views |
| 601 | 601 |
| 602 #endif // VIEWS_WIDGET_WIDGET_WIN_H_ | 602 #endif // VIEWS_WIDGET_WIDGET_WIN_H_ |
| OLD | NEW |