OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 UI_ANDROID_VIEW_ANDROID_H_ | 5 #ifndef UI_ANDROID_VIEW_ANDROID_H_ |
6 #define UI_ANDROID_VIEW_ANDROID_H_ | 6 #define UI_ANDROID_VIEW_ANDROID_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 | 9 |
10 #include "base/android/scoped_java_ref.h" | 10 #include "base/android/scoped_java_ref.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 const base::android::JavaRef<jobject>& GetViewAndroidDelegate() const; | 46 const base::android::JavaRef<jobject>& GetViewAndroidDelegate() const; |
47 | 47 |
48 // Used to return and set the layer for this view. May be |null|. | 48 // Used to return and set the layer for this view. May be |null|. |
49 cc::Layer* GetLayer() const; | 49 cc::Layer* GetLayer() const; |
50 void SetLayer(scoped_refptr<cc::Layer> layer); | 50 void SetLayer(scoped_refptr<cc::Layer> layer); |
51 | 51 |
52 // Add/remove this view as a child of another view. | 52 // Add/remove this view as a child of another view. |
53 void AddChild(ViewAndroid* child); | 53 void AddChild(ViewAndroid* child); |
54 void RemoveChild(ViewAndroid* child); | 54 void RemoveChild(ViewAndroid* child); |
55 | 55 |
| 56 void StartDragAndDrop(const base::android::JavaRef<jstring>& jtext, |
| 57 const base::android::JavaRef<jobject>& jimage); |
| 58 |
56 private: | 59 private: |
57 ViewAndroid* parent_; | 60 ViewAndroid* parent_; |
58 std::list<ViewAndroid*> children_; | 61 std::list<ViewAndroid*> children_; |
59 WindowAndroid* window_; | 62 WindowAndroid* window_; |
60 scoped_refptr<cc::Layer> layer_; | 63 scoped_refptr<cc::Layer> layer_; |
61 base::android::ScopedJavaGlobalRef<jobject> delegate_; | 64 base::android::ScopedJavaGlobalRef<jobject> delegate_; |
62 | 65 |
63 DISALLOW_COPY_AND_ASSIGN(ViewAndroid); | 66 DISALLOW_COPY_AND_ASSIGN(ViewAndroid); |
64 }; | 67 }; |
65 | 68 |
66 } // namespace ui | 69 } // namespace ui |
67 | 70 |
68 #endif // UI_ANDROID_VIEW_ANDROID_H_ | 71 #endif // UI_ANDROID_VIEW_ANDROID_H_ |
OLD | NEW |