diff options
author | powei@chromium.org <powei@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-13 07:15:45 +0000 |
---|---|---|
committer | powei@chromium.org <powei@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-13 07:15:45 +0000 |
commit | 4825cbfd9d1ffe09f93172893e73819ab9347546 (patch) | |
tree | 0f1394483574c1711acd8e32f62a6ff098521f9b /content/public/browser/android/ui_resource_provider.h | |
parent | 993c38816404ba88b532bbaef4aaf232cdcf1dea (diff) | |
download | chromium_src-4825cbfd9d1ffe09f93172893e73819ab9347546.zip chromium_src-4825cbfd9d1ffe09f93172893e73819ab9347546.tar.gz chromium_src-4825cbfd9d1ffe09f93172893e73819ab9347546.tar.bz2 |
android: content::UIResourceProvider and content::UIResourceClientAndroid
We abstract out the allocation of UI resources into the UIResourceProvider.
We add a client class that allows for callback from the provider when
resources are invalidated (due to change in LayerTreeHost).
android= https://chrome-internal-review.googlesource.com/#/c/164986
BUG=
TBR=jam@chromium.org
Review URL: https://codereview.chromium.org/287593002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276955 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/public/browser/android/ui_resource_provider.h')
-rw-r--r-- | content/public/browser/android/ui_resource_provider.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/content/public/browser/android/ui_resource_provider.h b/content/public/browser/android/ui_resource_provider.h new file mode 100644 index 0000000..38511e1 --- /dev/null +++ b/content/public/browser/android/ui_resource_provider.h @@ -0,0 +1,27 @@ +// Copyright 2014 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef CONTENT_PUBLIC_BROWSER_ANDROID_UI_RESOURCE_PROVIDER_H_ +#define CONTENT_PUBLIC_BROWSER_ANDROID_UI_RESOURCE_PROVIDER_H_ + +#include "cc/resources/ui_resource_client.h" +#include "content/common/content_export.h" + +namespace content { + +class UIResourceClientAndroid; + +class CONTENT_EXPORT UIResourceProvider { + public: + virtual ~UIResourceProvider() {} + + virtual cc::UIResourceId CreateUIResource( + UIResourceClientAndroid* client) = 0; + + virtual void DeleteUIResource(cc::UIResourceId resource_id) = 0; +}; + +} // namespace content + +#endif // CONTENT_PUBLIC_BROWSER_ANDROID_UI_RESOURCE_PROVIDER_H_ |