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
qqmlpreviewclient_p.h
Go to the documentation of this file.
1// Copyright (C) 2018 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
4
5
6#ifndef QQMLPREVIEWCLIENT_P_H
7#define QQMLPREVIEWCLIENT_P_H
8
9//
10// W A R N I N G
11// -------------
12//
13// This file is not part of the Qt API. It exists purely as an
14// implementation detail. This header file may change from version to
15// version without notice, or even be removed.
16//
17// We mean it.
18//
19
20#include <private/qqmldebugclient_p.h>
21#include <private/qqmldebugconnection_p.h>
22
23#include <private/qqmlprofilerqtdwriter_p.h>
24#include <private/qqmlprofilerclient_p.h>
25#include <private/qquickeventreplayclient_p.h>
26
27#include <QtCore/QTimer>
28
29QT_BEGIN_NAMESPACE
30
31class QQmlPreviewClientPrivate;
33{
34 Q_OBJECT
35 Q_DECLARE_PRIVATE(QQmlPreviewClient)
36public:
52
53 struct Settings {
55 };
56
68
69 QQmlPreviewClient(QQmlDebugConnection *parent);
70 void messageReceived(const QByteArray &message) override;
71
72 void sendDirectory(const QString &path, const QStringList &entries);
73 void sendFile(const QString &path, const QByteArray &contents);
74 void sendError(const QString &path);
75 void sendConfiguration(const Settings &settings);
76
77 void triggerLoad(const QUrl &url);
78 void triggerRerun();
79 void triggerZoom(float factor);
80 void triggerAnimationSpeed(float factor);
81
82 void replayEvents();
83 void replayEvent(const QQmlProfilerEventType &type, QQmlProfilerEvent &&event);
84
85 bool saveEvents(const QString &fileName);
86 bool replayEventsFromFile(const QString &fileName);
87 bool hasRecordedEvents() const;
89
91 void request(const QString &path);
92 void error(const QString &message);
93 void fps(const QQmlPreviewClient::FpsInfo &info);
94 void confirmation(const QQmlPreviewClient::Settings &settings);
95 void hotReloadFailure(const QString &reason);
96
97private:
98 void configureEventReplay();
99};
100
101QT_END_NAMESPACE
102
103#endif // QQMLPREVIEWCLIENT_P_H
QQuickEventReplayClient replayClient
void messageReceived(const QByteArray &message) override
void triggerZoom(float factor)
void confirmation(const QQmlPreviewClient::Settings &settings)
void replayEvent(const QQmlProfilerEventType &type, QQmlProfilerEvent &&event)
bool replayEventsFromFile(const QString &fileName)
QQmlPreviewClient(QQmlDebugConnection *parent)
bool hasRecordedEvents() const
void triggerAnimationSpeed(float factor)
bool saveEvents(const QString &fileName)
void fps(const QQmlPreviewClient::FpsInfo &info)
void sendFile(const QString &path, const QByteArray &contents)
void sendError(const QString &path)
void error(const QString &message)
void sendDirectory(const QString &path, const QStringList &entries)
void sendConfiguration(const Settings &settings)
void triggerLoad(const QUrl &url)
void hotReloadFailure(const QString &reason)
Combined button and popup list for selecting options.