Supervised user import: Listen for profile creation/deletion
[chromium-blink-merge.git] / cc / test / fake_ui_resource_layer_tree_host_impl.h
blobe5fad822ebfec15b8c61449cfdff18c6b28a9bca
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
3 // found in the LICENSE file.
5 #ifndef CC_TEST_FAKE_UI_RESOURCE_LAYER_TREE_HOST_IMPL_H_
6 #define CC_TEST_FAKE_UI_RESOURCE_LAYER_TREE_HOST_IMPL_H_
8 #include "base/containers/hash_tables.h"
9 #include "cc/test/fake_layer_tree_host_impl.h"
11 namespace cc {
13 class FakeUIResourceLayerTreeHostImpl : public FakeLayerTreeHostImpl {
14 public:
15 explicit FakeUIResourceLayerTreeHostImpl(Proxy* proxy,
16 SharedBitmapManager* manager);
17 ~FakeUIResourceLayerTreeHostImpl() override;
19 void CreateUIResource(UIResourceId uid,
20 const UIResourceBitmap& bitmap) override;
22 void DeleteUIResource(UIResourceId uid) override;
24 ResourceProvider::ResourceId ResourceIdForUIResource(
25 UIResourceId uid) const override;
27 bool IsUIResourceOpaque(UIResourceId uid) const override;
29 private:
30 typedef base::hash_map<UIResourceId, LayerTreeHostImpl::UIResourceData>
31 UIResourceMap;
32 UIResourceMap fake_ui_resource_map_;
35 } // namespace cc
37 #endif // CC_TEST_FAKE_UI_RESOURCE_LAYER_TREE_HOST_IMPL_H_