qmlFrontend/previewimageprovider.h
author unc0rr
Thu, 11 Aug 2016 23:05:14 +0300
branchqmlfrontend
changeset 11843 01f88c3b7b66
parent 10424 4be6cd55f1cf
permissions -rw-r--r--
Make in-game chat work

#ifndef PREVIEWIMAGEPROVIDER_H
#define PREVIEWIMAGEPROVIDER_H

#include <QQuickImageProvider>
#include <QPixmap>
#include <QSize>

class PreviewImageProvider : public QQuickImageProvider
{
public:
    PreviewImageProvider();

    QPixmap requestPixmap(const QString &id, QSize *size, const QSize &requestedSize);

    void setPixmap(const QByteArray & px);

private:
    QPixmap m_px;
};

#endif // PREVIEWIMAGEPROVIDER_H