Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qnativeinterface_p.h File Reference

(7466422e9ce964553dd09fce9f48437af7ec76c8)

#include <QtCore/private/qglobal_p.h>
#include <QtCore/qloggingcategory.h>
+ Include dependency graph for qnativeinterface_p.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  QtPrivate
 \macro QT_NO_KEYWORDS >
 

Macros

#define QT_DEFINE_NATIVE_INTERFACE_2(Namespace, InterfaceClass)    QT_PREPEND_NAMESPACE(Namespace)::InterfaceClass::~InterfaceClass() = default
 
#define QT_DEFINE_NATIVE_INTERFACE(...)    QT_OVERLOADED_MACRO(QT_DEFINE_NATIVE_INTERFACE, QNativeInterface, __VA_ARGS__)
 
#define QT_DEFINE_PRIVATE_NATIVE_INTERFACE(...)    QT_OVERLOADED_MACRO(QT_DEFINE_NATIVE_INTERFACE, QNativeInterface::Private, __VA_ARGS__)
 
#define QT_NATIVE_INTERFACE_RETURN_IF(NativeInterface, baseType)
 

Macro Definition Documentation

◆ QT_DEFINE_NATIVE_INTERFACE

#define QT_DEFINE_NATIVE_INTERFACE ( ...)     QT_OVERLOADED_MACRO(QT_DEFINE_NATIVE_INTERFACE, QNativeInterface, __VA_ARGS__)

Definition at line 31 of file qnativeinterface_p.h.

◆ QT_DEFINE_NATIVE_INTERFACE_2

#define QT_DEFINE_NATIVE_INTERFACE_2 ( Namespace,
InterfaceClass )    QT_PREPEND_NAMESPACE(Namespace)::InterfaceClass::~InterfaceClass() = default

Definition at line 28 of file qnativeinterface_p.h.

◆ QT_DEFINE_PRIVATE_NATIVE_INTERFACE

#define QT_DEFINE_PRIVATE_NATIVE_INTERFACE ( ...)     QT_OVERLOADED_MACRO(QT_DEFINE_NATIVE_INTERFACE, QNativeInterface::Private, __VA_ARGS__)

Definition at line 33 of file qnativeinterface_p.h.

◆ QT_NATIVE_INTERFACE_RETURN_IF

#define QT_NATIVE_INTERFACE_RETURN_IF ( NativeInterface,
baseType )
Value:
{ \
using QtPrivate::lcNativeInterface; \
qCDebug(lcNativeInterface, "Comparing requested interface name %s with available %s", \
name, TypeInfo<NativeInterface>::name()); \
if (qstrcmp(name, TypeInfo<NativeInterface>::name()) == 0) { \
qCDebug(lcNativeInterface, \
"Match for interface %s. Comparing revisions (requested %d / available %d)", \
name, revision, TypeInfo<NativeInterface>::revision()); \
if (revision == TypeInfo<NativeInterface>::revision()) { \
qCDebug(lcNativeInterface) << "Full match. Returning dynamic cast of" << baseType; \
return dynamic_cast<NativeInterface *>(baseType); \
} else { \
qCWarning(lcNativeInterface, \
"Native interface revision mismatch (requested %d / available %d) for " \
"interface %s", \
revision, TypeInfo<NativeInterface>::revision(), name); \
return nullptr; \
} \
} else { \
qCDebug(lcNativeInterface, "No match for requested interface name %s", name); \
} \
}
Q_CORE_EXPORT int qstrcmp(const char *str1, const char *str2)
GLuint name

Definition at line 36 of file qnativeinterface_p.h.