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
qjsmanagedvalue_p.h
Go to the documentation of this file.
1// Copyright (C) 2025 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#ifndef QJSMANAGEDVALUE_P_H
6#define QJSMANAGEDVALUE_P_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is not part of the Qt API. It exists purely as an
13// implementation detail. This header file may change from version to
14// version without notice, or even be removed.
15//
16// We mean it.
17//
18
20
21#include <private/qv4managed_p.h>
22
24
25// ### Qt 7: Use this for proper PIMPL
27{
28public:
29 static QV4::Value *member(const QJSManagedValue *jsmv) { return jsmv->d; }
30
31 static QJSManagedValue create(QV4::ExecutionEngine *engine, const QV4::Value &value)
32 {
33 QJSManagedValue result(engine);
34 *result.d = value;
35 return result;
36 }
37
38 static QJSManagedValue create(const QV4::Managed &managed)
39 {
40 return create(managed.engine(), managed);
41 }
42};
43
44QT_END_NAMESPACE
45
46#endif // QJSMANAGEDVALUE_P_H
static QV4::Value * member(const QJSManagedValue *jsmv)
static QJSManagedValue create(QV4::ExecutionEngine *engine, const QV4::Value &value)
static QJSManagedValue create(const QV4::Managed &managed)
Combined button and popup list for selecting options.
Definition qjsvalue.h:24