Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qquickswipe_p.h
Go to the documentation of this file.
1// Copyright (C) 2017 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QQUICKSWIPE_P_H
5#define QQUICKSWIPE_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QtCore/qobject.h>
19#include <QtQuickTemplates2/private/qtquicktemplates2global_p.h>
20#include <QtQuickTemplates2/private/qquickswipedelegate_p.h>
21
23
24class QQmlComponent;
25class QQuickItem;
28
29class Q_QUICKTEMPLATES2_EXPORT QQuickSwipe : public QObject
30{
32 Q_PROPERTY(qreal position READ position WRITE setPosition NOTIFY positionChanged FINAL)
33 Q_PROPERTY(bool complete READ isComplete NOTIFY completeChanged FINAL)
34 Q_PROPERTY(QQmlComponent *left READ left WRITE setLeft NOTIFY leftChanged FINAL)
35 Q_PROPERTY(QQmlComponent *behind READ behind WRITE setBehind NOTIFY behindChanged FINAL)
36 Q_PROPERTY(QQmlComponent *right READ right WRITE setRight NOTIFY rightChanged FINAL)
37 Q_PROPERTY(QQuickItem *leftItem READ leftItem NOTIFY leftItemChanged FINAL)
38 Q_PROPERTY(QQuickItem *behindItem READ behindItem NOTIFY behindItemChanged FINAL)
39 Q_PROPERTY(QQuickItem *rightItem READ rightItem NOTIFY rightItemChanged FINAL)
40 // 2.2 (Qt 5.9)
41 Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY enabledChanged FINAL) // REVISION(2, 2)
42 Q_PROPERTY(QQuickTransition *transition READ transition WRITE setTransition NOTIFY transitionChanged FINAL) // REVISION(2, 2)
45
46public:
48
49 qreal position() const;
51
52 bool isComplete() const;
53 void setComplete(bool complete);
54
55 QQmlComponent *left() const;
56 void setLeft(QQmlComponent *left);
57
58 QQmlComponent *behind() const;
59 void setBehind(QQmlComponent *behind);
60
61 QQmlComponent *right() const;
62 void setRight(QQmlComponent *right);
63
64 QQuickItem *leftItem() const;
65 void setLeftItem(QQuickItem *item);
66
67 QQuickItem *behindItem() const;
68 void setBehindItem(QQuickItem *item);
69
70 QQuickItem *rightItem() const;
71 void setRightItem(QQuickItem *item);
72
73 // 2.1 (Qt 5.8)
74 Q_REVISION(2, 1) Q_INVOKABLE void close();
75
76 // 2.2 (Qt 5.9)
77 bool isEnabled() const;
78 void setEnabled(bool enabled);
79
80 QQuickTransition *transition() const;
81 void setTransition(QQuickTransition *transition);
82
83 Q_REVISION(2, 2) Q_INVOKABLE void open(QQuickSwipeDelegate::Side side);
84
86 void positionChanged();
87 void completeChanged();
88 void leftChanged();
89 void behindChanged();
90 void rightChanged();
91 void leftItemChanged();
92 void behindItemChanged();
93 void rightItemChanged();
94 // 2.1 (Qt 5.8)
95 /*Q_REVISION(2, 1)*/ void completed();
96 // 2.2 (Qt 5.9)
97 /*Q_REVISION(2, 2)*/ void opened();
98 /*Q_REVISION(2, 2)*/ void closed();
99 /*Q_REVISION(2, 2)*/ void enabledChanged();
100 /*Q_REVISION(2, 2)*/ void transitionChanged();
101
102private:
103 Q_DISABLE_COPY(QQuickSwipe)
104 Q_DECLARE_PRIVATE(QQuickSwipe)
105};
106
108
109#endif // QQUICKSWIPE_P_H
\inmodule QtCore
Definition qobject.h:103
The QQmlComponent class encapsulates a QML component definition.
The QQuickItem class provides the most basic of all visual items in \l {Qt Quick}.
Definition qquickitem.h:63
Combined button and popup list for selecting options.
n void setPosition(void) \n\
GLdouble GLdouble right
GLenum GLenum GLsizei const GLuint GLboolean enabled
GLint left
#define QML_ANONYMOUS
#define QML_ADDED_IN_VERSION(MAJOR, MINOR)
static qreal position(const QQuickItem *item, QQuickAnchors::Anchor anchorLine)
#define Q_PROPERTY(...)
#define Q_OBJECT
#define Q_REVISION(...)
#define Q_INVOKABLE
#define Q_SIGNALS
double qreal
Definition qtypes.h:187
#define explicit
file open(QIODevice::ReadOnly)
QGraphicsItem * item