mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-06-17 13:21:44 +08:00
Summary: ImageLoader is an actual external dependency, not a ImageManager. That change allows to remove dependency on ImageManager from SurfacePresenter and make some other code simpler. Reviewed By: mdvacca Differential Revision: D15242047 fbshipit-source-id: 8622d15b8fdb5c3a7e25091adf7be1108f87ecd5
39 lines
798 B
C++
39 lines
798 B
C++
/**
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <memory>
|
|
|
|
#include <react/imagemanager/ImageRequest.h>
|
|
#include <react/imagemanager/primitives.h>
|
|
#include <react/utils/ContextContainer.h>
|
|
|
|
namespace facebook {
|
|
namespace react {
|
|
|
|
class ImageManager;
|
|
|
|
using SharedImageManager = std::shared_ptr<ImageManager>;
|
|
|
|
/*
|
|
* Cross platform facade for iOS-specific RCTImageManager.
|
|
*/
|
|
class ImageManager {
|
|
public:
|
|
ImageManager(ContextContainer::Shared const &contextContainer);
|
|
~ImageManager();
|
|
|
|
ImageRequest requestImage(const ImageSource &imageSource) const;
|
|
|
|
private:
|
|
void *self_;
|
|
};
|
|
|
|
} // namespace react
|
|
} // namespace facebook
|