GLBasic forum

Main forum => GLBasic - en => Topic started by: Paul Smith on 2017-Jul-08

Title: Android GPS disable
Post by: Paul Smith on 2017-Jul-08
Hi Guys
I don't have GPS switch on
and my builds always advise me to turn it on when executed.
i guessed this would have been in the manifest.xml and just needed removing
 <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
but its not

any ideas on how to kill this?

also not that important but I'm building a new app with a resolution of 720x1280, under testing with android my finger mouse reports locations normally, but windows x is normal 0-720 but y is 0-1092 and wont go any higher (using mouseatate). The photo show 1068 must have knocked it when grabbing.
Title: Re: Android GPS disable
Post by: spacefractal on 2017-Jul-09
im means im fixed that long time ago, if you using Android Extras. Its should not touch GPS anymore, if its does not have that permission. Make sure you have newest Android Extras.

Also some android devices reserve pixels for the onscreen buttons, which cannot covered up by the game for some devices. So here you will simply return the resolution that does not cover up the buttons. Fullscreen feature was added in Android 5 (or was its Android 6?), but its might not allways works. But not in Android 4.

Again, you need Android Extras and/or a least glbasic v14 with Android Extras for doing that.
Title: Re: Android GPS disable
Post by: erico on 2017-Jul-09
Yep, the resolution thing is probably related to those on screen controls. It´s very non standard, I recall finding about 3 or 4 different sizes of bars some years ago.
Title: Re: Android GPS disable
Post by: Paul Smith on 2017-Jul-09
I'm using GLBasic IDE, Version: 14.497.
I thought android extras was now built in with v14 or do I have to update it another way?

the screen on android is fine it's the windows mouse that stop at 1092.
Title: Re: Android GPS disable
Post by: spacefractal on 2017-Jul-09
have you downloaded the newst android extras from the top posts?
Title: Re: Android GPS disable
Post by: Paul Smith on 2017-Jul-09
just unpacked this version
Android Extras 3.01.2 and iOS9 iOS/TVos projects:
I guess this is the right one.

Its cleared the GPS warning. and also saved 100kb in APK size
Title: Re: Android GPS disable
Post by: Qedo on 2017-Jul-10
I need help. I want to install Android Extras 3.01.2 and then I downloaded it.
Is this just enough to replace the original Android folder under "Compiler-->platform" or do I have to do something else?
Sorry i am looking into the forum but i just increased the confusion.
Thank you
Ciao
Title: Re: Android GPS disable
Post by: Paul Smith on 2017-Jul-10
all I did was exit Glbasic
goto
C:\Program Files (x86)\GLBasic_v14\Compiler\platform\android
and dragged all the new  files / folders in like for like.
takes a few minutes to unpack and copy plus overwrite warnings.
but this worked for me.



 
Title: Re: Android GPS disable
Post by: adaz on 2018-Feb-16
Also some android devices reserve pixels for the onscreen buttons, which cannot covered up by the game for some devices. So here you will simply return the resolution that does not cover up the buttons. Fullscreen feature was added in Android 5 (or was its Android 6?), but its might not allways works. But not in Android 4.

Again, you need Android Extras and/or a least glbasic v14 with Android Extras for doing that.

Dear Space Fractal,
Can you please help in this? My device doesn't allow me to touch the very bottom of the screen. Is it because the virtual buttons bar? Can I somehow override it? I use api-22.

Thanks!

Adam
Title: Re: Android GPS disable
Post by: MrPlow on 2018-Feb-18
Hey Paul

I had a that GPS notice issue for a while and after SF letting me know it was an issue with the library I had I edited it and fixed it :)

If I recall correctly I commented out line in SDLactivity.java

   // Create GPS instance
      // androidGPS = new AndroidGPS(this);

Edit : But I can see you sorted it with new files altogether... :)

Title: Re: Android GPS disable
Post by: spacefractal on 2018-Feb-18
this was fixed on one of the last AndroidExtras version before im stoppede..... its should check if GPS string was set in AndroidManifest or not, and then simply just skip the code..... In a older version, just uncomment the commend by MRPlow post.

Android on some devices might reserve some screen, when its have virtual buttons. That is normal and is a system feature.