summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/android/qandroidplatformintegration.h
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2020-01-06 12:33:55 +0100
committerEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2020-01-07 07:10:44 +0100
commit42ecdfe6f3bcbf3e35ca88b24af07249e3936fc7 (patch)
tree3dddb3f2b877e313c65cd13f255be33ff8771376 /src/plugins/platforms/android/qandroidplatformintegration.h
parent68c30e372b01561e8809fcfa5426ae896da70b8e (diff)
Revert "Android: Implement MaximizeUsingFullscreenGeometryHint"
This reverts commit c17a5cec1901dd23f4c39ec2ae47a060fbb06895. The patch introduced a call to View.getRootViewInsets() which was introduced in API level 23. We don't want to change the minimum level for Qt 5.x series now, so we will revert the change in 5.15 and reintroduce it in Qt 6, simultaneously setting the minimum API level to 23. Task-number: QTBUG-74202 Change-Id: Ia25bb2cd62287aa80a43bbd294fb757f3f79ff5e Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Diffstat (limited to 'src/plugins/platforms/android/qandroidplatformintegration.h')
-rw-r--r--src/plugins/platforms/android/qandroidplatformintegration.h28
1 files changed, 15 insertions, 13 deletions
diff --git a/src/plugins/platforms/android/qandroidplatformintegration.h b/src/plugins/platforms/android/qandroidplatformintegration.h
index d607ec0064..c795c499bc 100644
--- a/src/plugins/platforms/android/qandroidplatformintegration.h
+++ b/src/plugins/platforms/android/qandroidplatformintegration.h
@@ -91,8 +91,8 @@ public:
QAndroidPlatformScreen *screen() { return m_primaryScreen; }
QPlatformOffscreenSurface *createPlatformOffscreenSurface(QOffscreenSurface *surface) const override;
- void setAvailableGeometry(const QRect &availableGeometry);
- void setPhysicalSize(int width, int height);
+ virtual void setDesktopSize(int width, int height);
+ virtual void setDisplayMetrics(int width, int height);
void setScreenSize(int width, int height);
bool isVirtualDesktop() { return true; }
@@ -116,17 +116,16 @@ public:
QStringList themeNames() const override;
QPlatformTheme *createPlatformTheme(const QString &name) const override;
- static void setDefaultDisplayMetrics(int availableLeft,
- int availableTop,
- int availableWidth,
- int availableHeight,
- int physicalWidth,
- int physicalHeight,
- int screenWidth,
- int screenHeight);
+ static void setDefaultDisplayMetrics(int gw, int gh, int sw, int sh, int width, int height);
+ static void setDefaultDesktopSize(int gw, int gh);
static void setScreenOrientation(Qt::ScreenOrientation currentOrientation,
Qt::ScreenOrientation nativeOrientation);
+ static QSize defaultDesktopSize()
+ {
+ return QSize(m_defaultGeometryWidth, m_defaultGeometryHeight);
+ }
+
QTouchDevice *touchDevice() const { return m_touchDevice; }
void setTouchDevice(QTouchDevice *touchDevice) { m_touchDevice = touchDevice; }
@@ -144,9 +143,12 @@ private:
QThread *m_mainThread;
- static QRect m_defaultAvailableGeometry;
- static QSize m_defaultPhysicalSize;
- static QSize m_defaultScreenSize;
+ static int m_defaultGeometryWidth;
+ static int m_defaultGeometryHeight;
+ static int m_defaultPhysicalSizeWidth;
+ static int m_defaultPhysicalSizeHeight;
+ static int m_defaultScreenWidth;
+ static int m_defaultScreenHeight;
static Qt::ScreenOrientation m_orientation;
static Qt::ScreenOrientation m_nativeOrientation;