qmlfrontend/preview_image_provider.h
author nemo
Wed, 05 Dec 2018 09:38:31 -0500
branch0.9.25
changeset 14366 2ab312c47dc3
parent 14154 8354b390f1a2
permissions -rw-r--r--
make pas2c function without haskell aborting if locale is C

#ifndef PREVIEWIMAGEPROVIDER_H
#define PREVIEWIMAGEPROVIDER_H

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

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

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

  void setImage(const QImage &preview);

 private:
  QPixmap m_px;
};

#endif  // PREVIEWIMAGEPROVIDER_H