File tree Expand file tree Collapse file tree 3 files changed +21
-0
lines changed
java/com/programminghoch10/GalaxyWearable Expand file tree Collapse file tree 3 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -8,3 +8,4 @@ Additional features:
88* Disable the forced app update prompt when opening the app
99* Disable the required phone permission
1010* Disable nearby WiFi devices permission
11+ * Disable fine location permission
Original file line number Diff line number Diff line change 11com.programminghoch10.GalaxyWearable.DisableForcedUpdateHook
2+ com.programminghoch10.GalaxyWearable.DisableLocationPermissionHook
23com.programminghoch10.GalaxyWearable.DisableManufacturerCheckHook
34com.programminghoch10.GalaxyWearable.DisableNearbyWifiDevicesPermissionHook
45com.programminghoch10.GalaxyWearable.DisableTelephonyPermissionHook
Original file line number Diff line number Diff line change 1+ package com .programminghoch10 .GalaxyWearable ;
2+
3+ import java .util .ArrayList ;
4+
5+ import de .robv .android .xposed .IXposedHookLoadPackage ;
6+ import de .robv .android .xposed .XposedHelpers ;
7+ import de .robv .android .xposed .callbacks .XC_LoadPackage ;
8+
9+ public class DisableLocationPermissionHook implements IXposedHookLoadPackage {
10+ @ SuppressWarnings ("unchecked" )
11+ @ Override
12+ public void handleLoadPackage (XC_LoadPackage .LoadPackageParam lpparam ) throws Throwable {
13+ if (!lpparam .packageName .equals ("com.samsung.android.app.watchmanager" )) return ;
14+ Class <?> PermissionsUtilsClass =
15+ XposedHelpers .findClass ("com.samsung.android.app.watchmanager.setupwizard.permission.PermissionUtils" , lpparam .classLoader );
16+ ArrayList <String > INITIAL_PERMISSION = (ArrayList <String >) XposedHelpers .getStaticObjectField (PermissionsUtilsClass , "INITIAL_PERMISSION" );
17+ INITIAL_PERMISSION .remove ("android.permission.ACCESS_FINE_LOCATION" );
18+ }
19+ }
You can’t perform that action at this time.
0 commit comments