Android: Early spring QPA cleanup
- Move m_eglDisplay to private section - needsBasicRenderloopWorkaround is needed only locally so, make it a static function - remove unused member variables. Change-Id: I3e845301ec66a322621c7d9e6fac257320a40f77 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
This commit is contained in:
parent
05e073deeb
commit
5cb72486ba
@ -110,9 +110,9 @@ void *QAndroidPlatformNativeInterface::nativeResourceForIntegration(const QByteA
|
||||
}
|
||||
|
||||
QAndroidPlatformIntegration::QAndroidPlatformIntegration(const QStringList ¶mList)
|
||||
: m_touchDevice(0)
|
||||
: m_touchDevice(nullptr)
|
||||
#ifndef QT_NO_ACCESSIBILITY
|
||||
, m_accessibility(0)
|
||||
, m_accessibility(nullptr)
|
||||
#endif
|
||||
{
|
||||
Q_UNUSED(paramList);
|
||||
@ -183,7 +183,7 @@ QAndroidPlatformIntegration::QAndroidPlatformIntegration(const QStringList ¶
|
||||
QGuiApplicationPrivate::instance()->setApplicationState(m_defaultApplicationState);
|
||||
}
|
||||
|
||||
bool QAndroidPlatformIntegration::needsBasicRenderloopWorkaround()
|
||||
static bool needsBasicRenderloopWorkaround()
|
||||
{
|
||||
static bool needsWorkaround =
|
||||
QtAndroid::deviceName().compare(QLatin1String("samsung SM-T211"), Qt::CaseInsensitive) == 0
|
||||
@ -200,11 +200,7 @@ bool QAndroidPlatformIntegration::hasCapability(Capability cap) const
|
||||
case NativeWidgets: return true;
|
||||
case OpenGL: return true;
|
||||
case ForeignWindows: return true;
|
||||
case ThreadedOpenGL:
|
||||
if (needsBasicRenderloopWorkaround())
|
||||
return false;
|
||||
else
|
||||
return true;
|
||||
case ThreadedOpenGL: return !needsBasicRenderloopWorkaround();
|
||||
case RasterGLSurface: return true;
|
||||
default:
|
||||
return QPlatformIntegration::hasCapability(cap);
|
||||
|
@ -117,10 +117,8 @@ public:
|
||||
void setTouchDevice(QTouchDevice *touchDevice) { m_touchDevice = touchDevice; }
|
||||
static void setDefaultApplicationState(Qt::ApplicationState applicationState) { m_defaultApplicationState = applicationState; }
|
||||
|
||||
EGLDisplay m_eglDisplay;
|
||||
private:
|
||||
static bool needsBasicRenderloopWorkaround();
|
||||
|
||||
EGLDisplay m_eglDisplay;
|
||||
QTouchDevice *m_touchDevice;
|
||||
|
||||
QAndroidPlatformScreen *m_primaryScreen;
|
||||
@ -140,8 +138,6 @@ private:
|
||||
static Qt::ApplicationState m_defaultApplicationState;
|
||||
|
||||
QPlatformFontDatabase *m_androidFDB;
|
||||
QImage *m_FbScreenImage;
|
||||
QPainter *m_compositePainter;
|
||||
QAndroidPlatformNativeInterface *m_androidPlatformNativeInterface;
|
||||
QAndroidPlatformServices *m_androidPlatformServices;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user