[Sprint Samsung Galaxy Note II] digiblur:
[DEV] [MOD] [HOW-TO] Enable PRL Write & Remove ##DEBUG# lock code prompt - Note2 MA7

Please give thanks/credit if you use this in your ROM

- Donations are also appreciated!

Enable the PRL Write option in the ##DATA# menu (please do not abuse this and write VZW PRLs to end your contract as this will just lead to the permanent removal of this where it can't be added back in)

Decompile HiddenMenu.apk

Modify HiddenMenu/smali/com/android/hiddenmenu/hdata.smali

[COLOR="Red"] --const-string v2, "SPR"[/COLOR]
[COLOR="Green"] ++const-string v2, "SPX"[/COLOR]

sget-object v3, Lcom/android/hiddenmenu/hdata;->mSalesCode:Ljava/lang/String;

invoke-virtual {v2, v3}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

move-result v2

if-nez v2, :cond_3

const-string v2, "MSM7630_SURF"

sget-object v3, Lcom/android/hiddenmenu/hdata;->cpuPreCode:Ljava/lang/String;

invoke-virtual {v2, v3}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

move-result v2

if-nez v2, :cond_3

const-string v2, "VMU"

sget-object v3, Lcom/android/hiddenmenu/hdata;->mSalesCode:Ljava/lang/String;

invoke-virtual {v2, v3}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

move-result v2

if-nez v2, :cond_3

.line 79
invoke-virtual {p0}, Lcom/android/hiddenmenu/hdata;->getPreferenceManager()Landroid/preference/PreferenceManager;

move-result-object v2

invoke-virtual {v2, p0}, Landroid/preference/PreferenceManager;->createPreferenceScreen(Landroid/content/Context;)Landroid/preference/PreferenceScreen;

move-result-object v2

.line 80
const-string v3, "PRL Write"

NAM Block (not sure if this useful)

.line 85
:cond_3
[COLOR="Red"] --const-string v2, "SPR"[/COLOR]
[COLOR="Green"] ++const-string v2, "SPX"[/COLOR]

sget-object v3, Lcom/android/hiddenmenu/hdata;->mSalesCode:Ljava/lang/String;

invoke-virtual {v2, v3}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

move-result v2

if-nez v2, :cond_4

const-string v2, "MSM7630_SURF"

sget-object v3, Lcom/android/hiddenmenu/hdata;->cpuPreCode:Ljava/lang/String;

invoke-virtual {v2, v3}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

move-result v2

if-nez v2, :cond_4

const-string v2, "VMU"

sget-object v3, Lcom/android/hiddenmenu/hdata;->mSalesCode:Ljava/lang/String;

invoke-virtual {v2, v3}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

move-result v2

if-nez v2, :cond_4

.line 86
invoke-virtual {p0}, Lcom/android/hiddenmenu/hdata;->getPreferenceManager()Landroid/preference/PreferenceManager;

move-result-object v2

invoke-virtual {v2, p0}, Landroid/preference/PreferenceManager;->createPreferenceScreen(Landroid/content/Context;)Landroid/preference/PreferenceScreen;

move-result-object v2

.line 87
const-string v3, "NAM Block"

Remove the ##DEBUG# lock code prompt (Samsung, you shouldn't lock this in the first place as it does no harm)

Modify HiddenMenu/smali/com/android/hiddenmenu/HiddenmenuBroadcastReceiver.smali

.line 169
[COLOR="Red"] --const-class v0, Lcom/android/hiddenmenu/DebugMenu_Check;[/COLOR]
[COLOR="Green"] ++const-class v0, Lcom/android/hiddenmenu/DEBUGMENU;[/COLOR]

invoke-virtual {v3, p1, v0}, Landroid/content/Intent;->setClass(Landroid/content/Context;Ljava/lang/Class;)Landroid/content/Intent;

move-result-object v0

[COLOR="Red"] --const-string v1, "keyString"

--invoke-virtual {v0, v1, v5}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
[/COLOR]
move v0, v2

If you like this MOD and would like to see others please consider a donation via my profile. I encourage other developers to share their work in How-To's as well.