[Galaxy Y GT-S5360 Android Development] d3cka:
before proceed this guide, you must download this files : android.policy.zip, Lidroid-res.apk and Lidroid-Parts.

please notice that this guide based on stock deodex DXLF1 firmware

decompile your android.policy.jar

unzip android.policy.zip that u have download before

now copy lidroid folder from android.policy.zip\android.policy\smali to your android.policy.jar\smali

copy lidroid folder from android.policy.zip[/B]\android.policy\smali\com to your android.policy.jar\smali\com

copy CyanogenLockScreen.smali, CyanogenLockScreen$1.smali, CyanogenLockScreen$2.smali, CyanogenLockScreen$3.smali, CyanogenLockScreen$4.smali, CyanogenLockScreen$5.smali, CyanogenLockScreen$Status.smali and KeyguardUpdateMonitor$MediaStateCallback.smali from android.policy.zip\android.policy\smali\com\android\internal\policy\impl to your android.policy.jar\smali\com\android\internal\policy\impl

now edit KeyguardUpdateMonitor.smali from your android.policy.jar\smali\com\android\internal\policy\impl

find this (line 6)

# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$LockscreenWallpaperCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$PcwInfoChangeCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$AirplaneModeChangeCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$SimStateCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$InfoCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$ConfigurationChangeCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$SimArgs;
}
.end annotation

add this line "Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;," below this line "Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$AirplaneModeChangeCallback;,"

after :

# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$LockscreenWallpaperCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$PcwInfoChangeCallback;,
[COLOR="blue"] Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$AirplaneModeChangeCallback;,[/COLOR]
[COLOR="Red"]Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;,[/COLOR]
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$SimStateCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$InfoCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$ConfigurationChangeCallback;,
Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$SimArgs;
}
.end annotation

find this (line 160)

.field private mLockscreenWallpaperDrawable:Landroid/graphics/drawable/Drawable;

add this line below it

[COLOR="Red"].field private mMediaCallbacks:Ljava/util/ArrayList;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/ArrayList",
"<",
"Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;",
">;"
}
.end annotation
.end field[/COLOR]

after :

.field private mLockscreenWallpaperDrawable:Landroid/graphics/drawable/Drawable;
[COLOR="red"].field private mMediaCallbacks:Ljava/util/ArrayList;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/ArrayList",
"<",
"Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;",
">;"
}
.end annotation
.end field[/COLOR]

find this (line 202)

.field private mWallpaperModeValue:I

add this line below it

[COLOR="Red"].field private timezone:Ljava/lang/String;[/COLOR]

after :

.field private mWallpaperModeValue:I

[COLOR="red"].field private timezone:Ljava/lang/String;[/COLOR]

note: if u already has this line .field private timezone:Ljava/lang/String; below .field private mWallpaperModeValue:I , u may continue to next step.

find this (line 1772)

.method private handleSimStateChange(Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$SimArgs;)V

add this line above it

[COLOR="red"].method private handleMediaUpdate(IILandroid/net/Uri;)V
.locals 5
.parameter "isPlaying"
.parameter "isStop"
.parameter "mediaUri"

.prologue
const/4 v4, 0x0

const/4 v3, 0x1

.line 467
if-ne p1, v3, :cond_0

move v0, v3

.line 468
.local v0, bIsPlaying:Z
:goto_0
if-ne p2, v3, :cond_1

move v1, v3

.line 470
.local v1, bIsStop:Z
:goto_1
const/4 v2, 0x0

.local v2, i:I
:goto_2
iget-object v3, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->mMediaCallbacks:Ljava/util/ArrayList;

invoke-virtual {v3}, Ljava/util/ArrayList;->size()I

move-result v3

if-ge v2, v3, :cond_2

.line 471
iget-object v3, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->mMediaCallbacks:Ljava/util/ArrayList;

invoke-virtual {v3, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

move-result-object v3

check-cast v3, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;

invoke-interface {v3, v0, v1, p3}, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;->onMediaUpdated(ZZLandroid/net/Uri;)V

.line 470
add-int/lit8 v2, v2, 0x1

goto :goto_2

.end local v0 #bIsPlaying:Z
.end local v1 #bIsStop:Z
.end local v2 #i:I
:cond_0
move v0, v4

.line 467
goto :goto_0

.restart local v0 #bIsPlaying:Z
:cond_1
move v1, v4

.line 468
goto :goto_1

.line 473
.restart local v1 #bIsStop:Z
.restart local v2 #i:I
:cond_2
return-void
.end method[/COLOR]

after :

[COLOR="red"].method private handleMediaUpdate(IILandroid/net/Uri;)V
.locals 5
.parameter "isPlaying"
.parameter "isStop"
.parameter "mediaUri"

.prologue
const/4 v4, 0x0

const/4 v3, 0x1

.line 467
if-ne p1, v3, :cond_0

move v0, v3

.line 468
.local v0, bIsPlaying:Z
:goto_0
if-ne p2, v3, :cond_1

move v1, v3

.line 470
.local v1, bIsStop:Z
:goto_1
const/4 v2, 0x0

.local v2, i:I
:goto_2
iget-object v3, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->mMediaCallbacks:Ljava/util/ArrayList;

invoke-virtual {v3}, Ljava/util/ArrayList;->size()I

move-result v3

if-ge v2, v3, :cond_2

.line 471
iget-object v3, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->mMediaCallbacks:Ljava/util/ArrayList;

invoke-virtual {v3, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

move-result-object v3

check-cast v3, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;

invoke-interface {v3, v0, v1, p3}, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$MediaStateCallback;->onMediaUpdated(ZZLandroid/net/Uri;)V

.line 470
add-int/lit8 v2, v2, 0x1

goto :goto_2

.end local v0 #bIsPlaying:Z
.end local v1 #bIsStop:Z
.end local v2 #i:I
:cond_0
move v0, v4

.line 467
goto :goto_0

.restart local v0 #bIsPlaying:Z
:cond_1
move v1, v4

.line 468
goto :goto_1

.line 473
.restart local v1 #bIsStop:Z
.restart local v2 #i:I
:cond_2
return-void
.end method[/COLOR]

.method private handleSimStateChange(Lcom/android/internal/policy/impl/KeyguardUpdateMonitor$SimArgs;)V

find this (line 2135)

.method public getFailedAttempts()I

add this line above it

.method public getChangedTimeZone()Ljava/lang/String;
.locals 1

.prologue
.line 1131
iget-object v0, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->timezone:Ljava/lang/String;

return-object v0
.end method

after :

[COLOR="red"].method public getChangedTimeZone()Ljava/lang/String;
.locals 1

.prologue
.line 1131
iget-object v0, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->timezone:Ljava/lang/String;

return-object v0
.end method[/COLOR]

.method public getFailedAttempts()I

find this (line 2315)

.method public isDevicePluggedIn()Z

add this line above it

.method public isDeviceCharged()Z
.locals 2

.prologue
.line 866
iget v0, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->mBatteryLevel:I

const/16 v1, 0x64

if-lt v0, v1, :cond_0

const/4 v0, 0x1

:goto_0
return v0

:cond_0
const/4 v0, 0x0

goto :goto_0
.end method

after

[COLOR="red"].method public isDeviceCharged()Z
.locals 2

.prologue
.line 866
iget v0, p0, Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;->mBatteryLevel:I

const/16 v1, 0x64

if-lt v0, v1, :cond_0

const/4 v0, 0x1

:goto_0
return v0

:cond_0
const/4 v0, 0x0

goto :goto_0
.end method[/COLOR]

.method public isDevicePluggedIn()Z

close and save.

now edit LockPatternKeyguardView.smali from your android.policy.jar\smali\com\android\internal\policy\impl

find this (line 2007)

.method createLockScreen()Landroid/view/View;

below this line

.prologue

.line 892

add this line

[COLOR="red"]const/4 v2, 0x0

const/4 v0, 0x0

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

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

move-result-object v3

const-string v4, "lockscreen_style_pref"

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

move-result v0

const/4 v2, 0x1

if-eq v2, v0, :cond_3

const/4 v2, 0x2

if-eq v2, v0, :cond_3

const/4 v2, 0x3

if-eq v2, v0, :cond_3

const/4 v2, 0x4

if-eq v2, v0, :cond_3

const/4 v2, 0x5

if-eq v2, v0, :cond_3

if-eqz v0, :cond_0

.line 869
const/4 v2, 0x0

const/4 v0, 0x0

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

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

move-result-object v3

const-string v4, "lockscreen_style_pref"

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

move-result v0

const/4 v2, 0x6

if-eq v2, v0, :cond_2

const/4 v2, 0x7

if-eq v2, v0, :cond_1

:cond_0
new-instance v0, Lcom/android/internal/policy/impl/LockScreen;

iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;

iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;

iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/LockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

goto :goto_0

:cond_1
new-instance v0, Lcom/android/internal/policy/impl/LockScreen;

iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;

iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;

iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/LockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

goto :goto_0

:cond_2[/COLOR]

after :

.method createLockScreen()Landroid/view/View;
.registers 7

.prologue
.line 892

[COLOR="red"]const/4 v2, 0x0

const/4 v0, 0x0

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

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

move-result-object v3

const-string v4, "lockscreen_style_pref"

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

move-result v0

const/4 v2, 0x1

if-eq v2, v0, :cond_3

const/4 v2, 0x2

if-eq v2, v0, :cond_3

const/4 v2, 0x3

if-eq v2, v0, :cond_3

const/4 v2, 0x4

if-eq v2, v0, :cond_3

const/4 v2, 0x5

if-eq v2, v0, :cond_3

if-eqz v0, :cond_0

.line 869
const/4 v2, 0x0

const/4 v0, 0x0

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

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

move-result-object v3

const-string v4, "lockscreen_style_pref"

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

move-result v0

const/4 v2, 0x6

if-eq v2, v0, :cond_2

const/4 v2, 0x7

if-eq v2, v0, :cond_1

:cond_0
new-instance v0, Lcom/android/internal/policy/impl/LockScreen;

iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;

iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;

iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/LockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

goto :goto_0

:cond_1
new-instance v0, Lcom/android/internal/policy/impl/LockScreen;

iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;

iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;

iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/LockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

goto :goto_0

:cond_2[/COLOR]

fine this (line 2129)

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/GlassLockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

.line 907
:goto_13
return-object v0

and change to this

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/GlassLockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

[COLOR="Red"]:goto_0[/COLOR]

.line 907
:goto_13
return-object v0

[COLOR="red"]:cond_3
new-instance v0, Lcom/android/internal/policy/impl/CyanogenLockScreen;

iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;

iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;

iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;

iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;

iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;

invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/CyanogenLockScreen;-><init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V

goto :goto_0

[/COLOR]

save and close.

recompile android.policy.jar, set permission r-w-r-r and push to /system/framework and also with lidroid-res.apk.

set permission r-w-r-r and push Lidroid-Parts.apk to /system/app

note : if u already have 14 toggle please go to this thread to avoid force close

i hope u like it, and dont forget to press thanks :good::good::good:

credit : pratyush.creed@xda