iphoneSafeAreaInsets()

scott at elementarysoftware.com scott at elementarysoftware.com
Wed Feb 23 15:29:11 EST 2022


Hmm… I had never noticed that mobileOrientation() and mobileDeviceOrientation() are different functions [ it doesn’t help that the documentation for mobileOrientation() seems to mistakenly refer to mobileDeviceOrientation() ] but mobileOrientation() seems like it should, unlike mobileDeviceOrientation(),  always be able to determine which side the notch is on.

—
Scott


> On Feb 23, 2022, at 12:15 PM, scott--- via use-livecode <use-livecode at lists.runrev.com> wrote:
> 
> I was updating a library to use the new iphoneSafeAreaInsets() for retuning the inset of the iPhoneX notch. I was surprised to see that it reports an inset on both left and right sides when in landscape even though the notch is only on one side. I would have expected an iPhone in landscape to report an inset on the bottom (for the home indicator, which it does report) and on whichever side the notch was actually on. While this can usually be figured out with  mobileDeviceOrientation()  (though not always) it seems like an extra step in addition to just being inaccurate about one side. Am I missing something or should this be a bug?
> 
> --
> Scott Morrow
> 
> Elementary Software
> (Now with 20% less chalk dust!)
> web       https://elementarysoftware.com/
> email     scott at elementarysoftware.com
> booth    1-360-734-4701
> ------------------------------------------------------
> 
> 
> 
> 
> 
> 
> 
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode




More information about the use-livecode mailing list