Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qsignalmapper.h
Go to the documentation of this file.
1// Copyright (C) 2016 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 QSIGNALMAPPER_H
5#define QSIGNALMAPPER_H
6
7#include <QtCore/qobject.h>
8
10
12
13class Q_CORE_EXPORT QSignalMapper : public QObject
14{
16 Q_DECLARE_PRIVATE(QSignalMapper)
17public:
18 explicit QSignalMapper(QObject *parent = nullptr);
20
21 void setMapping(QObject *sender, int id);
22 void setMapping(QObject *sender, const QString &text);
23 void setMapping(QObject *sender, QObject *object);
24 void removeMappings(QObject *sender);
25
26 QObject *mapping(int id) const;
27 QObject *mapping(const QString &text) const;
28 QObject *mapping(QObject *object) const;
29
31 void mappedInt(int);
32 void mappedString(const QString &);
34
35public Q_SLOTS:
36 void map();
37 void map(QObject *sender);
38
39private:
40 Q_DISABLE_COPY(QSignalMapper)
41 Q_PRIVATE_SLOT(d_func(), void _q_senderDestroyed())
42};
43
45
46#endif // QSIGNALMAPPER_H
\inmodule QtCore
Definition qobject.h:90
\inmodule QtCore
void mappedString(const QString &)
void mappedObject(QObject *)
void mappedInt(int)
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:127
QMap< QString, QString > map
[6]
QString text
Combined button and popup list for selecting options.
GLenum GLenum GLenum GLenum mapping
#define Q_OBJECT
#define Q_SLOTS
#define Q_PRIVATE_SLOT(d, signature)
#define Q_SIGNALS
IUIAutomationTreeWalker __RPC__deref_out_opt IUIAutomationElement ** parent