2017-04-23 15:05:48 +02:00
|
|
|
#include "clipboarduploader.hpp"
|
|
|
|
|
|
|
|
#include <QApplication>
|
|
|
|
#include <QClipboard>
|
2017-04-25 22:17:36 +02:00
|
|
|
#include <notifications.hpp>
|
2017-04-23 15:05:48 +02:00
|
|
|
|
2017-06-04 22:58:29 +02:00
|
|
|
void ClipboardUploader::doUpload(QByteArray imgData) {
|
|
|
|
QApplication::clipboard()->setImage(QImage::fromData(imgData, std::get<0>(format()).toLocal8Bit().constData()));
|
2017-05-09 17:26:00 +02:00
|
|
|
notifications::notify("KShare", "Copied to clipboard!");
|
2017-04-23 15:05:48 +02:00
|
|
|
}
|