[Interest] How to distinguish from iPhone screen type with Qt/Qml
maitai
maitai at virtual-winds.org
Mon Dec 3 14:02:52 CET 2018
Hi,
Here I call an objective C function at startup, which stores a global
boolean var
if ( [(NSString*)[UIDevice currentDevice].model hasPrefix:@"iPad"] )
isIphone = false;
else
isIphone = true;
Philippe.
Le 03-12-2018 13:47, ekke a écrit :
> Hi Nuno,
> one way is to detect from pixels
>
> perhaps this gives you an idea:
> https://github.com/ekke/c2gQtWS_x/blob/master/cpp/unsafearea.cpp
>
> later will use mobile device types to better distinguish between
> different models
> best overview I found here: https://gist.github.com/adamawolf/3048717
>
> ekke
> Am 03.12.18 um 13:34 schrieb Nuno Santos:
>> Hi,
>>
>> I’m trying to make my iOS apps ready for iPhone X screen as well as
>> the new iPads.
>>
>> How can I distinguish the screen types? Can I do that directly from
>> Qml? How?
>>
>> Thanks in advance!
>>
>> Regards,
>>
>> Nuno
>> _______________________________________________
>> Interest mailing list
>> Interest at lists.qt-project.org
>> https://lists.qt-project.org/listinfo/interest
>
> _______________________________________________
> Interest mailing list
> Interest at lists.qt-project.org
> https://lists.qt-project.org/listinfo/interest
More information about the Interest
mailing list