| OLD | NEW |
| 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_H_ | 5 #ifndef UI_ANDROID_RESOURCES_RESOURCE_MANAGER_H_ |
| 6 #define UI_ANDROID_RESOURCES_RESOURCE_MANAGER_H_ | 6 #define UI_ANDROID_RESOURCES_RESOURCE_MANAGER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <unordered_map> | 9 #include <unordered_map> |
| 10 #include <unordered_set> | 10 #include <unordered_set> |
| 11 | 11 |
| 12 #include "base/android/jni_android.h" | 12 #include "base/android/jni_android.h" |
| 13 #include "cc/resources/scoped_ui_resource.h" | 13 #include "cc/resources/scoped_ui_resource.h" |
| 14 #include "third_party/skia/include/core/SkColor.h" | 14 #include "third_party/skia/include/core/SkColor.h" |
| 15 #include "ui/android/resources/crushed_sprite_resource.h" | 15 #include "ui/android/resources/crushed_sprite_resource.h" |
| 16 #include "ui/android/ui_android_export.h" | 16 #include "ui/android/ui_android_export.h" |
| 17 #include "ui/gfx/geometry/insets_f.h" | 17 #include "ui/gfx/geometry/insets_f.h" |
| 18 #include "ui/gfx/geometry/rect.h" | 18 #include "ui/gfx/geometry/rect.h" |
| 19 #include "ui/gfx/geometry/size.h" | 19 #include "ui/gfx/geometry/size.h" |
| 20 | 20 |
| 21 namespace ui { | 21 namespace ui { |
| 22 | 22 |
| 23 class UIResourceProvider; | |
| 24 | |
| 25 // A Java counterpart will be generated for this enum. | 23 // A Java counterpart will be generated for this enum. |
| 26 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.ui.resources | 24 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.ui.resources |
| 27 enum AndroidResourceType { | 25 enum AndroidResourceType { |
| 28 ANDROID_RESOURCE_TYPE_STATIC = 0, | 26 ANDROID_RESOURCE_TYPE_STATIC = 0, |
| 29 ANDROID_RESOURCE_TYPE_DYNAMIC, | 27 ANDROID_RESOURCE_TYPE_DYNAMIC, |
| 30 ANDROID_RESOURCE_TYPE_DYNAMIC_BITMAP, | 28 ANDROID_RESOURCE_TYPE_DYNAMIC_BITMAP, |
| 31 ANDROID_RESOURCE_TYPE_SYSTEM, | 29 ANDROID_RESOURCE_TYPE_SYSTEM, |
| 32 ANDROID_RESOURCE_TYPE_CRUSHED_SPRITE, | 30 ANDROID_RESOURCE_TYPE_CRUSHED_SPRITE, |
| 33 | 31 |
| 34 ANDROID_RESOURCE_TYPE_COUNT, | 32 ANDROID_RESOURCE_TYPE_COUNT, |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 return resource && resource->ui_resource ? resource->ui_resource->id() : 0; | 89 return resource && resource->ui_resource ? resource->ui_resource->id() : 0; |
| 92 } | 90 } |
| 93 | 91 |
| 94 protected: | 92 protected: |
| 95 virtual ~ResourceManager() {} | 93 virtual ~ResourceManager() {} |
| 96 }; | 94 }; |
| 97 | 95 |
| 98 } // namespace ui | 96 } // namespace ui |
| 99 | 97 |
| 100 #endif // UI_ANDROID_RESOURCES_RESOURCE_MANAGER_H_ | 98 #endif // UI_ANDROID_RESOURCES_RESOURCE_MANAGER_H_ |
| OLD | NEW |