Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qqmltypeloadernetworkreplyproxy_p.h
Go to the documentation of this file.
1// Copyright (C) 2019 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 QQMLTYPELOADERNETWORKREPLYPROXY_P_H
5#define QQMLTYPELOADERNETWORKREPLYPROXY_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 <QtQml/qtqmlglobal.h>
19#include <QtCore/qobject.h>
20#include <QtCore/private/qglobal_p.h>
21
23
24QT_BEGIN_NAMESPACE
25
26class QNetworkReply;
27class QQmlTypeLoader;
28
29// This is a lame object that we need to ensure that slots connected to
30// QNetworkReply get called in the correct thread (the loader thread).
31// As QQmlTypeLoader lives in the main thread, and we can't use
32// Qt::DirectConnection connections from a QNetworkReply (because then
33// sender() wont work), we need to insert this object in the middle.
35{
37public:
39
40public Q_SLOTS:
41 void finished();
43 void manualFinished(QNetworkReply*);
44
45private:
46 QQmlTypeLoader *l;
47};
48
49QT_END_NAMESPACE
50
51#endif // QQMLTYPELOADERNETWORKREPLYPROXY_P_H
QT_REQUIRE_CONFIG(qml_network)