| 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 #ifndef VIEWS_CONTROLS_NATIVE_CONTROL_H_ | 5 #ifndef VIEWS_CONTROLS_NATIVE_CONTROL_H_ |
| 6 #define VIEWS_CONTROLS_NATIVE_CONTROL_H_ | 6 #define VIEWS_CONTROLS_NATIVE_CONTROL_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <windows.h> | 9 #include <windows.h> |
| 10 | 10 |
| 11 #include "ui/base/keycodes/keyboard_codes.h" | 11 #include "ui/base/keycodes/keyboard_codes.h" |
| 12 #include "views/view.h" | 12 #include "views/view.h" |
| 13 | 13 |
| 14 namespace views { | 14 namespace views { |
| 15 | 15 |
| 16 class NativeViewHost; | 16 class NativeViewHost; |
| 17 class NativeControlContainer; | 17 class NativeControlContainer; |
| 18 | 18 |
| 19 //////////////////////////////////////////////////////////////////////////////// | 19 //////////////////////////////////////////////////////////////////////////////// |
| 20 // | 20 // |
| 21 // NativeControl is an abstract view that is used to implement views wrapping | 21 // NativeControl is an abstract view that is used to implement views wrapping |
| 22 // native controls. Subclasses can simply implement CreateNativeControl() to | 22 // native controls. Subclasses can simply implement CreateNativeControl() to |
| 23 // wrap a new kind of control | 23 // wrap a new kind of control |
| 24 // | 24 // |
| 25 //////////////////////////////////////////////////////////////////////////////// | 25 //////////////////////////////////////////////////////////////////////////////// |
| 26 class VIEWS_API NativeControl : public View { | 26 class VIEWS_EXPORT NativeControl : public View { |
| 27 public: | 27 public: |
| 28 enum Alignment { | 28 enum Alignment { |
| 29 LEADING = 0, | 29 LEADING = 0, |
| 30 CENTER, | 30 CENTER, |
| 31 TRAILING }; | 31 TRAILING }; |
| 32 | 32 |
| 33 NativeControl(); | 33 NativeControl(); |
| 34 virtual ~NativeControl(); | 34 virtual ~NativeControl(); |
| 35 | 35 |
| 36 virtual void ViewHierarchyChanged(bool is_add, View *parent, View *child); | 36 virtual void ViewHierarchyChanged(bool is_add, View *parent, View *child); |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 WPARAM w_param, LPARAM l_param); | 117 WPARAM w_param, LPARAM l_param); |
| 118 | 118 |
| 119 NativeControlContainer* container_; | 119 NativeControlContainer* container_; |
| 120 | 120 |
| 121 DISALLOW_COPY_AND_ASSIGN(NativeControl); | 121 DISALLOW_COPY_AND_ASSIGN(NativeControl); |
| 122 }; | 122 }; |
| 123 | 123 |
| 124 } // namespace views | 124 } // namespace views |
| 125 | 125 |
| 126 #endif // VIEWS_CONTROLS_NATIVE_CONTROL_H_ | 126 #endif // VIEWS_CONTROLS_NATIVE_CONTROL_H_ |
| OLD | NEW |