OpenCoverage

qquickstateoperations_p.h

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/quick/items/qquickstateoperations_p.h
Source codeSwitch to Preprocessed file
LineSourceCount
1/****************************************************************************-
2**-
3** Copyright (C) 2016 The Qt Company Ltd.-
4** Contact: https://www.qt.io/licensing/-
5**-
6** This file is part of the QtQuick module of the Qt Toolkit.-
7**-
8** $QT_BEGIN_LICENSE:LGPL$-
9** Commercial License Usage-
10** Licensees holding valid commercial Qt licenses may use this file in-
11** accordance with the commercial license agreement provided with the-
12** Software or, alternatively, in accordance with the terms contained in-
13** a written agreement between you and The Qt Company. For licensing terms-
14** and conditions see https://www.qt.io/terms-conditions. For further-
15** information use the contact form at https://www.qt.io/contact-us.-
16**-
17** GNU Lesser General Public License Usage-
18** Alternatively, this file may be used under the terms of the GNU Lesser-
19** General Public License version 3 as published by the Free Software-
20** Foundation and appearing in the file LICENSE.LGPL3 included in the-
21** packaging of this file. Please review the following information to-
22** ensure the GNU Lesser General Public License version 3 requirements-
23** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.-
24**-
25** GNU General Public License Usage-
26** Alternatively, this file may be used under the terms of the GNU-
27** General Public License version 2.0 or (at your option) the GNU General-
28** Public license version 3 or any later version approved by the KDE Free-
29** Qt Foundation. The licenses are as published by the Free Software-
30** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3-
31** included in the packaging of this file. Please review the following-
32** information to ensure the GNU General Public License requirements will-
33** be met: https://www.gnu.org/licenses/gpl-2.0.html and-
34** https://www.gnu.org/licenses/gpl-3.0.html.-
35**-
36** $QT_END_LICENSE$-
37**-
38****************************************************************************/-
39-
40#ifndef QQUICKSTATEOPERATIONS_P_H-
41#define QQUICKSTATEOPERATIONS_P_H-
42-
43//-
44// W A R N I N G-
45// --------------
46//-
47// This file is not part of the Qt API. It exists purely as an-
48// implementation detail. This header file may change from version to-
49// version without notice, or even be removed.-
50//-
51// We mean it.-
52//-
53-
54#include "qquickitem.h"-
55#include "qquickanchors_p.h"-
56-
57#include <QtQuick/private/qquickstate_p.h>-
58-
59#include <QtQml/qqmlscriptstring.h>-
60-
61QT_BEGIN_NAMESPACE-
62-
63class QQuickParentChangePrivate;-
64class Q_AUTOTEST_EXPORT QQuickParentChange : public QQuickStateOperation, public QQuickStateActionEvent-
65{-
66 Q_OBJECT-
67 Q_DECLARE_PRIVATE(QQuickParentChange)
executed 950 times by 5 tests: return reinterpret_cast<QQuickParentChangePrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_examples
  • tst_qquickanimations
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickstates
executed 22 times by 2 tests: return reinterpret_cast<const QQuickParentChangePrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_qquickanimations
  • tst_qquickstates
22-950
68-
69 Q_PROPERTY(QQuickItem *target READ object WRITE setObject)-
70 Q_PROPERTY(QQuickItem *parent READ parent WRITE setParent)-
71 Q_PROPERTY(QQmlScriptString x READ x WRITE setX)-
72 Q_PROPERTY(QQmlScriptString y READ y WRITE setY)-
73 Q_PROPERTY(QQmlScriptString width READ width WRITE setWidth)-
74 Q_PROPERTY(QQmlScriptString height READ height WRITE setHeight)-
75 Q_PROPERTY(QQmlScriptString scale READ scale WRITE setScale)-
76 Q_PROPERTY(QQmlScriptString rotation READ rotation WRITE setRotation)-
77public:-
78 QQuickParentChange(QObject *parent=nullptr);-
79 ~QQuickParentChange();-
80-
81 QQuickItem *object() const;-
82 void setObject(QQuickItem *);-
83-
84 QQuickItem *parent() const;-
85 void setParent(QQuickItem *);-
86-
87 QQuickItem *originalParent() const;-
88-
89 QQmlScriptString x() const;-
90 void setX(QQmlScriptString x);-
91 bool xIsSet() const;-
92-
93 QQmlScriptString y() const;-
94 void setY(QQmlScriptString y);-
95 bool yIsSet() const;-
96-
97 QQmlScriptString width() const;-
98 void setWidth(QQmlScriptString width);-
99 bool widthIsSet() const;-
100-
101 QQmlScriptString height() const;-
102 void setHeight(QQmlScriptString height);-
103 bool heightIsSet() const;-
104-
105 QQmlScriptString scale() const;-
106 void setScale(QQmlScriptString scale);-
107 bool scaleIsSet() const;-
108-
109 QQmlScriptString rotation() const;-
110 void setRotation(QQmlScriptString rotation);-
111 bool rotationIsSet() const;-
112-
113 ActionList actions() override;-
114-
115 void saveOriginals() override;-
116 //virtual void copyOriginals(QQuickStateActionEvent*);-
117 void execute() override;-
118 bool isReversable() override;-
119 void reverse() override;-
120 EventType type() const override;-
121 bool mayOverride(QQuickStateActionEvent*other) override;-
122 void rewind() override;-
123 void saveCurrentValues() override;-
124};-
125-
126class QQuickAnchorChanges;-
127class QQuickAnchorSetPrivate;-
128class Q_AUTOTEST_EXPORT QQuickAnchorSet : public QObject-
129{-
130 Q_OBJECT-
131-
132 Q_PROPERTY(QQmlScriptString left READ left WRITE setLeft RESET resetLeft)-
133 Q_PROPERTY(QQmlScriptString right READ right WRITE setRight RESET resetRight)-
134 Q_PROPERTY(QQmlScriptString horizontalCenter READ horizontalCenter WRITE setHorizontalCenter RESET resetHorizontalCenter)-
135 Q_PROPERTY(QQmlScriptString top READ top WRITE setTop RESET resetTop)-
136 Q_PROPERTY(QQmlScriptString bottom READ bottom WRITE setBottom RESET resetBottom)-
137 Q_PROPERTY(QQmlScriptString verticalCenter READ verticalCenter WRITE setVerticalCenter RESET resetVerticalCenter)-
138 Q_PROPERTY(QQmlScriptString baseline READ baseline WRITE setBaseline RESET resetBaseline)-
139-
140public:-
141 QQuickAnchorSet(QObject *parent=nullptr);-
142 virtual ~QQuickAnchorSet();-
143-
144 QQmlScriptString left() const;-
145 void setLeft(const QQmlScriptString &edge);-
146 void resetLeft();-
147-
148 QQmlScriptString right() const;-
149 void setRight(const QQmlScriptString &edge);-
150 void resetRight();-
151-
152 QQmlScriptString horizontalCenter() const;-
153 void setHorizontalCenter(const QQmlScriptString &edge);-
154 void resetHorizontalCenter();-
155-
156 QQmlScriptString top() const;-
157 void setTop(const QQmlScriptString &edge);-
158 void resetTop();-
159-
160 QQmlScriptString bottom() const;-
161 void setBottom(const QQmlScriptString &edge);-
162 void resetBottom();-
163-
164 QQmlScriptString verticalCenter() const;-
165 void setVerticalCenter(const QQmlScriptString &edge);-
166 void resetVerticalCenter();-
167-
168 QQmlScriptString baseline() const;-
169 void setBaseline(const QQmlScriptString &edge);-
170 void resetBaseline();-
171-
172 QQuickAnchors::Anchors usedAnchors() const;-
173-
174private:-
175 friend class QQuickAnchorChanges;-
176 Q_DISABLE_COPY(QQuickAnchorSet)-
177 Q_DECLARE_PRIVATE(QQuickAnchorSet)
executed 1024 times by 5 tests: return reinterpret_cast<QQuickAnchorSetPrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_examples
  • tst_qquickanimations
  • tst_qquickitem2
  • tst_qquicklistview
  • tst_qquickstates
executed 16 times by 1 test: return reinterpret_cast<const QQuickAnchorSetPrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_qquickstates
16-1024
178};-
179-
180class QQuickAnchorChangesPrivate;-
181class Q_AUTOTEST_EXPORT QQuickAnchorChanges : public QQuickStateOperation, public QQuickStateActionEvent-
182{-
183 Q_OBJECT-
184 Q_DECLARE_PRIVATE(QQuickAnchorChanges)
executed 350 times by 5 tests: return reinterpret_cast<QQuickAnchorChangesPrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_examples
  • tst_qquickanimations
  • tst_qquickitem2
  • tst_qquicklistview
  • tst_qquickstates
executed 142 times by 5 tests: return reinterpret_cast<const QQuickAnchorChangesPrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_examples
  • tst_qquickanimations
  • tst_qquickitem2
  • tst_qquicklistview
  • tst_qquickstates
142-350
185-
186 Q_PROPERTY(QQuickItem *target READ object WRITE setObject)-
187 Q_PROPERTY(QQuickAnchorSet *anchors READ anchors CONSTANT)-
188-
189public:-
190 QQuickAnchorChanges(QObject *parent=nullptr);-
191 ~QQuickAnchorChanges();-
192-
193 ActionList actions() override;-
194-
195 QQuickAnchorSet *anchors() const;-
196-
197 QQuickItem *object() const;-
198 void setObject(QQuickItem *);-
199-
200 void execute() override;-
201 bool isReversable() override;-
202 void reverse() override;-
203 EventType type() const override;-
204 bool mayOverride(QQuickStateActionEvent*other) override;-
205 bool changesBindings() override;-
206 void saveOriginals() override;-
207 bool needsCopy() override { return true; }
executed 4 times by 1 test: return true;
Executed by:
  • tst_qquickanimations
4
208 void copyOriginals(QQuickStateActionEvent*) override;-
209 void clearBindings() override;-
210 void rewind() override;-
211 void saveCurrentValues() override;-
212-
213 QList<QQuickStateAction> additionalActions() const;-
214 void saveTargetValues() override;-
215};-
216-
217QT_END_NAMESPACE-
218-
219QML_DECLARE_TYPE(QQuickParentChange)-
220QML_DECLARE_TYPE(QQuickAnchorSet)-
221QML_DECLARE_TYPE(QQuickAnchorChanges)-
222-
223#endif // QQUICKSTATEOPERATIONS_P_H-
224-
Source codeSwitch to Preprocessed file

Generated by Squish Coco 4.2.0