annotatedurl.h Example File
annotatedurl/annotatedurl.h
#ifndef ANNOTATEDURL_H
#define ANNOTATEDURL_H
#include <QtNfc/QNdefMessage>
#include <QtCore/QObject>
QT_FORWARD_DECLARE_CLASS(QUrl)
QT_FORWARD_DECLARE_CLASS(QPixmap)
QT_FORWARD_DECLARE_CLASS(QNearFieldManager)
QT_FORWARD_DECLARE_CLASS(QNearFieldTarget)
class AnnotatedUrl : public QObject
{
Q_OBJECT
public:
explicit AnnotatedUrl(QObject *parent = 0);
~AnnotatedUrl();
signals:
void annotatedUrl(const QUrl &url, const QString &title, const QPixmap &pixmap);
public slots:
void targetDetected(QNearFieldTarget *target);
void targetLost(QNearFieldTarget *target);
void handleMessage(const QNdefMessage &message, QNearFieldTarget *target);
void handlePolledNdefMessage(QNdefMessage message);
private:
QNearFieldManager *manager;
};
#endif // ANNOTATEDURL_H