Bug 1503656 - Part 4. Add safe area to nsIWidget. r=emilio

Safe area value is stored in nsIWidget for each platform support

Differential Revision: https://phabricator.services.mozilla.com/D52508

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Makoto Kato 2020-03-04 08:15:13 +00:00
parent aa5b814fee
commit 1df343ef04

View File

@ -372,6 +372,7 @@ class nsIWidget : public nsISupports {
typedef mozilla::LayoutDeviceIntRegion LayoutDeviceIntRegion;
typedef mozilla::LayoutDeviceIntSize LayoutDeviceIntSize;
typedef mozilla::ScreenIntPoint ScreenIntPoint;
typedef mozilla::ScreenIntMargin ScreenIntMargin;
typedef mozilla::ScreenIntSize ScreenIntSize;
typedef mozilla::ScreenPoint ScreenPoint;
typedef mozilla::CSSToScreenScale CSSToScreenScale;
@ -1742,6 +1743,14 @@ class nsIWidget : public nsISupports {
}
#endif
/*
* Get safe area insets except to cutout.
* See https://drafts.csswg.org/css-env-1/#safe-area-insets.
*/
virtual mozilla::ScreenIntMargin GetSafeAreaInsets() const {
return mozilla::ScreenIntMargin();
}
private:
class LongTapInfo {
public: