GetDisplayModes() dont work in APK Compiler 4.4 Pro

Report any Hollywood bugs here
Post Reply
P_B
Posts: 27
Joined: Sat Sep 15, 2018 4:28 pm

GetDisplayModes() dont work in APK Compiler 4.4 Pro

Post by P_B »

Hello,

With hollywood 10, when running On Nokia 3.1 Android 9 and 10, I get the message : no display mode found
Current line 6 in function Getdisplaymodes

With APK Compiler 3 Pro, I got only one result 720 x 1154.

The CanonizePath function also returns an error in APK.

Could you check, please.

Thank you.
User avatar
airsoftsoftwair
Posts: 5615
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: GetDisplayModes() dont work in APK Compiler 4.4 Pro

Post by airsoftsoftwair »

P_B wrote: Tue Jul 23, 2024 1:27 pm With hollywood 10, when running On Nokia 3.1 Android 9 and 10, I get the message : no display mode found
True, this is a bug. Fixed now.

Code: Select all

- Fix [Android]: GetDisplayModes() didn't return the display's screen mode
P_B wrote: Tue Jul 23, 2024 1:27 pm With APK Compiler 3 Pro, I got only one result 720 x 1154.
That is correct because mobile devices only have one physical resolution (unlike monitors) so GetDisplayModes() will only ever return a single display mode.
P_B wrote: Tue Jul 23, 2024 1:27 pm The CanonizePath function also returns an error in APK.
Need more details here. What exactly do you get and what do you expect?
P_B
Posts: 27
Joined: Sat Sep 15, 2018 4:28 pm

Re: GetDisplayModes() dont work in APK Compiler 4.4 Pro

Post by P_B »

Thank you for fixing GetDisplayModes() for APK.

CanonizePath is not protected against empty strings for all versions.

Code: Select all

directory$=GetProgramDirectory()

directory$=""

p$ = CanonizePath(directory$)
GetProgramDirectory() on APK returns an empty string, and therefore CanonizePath interrupts the execution of the current program, only on Android.

Thank you.
User avatar
airsoftsoftwair
Posts: 5615
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: GetDisplayModes() dont work in APK Compiler 4.4 Pro

Post by airsoftsoftwair »

P_B wrote: Thu Jul 25, 2024 8:00 pm GetProgramDirectory() on APK returns an empty string, and therefore CanonizePath interrupts the execution of the current program, only on Android.
Yeah, on Android everything is heavily sandboxed so it's not really possible to get the program directory as on desktop operating systems. Just make sure you don't call GetProgramDirectory() when on Android because it doesn't make any sense anyway ;)
P_B
Posts: 27
Joined: Sat Sep 15, 2018 4:28 pm

Re: GetDisplayModes() dont work in APK Compiler 4.4 Pro

Post by P_B »

It was to test the portability of the programs in Hollywood.

Thank you for your help.
Post Reply