summaryrefslogtreecommitdiffstats
path: root/tests/pysidetest/testobject.h
blob: ef0266199fec95a7ad7944b4dc3c5d0e9ad4aacf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#ifndef TESTOBJECT_H
#define TESTOBJECT_H

#include <QObject>
#include "pysidemacros.h"

class PYSIDE_API TestObject : public QObject
{
    Q_OBJECT
public:
    TestObject(int idValue, QObject* parent = 0) : QObject(parent), m_idValue(idValue) {}
    int idValue() const { return m_idValue; }
    static int staticMethodDouble(int value) { return value * 2; }

    void emitIdValueSignal();
    void emitStaticMethodDoubleSignal();

signals:
    void idValue(int newValue);
    void justASignal();
    void staticMethodDouble();

private:
    int m_idValue;
};

#endif // TESTOBJECT_H