Skip to content

Commit

Permalink
samsung j7
Browse files Browse the repository at this point in the history
  • Loading branch information
sattarsh committed Sep 7, 2020
1 parent 0225f65 commit c0c5e38
Show file tree
Hide file tree
Showing 9 changed files with 65 additions and 51 deletions.
4 changes: 3 additions & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ android {
}
buildTypes {
release {
minifyEnabled false
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
Expand All @@ -27,4 +27,6 @@ dependencies {
androidTestImplementation 'androidx.test:runner:1.1.2-alpha01'
androidTestImplementation 'androidx.test:rules:1.1.2-alpha01'
implementation project(':pflockscreen')
implementation 'io.github.inflationx:calligraphy3:3.1.1'
implementation 'io.github.inflationx:viewpump:2.0.3'
}
1 change: 1 addition & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<uses-feature android:name="android.hardware.fingerprint" android:required="false"/>

<application
android:name=".MyApp"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
Expand Down
Binary file added app/src/main/assets/fonts/iran_yekan_regular.ttf
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import com.beautycoder.pflockscreen.security.PFSecurityManager;
import com.beautycoder.pflockscreen.viewmodels.PFPinCodeViewModel;

public class MainActivity extends AppCompatActivity {
public class MainActivity extends MyActivity {

@Override
protected void onCreate(Bundle savedInstanceState) {
Expand All @@ -33,6 +33,7 @@ protected void onCreate(Bundle savedInstanceState) {
public void onCodeCreated(String encodedCode) {
Toast.makeText(MainActivity.this, "Code created", Toast.LENGTH_SHORT).show();
PreferencesSettings.saveToPref(MainActivity.this, encodedCode);
showMainFragment();
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package com.beautycoder.applicationlockscreenexample;

import android.content.Context;

import androidx.appcompat.app.AppCompatActivity;

import io.github.inflationx.viewpump.ViewPumpContextWrapper;


public class MyActivity extends AppCompatActivity {
@Override
protected void attachBaseContext(Context newBase) {
super.attachBaseContext(ViewPumpContextWrapper.wrap(newBase));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
package com.beautycoder.applicationlockscreenexample;

import android.app.Application;

import io.github.inflationx.calligraphy3.CalligraphyConfig;
import io.github.inflationx.calligraphy3.CalligraphyInterceptor;
import io.github.inflationx.viewpump.ViewPump;


public class MyApp extends Application {

@Override
public void onCreate() {
super.onCreate();


ViewPump.init(ViewPump.builder()
.addInterceptor(new CalligraphyInterceptor(
new CalligraphyConfig.Builder()
.setDefaultFontPath("fonts/iran_yekan_regular.ttf")
.setFontAttrId(R.attr.fontPath)
.build()))
.build());


}


}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,11 @@ private void applyConfiguration(PFFLockScreenConfiguration configuration) {

mNextButton.setVisibility(View.INVISIBLE);
mCodeView.setCodeLength(mConfiguration.getCodeLength());
if(mFingerprintHardwareDetected){
mFingerprintButton.setVisibility(View.VISIBLE);
}else {
mFingerprintButton.setVisibility(View.GONE);
}
}

private void initKeyViews(View parent) {
Expand Down
20 changes: 10 additions & 10 deletions pflockscreen/src/main/res/layout/fragment_lock_screen_pf.xml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand All @@ -109,7 +109,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand All @@ -129,7 +129,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand Down Expand Up @@ -157,7 +157,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand All @@ -177,7 +177,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand All @@ -197,7 +197,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand Down Expand Up @@ -225,7 +225,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand All @@ -245,7 +245,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand All @@ -265,7 +265,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand Down Expand Up @@ -311,7 +311,7 @@
android:layout_height="wrap_content"
android:layout_weight="1">

<com.beautycoder.pflockscreen.MyTextView
<TextView
android:textStyle="bold"
android:elevation="4dp"
android:textColor="@color/color_text_btn_key_pf"
Expand Down

0 comments on commit c0c5e38

Please sign in to comment.