From 0efe79f80d6f249040f47162ebbfc82289ca073d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Wed, 7 Oct 2020 12:11:46 +0200 Subject: Rename the new platform APIs from QPlatformInterface to QNativeInterface We were already using the 'native' nomenclature when referring to these kinds of APIs, e.g. when talking about native handles, or the existing QPlatformNativeInterface on a QPA level. Using 'native' for the user facing APIs also distinguishes them from the 'platform' backend layer in QPA and elsewhere. Change-Id: I0f3273265904f0f19c0b6d62471f8820d3c3232e Reviewed-by: Friedemann Kleint Reviewed-by: Lars Knoll --- src/gui/platform/unix/qunixplatforminterface.cpp | 26 ++++++++++++------------ 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'src/gui/platform/unix/qunixplatforminterface.cpp') diff --git a/src/gui/platform/unix/qunixplatforminterface.cpp b/src/gui/platform/unix/qunixplatforminterface.cpp index 55650e3efcc..378282936ee 100644 --- a/src/gui/platform/unix/qunixplatforminterface.cpp +++ b/src/gui/platform/unix/qunixplatforminterface.cpp @@ -51,21 +51,21 @@ QT_BEGIN_NAMESPACE -using namespace QPlatformInterface::Private; +using namespace QNativeInterface::Private; #ifndef QT_NO_OPENGL #if defined(Q_OS_LINUX) -QT_DEFINE_PLATFORM_INTERFACE(QGLXContext, QOpenGLContext); -QT_DEFINE_PRIVATE_PLATFORM_INTERFACE(QGLXIntegration); +QT_DEFINE_NATIVE_INTERFACE(QGLXContext, QOpenGLContext); +QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QGLXIntegration); -QOpenGLContext *QPlatformInterface::QGLXContext::fromNative(GLXContext configBasedContext, QOpenGLContext *shareContext) +QOpenGLContext *QNativeInterface::QGLXContext::fromNative(GLXContext configBasedContext, QOpenGLContext *shareContext) { return QGuiApplicationPrivate::platformIntegration()->call< &QGLXIntegration::createOpenGLContext>(configBasedContext, nullptr, shareContext); } -QOpenGLContext *QPlatformInterface::QGLXContext::fromNative(GLXContext visualBasedContext, void *visualInfo, QOpenGLContext *shareContext) +QOpenGLContext *QNativeInterface::QGLXContext::fromNative(GLXContext visualBasedContext, void *visualInfo, QOpenGLContext *shareContext) { return QGuiApplicationPrivate::platformIntegration()->call< &QGLXIntegration::createOpenGLContext>(visualBasedContext, visualInfo, shareContext); @@ -73,10 +73,10 @@ QOpenGLContext *QPlatformInterface::QGLXContext::fromNative(GLXContext visualBas #endif #if QT_CONFIG(egl) -QT_DEFINE_PLATFORM_INTERFACE(QEGLContext, QOpenGLContext); -QT_DEFINE_PRIVATE_PLATFORM_INTERFACE(QEGLIntegration); +QT_DEFINE_NATIVE_INTERFACE(QEGLContext, QOpenGLContext); +QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QEGLIntegration); -QOpenGLContext *QPlatformInterface::QEGLContext::fromNative(EGLContext context, EGLDisplay display, QOpenGLContext *shareContext) +QOpenGLContext *QNativeInterface::QEGLContext::fromNative(EGLContext context, EGLDisplay display, QOpenGLContext *shareContext) { return QGuiApplicationPrivate::platformIntegration()->call< &QEGLIntegration::createOpenGLContext>(context, display, shareContext); @@ -86,19 +86,19 @@ QOpenGLContext *QPlatformInterface::QEGLContext::fromNative(EGLContext context, #endif // QT_NO_OPENGL #if QT_CONFIG(xcb) -QT_DEFINE_PRIVATE_PLATFORM_INTERFACE(QXcbScreen); -QT_DEFINE_PRIVATE_PLATFORM_INTERFACE(QXcbWindow); +QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QXcbScreen); +QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QXcbWindow); #endif #if QT_CONFIG(vsp2) -QT_DEFINE_PRIVATE_PLATFORM_INTERFACE(QVsp2Screen); +QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QVsp2Screen); #endif #if QT_CONFIG(evdev) -QT_DEFINE_PRIVATE_PLATFORM_INTERFACE(QEvdevKeyMapper); +QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QEvdevKeyMapper); template <> -QEvdevKeyMapper *QKeyMapper::platformInterface() const +QEvdevKeyMapper *QKeyMapper::nativeInterface() const { return dynamic_cast(QGuiApplicationPrivate::platformIntegration()); } -- cgit v1.2.3