#ifndef SHAREHELPER_H
#define SHAREHELPER_H
#include <QObject>
#include <QPixmap>
#include <qmlapplicationviewer.h>
#include <QDir>
// sharehelper.h is based on the PhotoMosaic App
// See: http://www.developer.nokia.com/Community/Wiki/Photomosaic_App_with_Qt
// PhotoMosaic in turn based on the butaca project
// See: http://projects.developer.nokia.com/butaca/
// The article "How to Use the Harmattan?s ShareUI Framework in Qml" on linux4us.org was also helpful
// See: http://blog.linux4us.org/2012/06/14/how-to-use-the-harmattans-shareui-framework-qml/
class ShareHelper : public QObject
{
public:
ShareHelper(QmlApplicationViewer* currentView);
Q_OBJECT public: Q_INVOKABLE void shareScreen(QString title, QString description, QString url);
//explicit ShareHelper(QObject *parent = 0);
signals:
public slots:
//! Shares a URL with the share-ui interface
//! \param title The title of the content to be shared
//! \param description The description of the content to be shared
//! \param url The URL to be shared
void shareURL(QString title, QString description, QString url);
//! Shares an Image with the share-ui interface
//! \param title The title of the content to be shared
//! \param description The description of the content to be shared
//! \param url The URL of the image to be shared
void shareImage(QString title, QString description, QString url);
private:
QmlApplicationViewer* currentView;
};
#endif // SHAREHELPER_H
it does take a screenshot on simulator but on the device it does not? (makes a gray image) and opens the share page but does not display the image? some help would be apricated
I just need help in the following stuff:
Takeing a Screenshot and use teh Share Api to share it! what i have done so far is: