Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Side by Side Diff: ui/android/resources/resource_manager_impl.h

Issue 1144333004: Make WebView work for external displays (over Presentations). Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Minor fixes according to boliu/jdduke's comments Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_RESOURCES_RESOURCE_MANAGER_IMPL_H_ 5 #ifndef UI_ANDROID_RESOURCES_RESOURCE_MANAGER_IMPL_H_
6 #define UI_ANDROID_RESOURCES_RESOURCE_MANAGER_IMPL_H_ 6 #define UI_ANDROID_RESOURCES_RESOURCE_MANAGER_IMPL_H_
7 7
8 #include "base/id_map.h" 8 #include "base/id_map.h"
9 #include "ui/android/resources/resource_manager.h" 9 #include "ui/android/resources/resource_manager.h"
10 #include "ui/android/ui_android_export.h" 10 #include "ui/android/ui_android_export.h"
11 #include "ui/gfx/geometry/rect.h" 11 #include "ui/gfx/geometry/rect.h"
12 12
13 namespace ui { 13 namespace ui {
14 14
15 class UI_ANDROID_EXPORT ResourceManagerImpl : public ResourceManager { 15 class UI_ANDROID_EXPORT ResourceManagerImpl : public ResourceManager {
16 public: 16 public:
17 static ResourceManagerImpl* FromJavaObject(jobject jobj); 17 static ResourceManagerImpl* FromJavaObject(jobject jobj);
18 18
19 explicit ResourceManagerImpl(ui::UIResourceProvider* ui_resource_provider); 19 ResourceManagerImpl(ui::UIResourceProvider* ui_resource_provider,
20 jobject context);
20 ~ResourceManagerImpl() override; 21 ~ResourceManagerImpl() override;
21 22
22 // ResourceManager implementation. 23 // ResourceManager implementation.
23 base::android::ScopedJavaLocalRef<jobject> GetJavaObject() override; 24 base::android::ScopedJavaLocalRef<jobject> GetJavaObject() override;
24 Resource* GetResource(AndroidResourceType res_type, int res_id) override; 25 Resource* GetResource(AndroidResourceType res_type, int res_id) override;
25 void PreloadResource(AndroidResourceType res_type, int res_id) override; 26 void PreloadResource(AndroidResourceType res_type, int res_id) override;
26 27
27 // Called from Java 28 // Called from Java
28 // ---------------------------------------------------------- 29 // ----------------------------------------------------------
29 void OnResourceReady(JNIEnv* env, 30 void OnResourceReady(JNIEnv* env,
(...skipping 27 matching lines...) Expand all
57 ResourceMap resources_[ANDROID_RESOURCE_TYPE_COUNT]; 58 ResourceMap resources_[ANDROID_RESOURCE_TYPE_COUNT];
58 59
59 base::android::ScopedJavaGlobalRef<jobject> java_obj_; 60 base::android::ScopedJavaGlobalRef<jobject> java_obj_;
60 61
61 DISALLOW_COPY_AND_ASSIGN(ResourceManagerImpl); 62 DISALLOW_COPY_AND_ASSIGN(ResourceManagerImpl);
62 }; 63 };
63 64
64 } // namespace ui 65 } // namespace ui
65 66
66 #endif // UI_ANDROID_RESOURCES_RESOURCE_MANAGER_IMPL_H_ 67 #endif // UI_ANDROID_RESOURCES_RESOURCE_MANAGER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698