gecko-dev/widget/android/ImageDecoderSupport.h
Agi Sferro cbc3c1528e Bug 1530402 - Provide GeckoImageDecoder. r=snorp
This class allows GeckoView embedders to decode images using Gecko's image
library.

Differential Revision: https://phabricator.services.mozilla.com/D49038

--HG--
extra : moz-landing-system : lando
2019-11-18 16:48:55 +00:00

31 lines
892 B
C++

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef ImageDecoderSupport_h__
#define ImageDecoderSupport_h__
#include "GeneratedJNINatives.h"
class imgIContainerCallback;
namespace mozilla {
namespace widget {
class ImageDecoderSupport final
: public java::ImageDecoder::Natives<ImageDecoderSupport> {
public:
static void Decode(jni::String::Param aUri, int32_t aDesiredLength,
jni::Object::Param aResult);
private:
static nsresult DecodeInternal(const nsAString& aUri,
imgIContainerCallback* aCallback,
imgINotificationObserver* aObserver);
};
} // namespace widget
} // namespace mozilla
#endif // ImageDecoderSupport_h__