Skip to content

Commit 54e9ea7

Browse files
committed
updated version
1 parent ddc8eb3 commit 54e9ea7

3 files changed

Lines changed: 10 additions & 7 deletions

File tree

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
apply plugin: 'com.android.application'
22
apply plugin: 'kotlin-android'
33
android {
4-
compileSdkVersion 29
4+
compileSdkVersion 31
55
defaultConfig {
66
applicationId "com.wesaphzt.privatelocation"
77
minSdkVersion 17
8-
targetSdkVersion 29
8+
targetSdkVersion 31
99
versionCode 4
1010
versionName "1.2"
1111
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"

app/src/main/AndroidManifest.xml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@
2828
android:label="@string/app_name"
2929
android:windowSoftInputMode="adjustPan"
3030
android:launchMode="singleTask"
31-
android:theme="@style/AppTheme.NoActionBar">
31+
android:theme="@style/AppTheme.NoActionBar"
32+
android:exported="true">
3233
<intent-filter>
3334
<action android:name="android.intent.action.MAIN"/>
3435

@@ -41,7 +42,8 @@
4142

4243
<receiver android:name="com.wesaphzt.privatelocation.receivers.ActionReceiver"/>
4344

44-
<receiver android:name=".receivers.BootReceiver">
45+
<receiver android:name=".receivers.BootReceiver"
46+
android:exported="true">
4547
<intent-filter>
4648
<action android:name="android.intent.action.BOOT_COMPLETED"/>
4749
</intent-filter>
@@ -52,7 +54,8 @@
5254
android:label="Service"
5355
android:permission="android.permission.BIND_JOB_SERVICE"/>
5456

55-
<receiver android:name=".widget.LocationWidgetProvider" >
57+
<receiver android:name=".widget.LocationWidgetProvider"
58+
android:exported="true">
5659
<intent-filter>
5760
<action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
5861
</intent-filter>

app/src/main/java/com/wesaphzt/privatelocation/service/LocationProvider.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package com.wesaphzt.privatelocation.service;
22

33
import android.content.Context;
4-
import android.location.Criteria;
4+
import android.location.*;
55
import android.location.Location;
66
import android.location.LocationManager;
77
import android.os.Build;
@@ -34,7 +34,7 @@ public LocationProvider(String name, Context context) {
3434
}
3535

3636
locationManager.addTestProvider(providerName, false, false, false, false, false,
37-
true, true, Criteria.POWER_LOW, Criteria.ACCURACY_FINE);
37+
true, true, android.location.provider.ProviderProperties.POWER_USAGE_LOW, android.location.provider.ProviderProperties.ACCURACY_FINE);
3838
locationManager.setTestProviderEnabled(providerName, true);
3939
} catch (SecurityException e) {
4040
throw new SecurityException("Error applying mock location");

0 commit comments

Comments
 (0)