(update)(guide)how to add lockscreeneffect(4.4.2~~4.4.4)

qwerty123258

Senior Member
Nov 4, 2014
269
288
0
Seoul
need
SecSettings.apk(4.4.2~~4.4.4) Keyguard.apk(4.4.2)
note 4 Keyguard.apk(4.4.4) note 4 Secvisualeffect.jar(4.4.4) note 4 libIndigoDiffusionEffect.so(4.4.4)

Important
4.4.4 must use note 4 keyguard and secvisualeffect.jar

first Secsettings.apk decompile

go to smali/com/android/settings/LcockScreenMenuSettings.smali

ctrl + f
removeUnsupportedEffect(Ljava/lang/CharSequence;)V

above line const-string vx, "3"

3 means number of lockscreeneffect

so.. 3 change 8(4.4.4 change 16)

and..

go to res/values/arrays.xml

ctrl + f <string-array name="lock_screen_unlock_effect_entries">

change to

<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>watercolor_effect</item>
<item>blind_effect</item>
<item>oil_paint</item>
<item>simple_ripple</item>
</string-array>

for 4.4.4
<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>watercolor_effect</item>
<item>blind_effect</item>
<item>oil_paint</item>
<item>simple_ripple</item>
<item>brilliant_ring</item>
<item>brilliant_cut</item>
<item>montblanc</item>
<item>seasonal</item>
<item>spring</item>
<item>summer</item>
<item>fall</item>
<item>winter</item>
</string-array>

ctrl + f <string-array name="lock_screen_unlock_effect_values">

change to

<string-array name="lock_screen_unlock_effect_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
</string-array>

for 4.4.4
<string-array name="lock_screen_unlock_effect_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>10</item>
<item>85</item>
<item>81</item>
<item>82</item>
<item>83</item>
<item>84</item>
</string-array>

end compile

second Keyguard.apk decompile

go to smali/com/android/keyguard/KeyguardViewMediator

ctrl + f .method private checkUnlockEffectVarification()V

under ~~~

const/4 v4, 0x(number) change to 0x0

end compile

third only 4.4.4
libIndigoDiffusionEffect.so push system and reboot


final~

push system and reboot~


Add for Note 4 Settings User

go to smali/com/android/settings/PreviewFragment.smali

1. seach populateUnlockEffectsOptions()V

Code:
    .line 91
    const-string v1, "UnlockEffect"

    iget-object v2, p0, Lcom/android/settings/PreviewFragment;->menuName:Ljava/lang/String;

    invoke-virtual {v1, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 92
    invoke-virtual {p0}, Lcom/android/settings/PreviewFragment;->populateUnlockEffectsOptions()V
change to

Code:
    .line 91
    const-string v1, "UnlockEffect"

    iget-object v2, p0, Lcom/android/settings/PreviewFragment;->menuName:Ljava/lang/String;

    invoke-virtual {v1, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 101
    const-string v1, "UnlockEffect"

    iget-object v2, p0, Lcom/android/settings/PreviewFragment;->menuName:Ljava/lang/String;

    invoke-virtual {v1, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 102
    invoke-virtual {p0}, Landroid/app/Fragment;->getResources()Landroid/content/res/Resources;

    move-result-object v1

    const v2, 0x7f0a0010  <<lock_screen_unlock_effect_entries

    invoke-virtual {v1, v2}, Landroid/content/res/Resources;->getStringArray(I)[Ljava/lang/String;

    move-result-object v1

    sput-object v1, Lcom/android/settings/PreviewFragment;->mModeItem:[Ljava/lang/String;

    .line 103
    invoke-virtual {p0}, Landroid/app/Fragment;->getResources()Landroid/content/res/Resources;

    move-result-object v1

    const v2, 0x7f0a0012  <<<lock_screen_unlock_effect_values

    invoke-virtual {v1, v2}, Landroid/content/res/Resources;->getStringArray(I)[Ljava/lang/String;

    move-result-object v1

    iput-object v1, p0, Lcom/android/settings/PreviewFragment;->dbValues:[Ljava/lang/String;

    .line 104
    const/16 v1, 0xf

    new-array v1, v1, [I

    fill-array-data v1, :array_3

    iput-object v1, p0, Lcom/android/settings/PreviewFragment;->backgroundImage:[I

    goto/16 :goto_0
2. search .end method
Code:
    .line 113
    :array_2
    .array-data 4
        0x7f020102
        0x7f0200ff
        0x7f020100
        0x7f020101
        0x7f0200fe
        0x7f020103
    .end array-data
.end method
add the code (red color)


Code:
    .line 113
    :array_2
    .array-data 4
        0x7f020102
        0x7f0200ff
        0x7f020100
        0x7f020101
        0x7f0200fe
        0x7f020103
    .end array-data

[COLOR="Magenta"]    :array_3
    .array-data 4
        0x7f0205f5 << no effect preview image
        0x7f0205f7 << ripple
        0x7f0208e1 << light
        0x7f0205f6
        0x7f0205f9
        0x7f0208df  <<< blind
        0x7f0205f8 <<< slmpleripple
        0x7f0205f2
        0x7f0208e0  <<diamond
        0x7f0205f4 <<< montblanc
        0x7f020105  <<seansonal
        0x7f020106
        0x7f020107
        0x7f020104
        0x7f020108
    .end array-data[/COLOR]
.end method
2. go to res/values/arrays.xml

ctrl + f <string-array name="lock_screen_unlock_effect_entries">

change to

<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>watercolor_effect</item>
<item>blind_effect</item>
<item>oil_paint</item>
<item>simple_ripple</item>
<item>brilliant_ring</item>
<item>brilliant_cut</item>
<item>montblanc</item>
<item>seasonal</item>
<item>spring</item>
<item>summer</item>
<item>fall</item>
<item>winter</item>
</string-array>

ctrl + f <string-array name="lock_screen_unlock_effect_values">

change to

<string-array name="lock_screen_unlock_effect_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>10</item>
<item>85</item>
<item>81</item>
<item>82</item>
<item>83</item>
<item>84</item>
</string-array>
 

Attachments

Last edited:

maxx35000

Senior Member
Jan 14, 2012
1,517
2,821
0
Rennes
need
SecSettings.apk(4.4.2~~4.4.4) Keyguard.apk(4.4.2)
note 4 Keyguard.apk(4.4.4) note 4 Secvisualeffect.jar(4.4.4) note 4 libIndigoDiffusionEffect.so(4.4.4)

Important
4.4.4 must use note 4 keyguard and secvisualeffect.jar

first Secsettings.apk decompile

go to smali/com/android/settings/LcockScreenMenuSettings.smali

ctrl + f
removeUnsupportedEffect(Ljava/lang/CharSequence;)V

above line const-string vx, "3"

3 means number of lockscreeneffect

so.. 3 change 8(4.4.4 change 16)

and..

go to res/values/arrays.xml

ctrl + f <string-array name="lock_screen_unlock_effect_entries">

change

<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>watercolor_effect</item>
<item>blind_effect</item>
<item>oil_paint</item>
<item>simple_ripple</item>
</string-array>

4.4.4
<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>watercolor_effect</item>
<item>blind_effect</item>
<item>oil_paint</item>
<item>simple_ripple</item>
<item>brilliant_ring</item>
<item>brilliant_cut</item>
<item>montblanc</item>
<item>seasonal</item>
<item>spring</item>
<item>summer</item>
<item>fall</item>
<item>winter</item>
</string-array>

ctrl + f <string-array name="lock_screen_unlock_effect_values">

change

<string-array name="lock_screen_unlock_effect_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
</string-array>

4.4.4
<string-array name="lock_screen_unlock_effect_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>10</item>
<item>85</item>
<item>81</item>
<item>82</item>
<item>83</item>
<item>84</item>
</string-array>

end compile

second Keyguard.apk decompile

go to smali/com/android/keyguard/KeyguardViewMediator

ctrl + f .method private checkUnlockEffectVarification()V

under ~~~

const/4 v4, 0x(number) change to 0x0

end compile

third only 4.4.4
libIndigoDiffusionEffect.so push system and reboot


final~

push system and reboot~
hi man thank's a lot for this

i need your advise i mod my file for SM-G7105 it Work but i have some issue everytime i reboot my phone the effect that is snt to lock screen reverts back to none .... can you help me ? i am on 4.4.2 thank's
 
Last edited:

qwerty123258

Senior Member
Nov 4, 2014
269
288
0
Seoul
hi man thank's a lot for this

i need your advise i mod my file for SM-G7105 it Work but i have some issue everytime i reboot my phone the effect that is snt to lock screen reverts back to none .... can you help me ? i am on 4.4.2 thank's
look my thread

second Keyguard.apk decompile

go to smali/com/android/keyguard/KeyguardViewMediator

ctrl + f .method private checkUnlockEffectVarification()V

under ~~~

const/4 v4, 0x(number) change to 0x0

end compile
 
  • Like
Reactions: maxx35000

maxx35000

Senior Member
Jan 14, 2012
1,517
2,821
0
Rennes
look my thread

second Keyguard.apk decompile

go to smali/com/android/keyguard/KeyguardViewMediator

ctrl + f .method private checkUnlockEffectVarification()V

under ~~~

const/4 v4, 0x(number) change to 0x0

end compile
can you tell me where in this code i dont understand

Code:
.method private checkUnlockEffectVarification()V
    .locals 5

    .prologue
    const/4 v2, 0x0

    const/4 v1, 0x1

    .line 1644
    iget-object v0, p0, Lcom/android/keyguard/KeyguardViewMediator;->mContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    const-string v3, "lockscreen_ripple_effect"

    invoke-static {v0, v3, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

    move-result v3

    .line 1648
    invoke-static {v3}, Lcom/android/keyguard/sec/KeyguardEffectViewMain;->isLockScreenEffect(I)Z

    move-result v0

    if-nez v0, :cond_3

    move v0, v1

    .line 1657
    :goto_0
    const/4 v4, 0x5

    if-ne v3, v4, :cond_0

    move v0, v1

    .line 1672
    :cond_0
    const/4 v4, 0x2

    if-ne v3, v4, :cond_1

    move v0, v1

    .line 1678
    :cond_1
    if-ne v0, v1, :cond_2

    .line 1679
    iget-object v0, p0, Lcom/android/keyguard/KeyguardViewMediator;->mContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    const-string v1, "lockscreen_ripple_effect"

    invoke-static {v0, v1, v2}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z

    .line 1681
    :cond_2
    return-void

    :cond_3
    move v0, v2

    goto :goto_0
.end method
 

qwerty123258

Senior Member
Nov 4, 2014
269
288
0
Seoul
can you tell me where in this code i dont understand

Code:
.method private checkUnlockEffectVarification()V
    .locals 5

    .prologue
    const/4 v2, 0x0

    const/4 v1, 0x1

    .line 1644
    iget-object v0, p0, Lcom/android/keyguard/KeyguardViewMediator;->mContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    const-string v3, "lockscreen_ripple_effect"

    invoke-static {v0, v3, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I

    move-result v3

    .line 1648
    invoke-static {v3}, Lcom/android/keyguard/sec/KeyguardEffectViewMain;->isLockScreenEffect(I)Z

    move-result v0

    if-nez v0, :cond_3

    move v0, v1

    .line 1657
    :goto_0
    const/4 v4, 0x5

    if-ne v3, v4, :cond_0

    move v0, v1

    .line 1672
    :cond_0
    const/4 v4, 0x2

    if-ne v3, v4, :cond_1

    move v0, v1

    .line 1678
    :cond_1
    if-ne v0, v1, :cond_2

    .line 1679
    iget-object v0, p0, Lcom/android/keyguard/KeyguardViewMediator;->mContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    const-string v1, "lockscreen_ripple_effect"

    invoke-static {v0, v1, v2}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z

    .line 1681
    :cond_2
    return-void

    :cond_3
    move v0, v2

    goto :goto_0
.end method
const/4 v4, 0x5 change to const/4 v4, 0x0

const/4 v4, 0x2 change to const/4 v4, 0x0
 
  • Like
Reactions: maxx35000

jazzespresso

Senior Member
Jul 24, 2012
2,845
1,647
0
NYC-USA
it is intersting that I was looking for some way to get additional unlock effect for my Note 8 (4.4.2), and then run into your thread.. I knew this was S3 thread, but thought let me give a try, so followed your instruction as much as I can considering that two different devices, strangely enough I can able to get only one additional unlock effect "Particle effect", but nothing else.
I know the fact that, Note 8's keyguard.apk has following effects coded, but only first three is enabled (settings --> lockscreen--> unlock effect lists only first three)
<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>Lens Flare effect</item>
<item>WaterColor effect</item>
<item>Blind Circle effect</item>
<item>MassRipple effect</item>
<item>MassTension effect</item>
</string-array>​

anyway, still a progress....I just thought I should let you know that I am thankful for this post....now the challenge I have how to enable all these additional effects....:confused:
 

qwerty123258

Senior Member
Nov 4, 2014
269
288
0
Seoul
it is intersting that I was looking for some way to get additional unlock effect for my Note 8 (4.4.2), and then run into your thread.. I knew this was S3 thread, but thought let me give a try, so followed your instruction as much as I can considering that two different devices, strangely enough I can able to get only one additional unlock effect "Particle effect", but nothing else.
I know the fact that, Note 8's keyguard.apk has following effects coded, but only first three is enabled (settings --> lockscreen--> unlock effect lists only first three)
<string-array name="lock_screen_unlock_effect_entries">
<item>None</item>
<item>Ripple effect</item>
<item>Light effect</item>
<item>Particle effect</item>
<item>Lens Flare effect</item>
<item>WaterColor effect</item>
<item>Blind Circle effect</item>
<item>MassRipple effect</item>
<item>MassTension effect</item>
</string-array>​

anyway, still a progress....I just thought I should let you know that I am thankful for this post....now the challenge I have how to enable all these additional effects....:confused:
language problem
choice english(uk)