Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Toggle main menu visibility
Loading...
Searching...
No Matches
qquickindicatorbutton_p.h
Go to the documentation of this file.
1
// Copyright (C) 2020 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
// Qt-Security score:significant reason:default
4
#
ifndef
QQUICKINDICATORBUTTON_H
5
#
define
QQUICKINDICATORBUTTON_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
<
QtQuickTemplates2
/
private
/
qquickcontrol_p
.
h
>
19
#
include
<
QtQml
/
qjsvalue
.
h
>
20
#
include
"qquickdeferredpointer_p_p.h"
21
22
QT_BEGIN_NAMESPACE
23
24
class
QQuickIndicatorButtonPrivate
;
25
26
class
Q_QUICKTEMPLATES2_EXPORT
QQuickIndicatorButton
:
public
QObject
27
{
28
Q_OBJECT
29
Q_PROPERTY(
bool
pressed READ isPressed WRITE setPressed NOTIFY pressedChanged FINAL)
30
Q_PROPERTY(QQuickItem *indicator READ indicator WRITE setIndicator NOTIFY indicatorChanged FINAL)
31
// 2.1 (Qt 5.8)
32
Q_PROPERTY(
bool
hovered READ isHovered WRITE setHovered NOTIFY hoveredChanged FINAL REVISION(2, 1))
33
// 2.5 (Qt 5.12)
34
Q_PROPERTY(qreal implicitIndicatorWidth READ implicitIndicatorWidth NOTIFY implicitIndicatorWidthChanged FINAL REVISION(2, 5))
35
Q_PROPERTY(qreal implicitIndicatorHeight READ implicitIndicatorHeight NOTIFY implicitIndicatorHeightChanged FINAL REVISION(2, 5))
36
Q_CLASSINFO(
"DeferredPropertyNames"
,
"indicator"
)
37
QML_ANONYMOUS
38
QML_ADDED_IN_VERSION(2, 0)
39
40
public
:
41
explicit
QQuickIndicatorButton(QObject *parent);
42
~QQuickIndicatorButton() override;
43
44
bool
isPressed()
const
;
45
void
setPressed(
bool
pressed);
46
47
QQuickItem *indicator()
const
;
48
void
setIndicator(QQuickItem *indicator);
49
50
bool
isHovered()
const
;
51
void
setHovered(
bool
hovered);
52
53
qreal implicitIndicatorWidth()
const
;
54
qreal implicitIndicatorHeight()
const
;
55
56
Q_SIGNALS:
57
void
pressedChanged();
58
void
indicatorChanged();
59
// 2.1 (Qt 5.8)
60
Q_REVISION(2, 1)
void
hoveredChanged();
61
// 2.5 (Qt 5.12)
62
Q_REVISION(2, 5)
void
implicitIndicatorWidthChanged();
63
Q_REVISION(2, 5)
void
implicitIndicatorHeightChanged();
64
65
private
:
66
Q_DISABLE_COPY(QQuickIndicatorButton)
67
Q_DECLARE_PRIVATE(QQuickIndicatorButton)
68
};
69
70
class
QQuickIndicatorButtonPrivate
:
public
QObjectPrivate
71
{
72
Q_DECLARE_PUBLIC(QQuickIndicatorButton)
73
74
public
:
75
static
QQuickIndicatorButtonPrivate
*
get
(
QQuickIndicatorButton
*
button
)
76
{
77
return
button
->
d_func
();
78
}
79
80
void
cancelIndicator
();
81
void
executeIndicator
(
bool
complete =
false
);
82
83
bool
pressed
=
false
;
84
bool
hovered
=
false
;
85
QQuickDeferredPointer
<
QQuickItem
>
indicator
;
86
};
87
88
QT_END_NAMESPACE
89
90
#
endif
// QQUICKINDICATORBUTTON_H
QQuickIndicatorButtonPrivate
Definition
qquickindicatorbutton_p.h:71
QQuickIndicatorButtonPrivate::pressed
bool pressed
Definition
qquickindicatorbutton_p.h:83
QQuickIndicatorButtonPrivate::indicator
QQuickDeferredPointer< QQuickItem > indicator
Definition
qquickindicatorbutton_p.h:85
QQuickIndicatorButtonPrivate::hovered
bool hovered
Definition
qquickindicatorbutton_p.h:84
QQuickIndicatorButtonPrivate::executeIndicator
void executeIndicator(bool complete=false)
Definition
qquickindicatorbutton_p.cpp:18
QQuickIndicatorButton
Definition
qquickindicatorbutton_p.h:27
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qtdeclarative
src
quicktemplates
qquickindicatorbutton_p.h
Generated on
for Qt by
1.18.0