Skip to content

Fix for Android 14 #30

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 10 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
local.properties

# Do not upload libs to Github
/private-libs
/private-libs
8 changes: 4 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id 'com.android.application' version '7.1.2' apply false
id 'com.android.library' version '7.1.2' apply false
id 'com.android.application' version '8.3.1' apply false
id 'com.android.library' version '8.3.1' apply false
id 'org.jetbrains.kotlin.android' version '1.6.10' apply false
}

Expand All @@ -13,8 +13,8 @@ configure ([project(':faceunlock'), project(':universalauth-xposed')]) {
afterEvaluate {
android {
defaultConfig {
versionCode 18
versionName "1.8"
versionCode 1009000
versionName "1.9.0"
}
}
}
Expand Down
5 changes: 3 additions & 2 deletions faceunlock-backend/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ plugins {
}

android {
compileSdk 32
namespace "ax.nd.faceunlock.backend"
compileSdk 35

defaultConfig {
minSdk 29
targetSdk 32
targetSdk 35

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
consumerProguardFiles "consumer-rules.pro"
Expand Down
5 changes: 3 additions & 2 deletions faceunlock-framework_stub/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ plugins {
}

android {
compileSdk 32
namespace "ax.nd.faceunlock.framework_stub"
compileSdk 35

defaultConfig {
minSdk 29
targetSdk 32
targetSdk 35

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
consumerProguardFiles "consumer-rules.pro"
Expand Down
6 changes: 4 additions & 2 deletions faceunlock/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@ plugins {
}

android {
compileSdk 31
namespace "ax.nd.faceunlock"
compileSdk 35

defaultConfig {
applicationId "ax.nd.faceunlock"
minSdk 29
targetSdk 31
targetSdk 35

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
Expand All @@ -29,6 +30,7 @@ android {
}
buildFeatures {
viewBinding true
aidl true
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ class ChooseLibsViewModel : ViewModel() {
companion object {
private val TAG = ChooseLibsViewModel::class.simpleName

private const val IPFS_GATEWAY = "https://cloudflare-ipfs.com"
private const val IPFS_GATEWAY = "https://ipfs.io/ipfs/"
private const val LIBS_CID = "QmQNREjjXTQBDpd69gFqEreNi1dV91eSGQByqi5nXU3rBt"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public void onCreate() {
IntentFilter intentFilter = new IntentFilter();
intentFilter.addAction(Intent.ACTION_USER_PRESENT);
intentFilter.setPriority(IntentFilter.SYSTEM_HIGH_PRIORITY);
registerReceiver(mReceiver, intentFilter, null, null);
registerReceiver(mReceiver, intentFilter, null, null, RECEIVER_EXPORTED);
getPackageManager().setComponentEnabledSetting(new ComponentName(this, SetupFaceIntroActivity.class),
PackageManager.COMPONENT_ENABLED_STATE_ENABLED,
PackageManager.DONT_KILL_APP);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ public void onCreate() {
intentFilter.addAction(Intent.ACTION_SCREEN_OFF);
intentFilter.addAction(Intent.ACTION_USER_PRESENT);
intentFilter.setPriority(IntentFilter.SYSTEM_HIGH_PRIORITY);
registerReceiver(mReceiver, intentFilter);
registerReceiver(mReceiver, intentFilter, RECEIVER_EXPORTED);
if (Util.DEBUG) {
Log.d(TAG, "OnCreate end");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ class LockscreenFaceAuthService : AccessibilityService(), FaceAuthServiceCallbac
prefs.failedUnlockAttempts.set(0)
}
}
registerReceiver(unlockReceiver, intentFilter)
registerReceiver(unlockReceiver, intentFilter, RECEIVER_EXPORTED)
}

private fun unregisterUnlockReceiver() {
Expand Down Expand Up @@ -148,7 +148,7 @@ class LockscreenFaceAuthService : AccessibilityService(), FaceAuthServiceCallbac
doubleCheckLockscreenState()
}
}
registerReceiver(lockStateReceiver, intentFilter)
registerReceiver(lockStateReceiver, intentFilter, RECEIVER_EXPORTED)
}

private fun registerEarlyUnlockReceiver() {
Expand All @@ -165,7 +165,7 @@ class LockscreenFaceAuthService : AccessibilityService(), FaceAuthServiceCallbac
}
}
}
registerReceiver(lockStateReceiver, intentFilter)
registerReceiver(lockStateReceiver, intentFilter, RECEIVER_EXPORTED)
}

private fun unregisterLockStateReceiver() {
Expand Down Expand Up @@ -231,10 +231,10 @@ class LockscreenFaceAuthService : AccessibilityService(), FaceAuthServiceCallbac
textViewAnimator = textView?.animate()
?.alpha(0f)
?.setListener(object : Animator.AnimatorListener {
override fun onAnimationStart(p0: Animator?) {}
override fun onAnimationEnd(p0: Animator?) = onTextViewAnimationEnd()
override fun onAnimationCancel(p0: Animator?) {}
override fun onAnimationRepeat(p0: Animator?) {}
override fun onAnimationStart(p0: Animator) {}
override fun onAnimationEnd(p0: Animator) = onTextViewAnimationEnd()
override fun onAnimationCancel(p0: Animator) {}
override fun onAnimationRepeat(p0: Animator) {}
})
?.setStartDelay(delay.toLong())
?.setDuration(300)
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
7 changes: 4 additions & 3 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#Fri Mar 11 23:32:25 EST 2022
distributionBase=GRADLE_USER_HOME
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading