[THEME][ZIP]Complete Gingerbread theme for 3xx based roms - Dell Venue

TheManii said:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Notification widgets are part of widgetsoid and not theme
Special thanks to Vertumus for allowing me to use his battery % icons in my theme.
His Samsung theme can be found here: Gingerbread SPECIAL EDITION
What it does is make the theme as close to stock as possible.
(All the HDPI icons are a straight rip from the Nexus 1's rom and the MDPI icons are from the Android 2.3 emulator image)
The theme is made of up 4 parts:
Main Gingerbread theme
Theme with optional battery % icons (HDPI only)
Stock app icons
Clock with AM/PM Removed and white clock mod
Stock Android fonts [Only required for Streakmod]
Install Instructions:
Flash framework or framework+batt for main theme
Optional: flash icons for stock GB icons
Optional: flash clock to remove AM/PM indicator
Optional: flash fonts for stock fonts
Changelog:
Sep 11, 2011: Minor update to theme, updated clock mod to Stock 360
Sep 11, 2011: Updated base apks to Stock 360
Sep 9, 2011: Removed carrier text from statusbar
Aug 19, 2011: Updated install script
Aug 14, 2011: Updated clock mod to work on all dpis
Aug 1, 2011: Updated email icons
Aug 1, 2011: Slimmed theme and added locales
Jul 30, 2011: Updated MDPI with assets from GB emulator image
Jul 29, 2011: Added black popup menu to theme
Jul 26, 2011: Added clock mod
Jul 25, 2011: Added missing phone icon
Jul 25, 2011: Added Icon mod
Jul 15, 2011: Updated sound icon
Jul 14, 2011: Initial release
Main theme and stock icon mod compatable roms:
Streakdroid 1.9.1
Simplestreak 1.2 (Likely, untested)
NeCoroiD b58
Playdoh 1.0 (Likely, untested)
Stock 351 (Requires clock mod) (Likely, untested)
Stock 354 (Requires clock mod)
Stock 360 (Requires clock mod)
Clock mod compatable roms:
Streakdroid 1.9.1 [354 Based]
Simplestreak 1.2 [354 Based] (Likely, untested)
Playdoh 1.0 [354 Based] (Likely, untested)
Stock 351 (Likely, untested)
Stock 354 (Likely, untested)
Stock 360
Notes:
First boot after flashing may take several minutes, any reboots afterwards will be much quicker
Battery % icons only work in HDPI mode (DPI of 200 or greater). They will NOT work on the default dpi of 160.
Known inconsistancies:
None
Download Mirror:
(Please use the attached files instead of the mirror if you can so I can keep track of downloads and to put less stress on DJ_Steve's servers)
Main theme
Main theme + battery icons
Clock
Fonts
Icons
Thanks:
Vertumus for his battery % icons
xanthinealkaloid/JsChiSurf for finding a better clock mod
s0niqu3 for writing the actual code for the clock mod
Click to expand...
Click to collapse
Reposted from the streak5 theme subforum, if you wish to leave comments, press the ">" in the header bar of the quote box.
The main theme itself should work on venue 3xx roms, but the clock will likely NOT work and I do not intend to make a clock port to any roms.
There's guides to make a clock mod on the streak 5 section, the directions would be identical for the venue too if anyone was inclined to port it.

TheManii said:
Reposted from the streak5 theme subforum, if you wish to leave comments, press the ">" in the header bar of the quote box.
The main theme itself should work on venue 3xx roms, but the clock will likely NOT work and I do not intend to make a clock port to any roms.
There's guides to make a clock mod on the streak 5 section, the directions would be identical for the venue too if anyone was inclined to port it.
Click to expand...
Click to collapse
i installed "Main + Baterry" with CWM, but my venue can not boot my venue'rom is 2.3.3 408

It's not compatable with 4xx/GB roms

Hi TheManii
Is it possible for you to make a nice theme like this for the 4xx/GBRom .Since most of us here have the 4xx rom...
Thanks

It's a port of the GB rom, you cant exactly port it's own theme back to itself

crainz said:
Hi TheManii
Is it possible for you to make a nice theme like this for the 4xx/GBRom .Since most of us here have the 4xx rom...
Thanks
Click to expand...
Click to collapse
"Nice theme like this"? Isn't 4xx's theme gingerbread already? What are you looking for?

clock color
awesome theme but i'm having the problem that my clock is not visible.. either it is in black color on black notification bar or it is not there..

nice theme
thank you for making

Question - I am just trying to remove the am/pm from my rom and make that edit myself in the services.jar file. If possible can you tell me which smali file did you edit... Thanks in Advance

Code:
.method private final updateClock()V
.registers 7
.prologue
.line 736
iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mCalendar:Ljava/util/Calendar;
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
move-result-wide v1
invoke-virtual {v0, v1, v2}, Ljava/util/Calendar;->setTimeInMillis(J)V
.line 737
iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mClockData:Lcom/android/server/status/IconData;
iget-object v1, p0, Lcom/android/server/status/StatusBarPolicy;->mContext:Landroid/content/Context;
invoke-static {v1}, Landroid/text/format/DateFormat;->getTimeFormat(Landroid/content/Context;)Ljava/text/DateFormat;
move-result-object v1
iget-object v2, p0, Lcom/android/server/status/StatusBarPolicy;->mCalendar:Ljava/util/Calendar;
invoke-virtual {v2}, Ljava/util/Calendar;->getTime()Ljava/util/Date;
move-result-object v2
invoke-virtual {v1, v2}, Ljava/text/DateFormat;->format(Ljava/util/Date;)Ljava/lang/String;
move-result-object v1
const-string v4, " PM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v1
const-string v4, " AM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v1
iput-object v1, v0, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;
.line 738
iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mService:Lcom/android/server/status/StatusBarService;
iget-object v1, p0, Lcom/android/server/status/StatusBarPolicy;->mClockIcon:Landroid/os/IBinder;
iget-object v2, p0, Lcom/android/server/status/StatusBarPolicy;->mClockData:Lcom/android/server/status/IconData;
const/4 v3, 0x0
invoke-virtual {v0, v1, v2, v3}, Lcom/android/server/status/StatusBarService;->updateIcon(Landroid/os/IBinder;Lcom/android/server/status/IconData;Lcom/android/server/status/NotificationData;)V
.line 739
return-void
.end method
in services.jar/clock\com\android\server\status\statusbaricon.smali
I assume you understand how to baksmali and diff it, the AM and PM should be whatever chars your lang uses for AM and PM (if your lang does not use AM PM). It's not the proper way to do it, I never bothered finding out how GB roms do it properly.

TheManii said:
Code:
.method private final updateClock()V
.registers 7
.prologue
.line 736
iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mCalendar:Ljava/util/Calendar;
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
move-result-wide v1
invoke-virtual {v0, v1, v2}, Ljava/util/Calendar;->setTimeInMillis(J)V
.line 737
iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mClockData:Lcom/android/server/status/IconData;
iget-object v1, p0, Lcom/android/server/status/StatusBarPolicy;->mContext:Landroid/content/Context;
invoke-static {v1}, Landroid/text/format/DateFormat;->getTimeFormat(Landroid/content/Context;)Ljava/text/DateFormat;
move-result-object v1
iget-object v2, p0, Lcom/android/server/status/StatusBarPolicy;->mCalendar:Ljava/util/Calendar;
invoke-virtual {v2}, Ljava/util/Calendar;->getTime()Ljava/util/Date;
move-result-object v2
invoke-virtual {v1, v2}, Ljava/text/DateFormat;->format(Ljava/util/Date;)Ljava/lang/String;
move-result-object v1
const-string v4, " PM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v1
const-string v4, " AM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v1
iput-object v1, v0, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;
.line 738
iget-object v0, p0, Lcom/android/server/status/StatusBarPolicy;->mService:Lcom/android/server/status/StatusBarService;
iget-object v1, p0, Lcom/android/server/status/StatusBarPolicy;->mClockIcon:Landroid/os/IBinder;
iget-object v2, p0, Lcom/android/server/status/StatusBarPolicy;->mClockData:Lcom/android/server/status/IconData;
const/4 v3, 0x0
invoke-virtual {v0, v1, v2, v3}, Lcom/android/server/status/StatusBarService;->updateIcon(Landroid/os/IBinder;Lcom/android/server/status/IconData;Lcom/android/server/status/NotificationData;)V
.line 739
return-void
.end method
in services.jar/clock\com\android\server\status\statusbaricon.smali
I assume you understand how to baksmali and diff it, the AM and PM should be whatever chars your lang uses for AM and PM (if your lang does not use AM PM). It's not the proper way to do it, I never bothered finding out how GB roms do it properly.
Click to expand...
Click to collapse
Yea if this is for Froyo then its a no go I have been sniffing around this code for a minute and I know its in the services.jar file but can not find the AM/PM indicators anywhere. Thanks for your assistance though... Just to clarify this is the Froyo method right

That code is directly from a Streak 5 360 rom, the base should be nearly identical for all V roms (assuming you're in fact talking about a V)
Code:
const-string v4, " PM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v1
const-string v4, " AM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v..
is the main functional part of the mod, but I havnt touched it in nearly a year so my memory of the specifics isnt very good

TheManii said:
That code is directly from a Streak 5 360 rom, the base should be nearly identical for all V roms (assuming you're in fact talking about a V)
Code:
const-string v4, " PM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v1
const-string v4, " AM"
const-string v5, ""
invoke-virtual {v1, v4, v5}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
move-result-object v..
is the main functional part of the mod, but I havnt touched it in nearly a year so my memory of the specifics isnt very good
Click to expand...
Click to collapse
Trying to do the mod for a Gingerbread based phone - Galaxy 2 actually and I was just mulling around looking for the fix and thought I might asked you to see if you had knowledge of it. The services files are definitely different at closer look but was hoping for some more insight... Like I said thanks anyway and sorry if I wasted any of your time

If you're on a GB rom already I dont believe that'll help, you'll need to figure out what code was removed/disabled then, as GB natively includes the ability to remove the AM/PM indicators.

Related

Can't figure out a few things. Rom Tweaks

I'm using android revolution right now as my current rom. It is missing a few things, that I'm used to from being on clean rom and infected for a while.
Can anyone help me figure these things out and add them to the rom myself.
Added camera settings - HDR, Panorama, sound on/off ~ http://forum.xda-developers.com/showthread.php?t=1263813
Dimmed Capacity Buttons with custom kernel ~ http://forum.xda-developers.com/showthread.php?t=1276936
Transparent Rosie
Transparent Pull down
Extended Quick Settings
Extended Power Options
I looked around for some flashable zips for these things but I couldnt find any. Thanks for your help.
faugnom1 said:
I'm using android revolution right now as my current rom. It is missing a few things, that I'm used to from being on clean rom and infected for a while.
Can anyone help me figure these things out and add them to the rom myself.
Added camera settings - HDR, Panorama, sound on/off ~ http://forum.xda-developers.com/showthread.php?t=1263813
Dimmed Capacity Buttons with custom kernel ~ http://forum.xda-developers.com/showthread.php?t=1276936
Transparent Rosie
Transparent Pull down
Extended Quick Settings
Extended Power Options
I looked around for some flashable zips for these things but I couldnt find any. Thanks for your help.
Click to expand...
Click to collapse
I don't know about the transparent things, but have done the last 2.
For extended settings, you just need to delete all of the following lines in quicksettings.smali inside of systemui.apk.
Code:
.line 79
iget-object v2, p0, Lcom/android/systemui/statusbar/preference/QuickSettings;->mSettingItems:[Lcom/android/systemui/statusbar/preference/StatusBarPreference;
aget-object v2, v2, v7
invoke-virtual {v2, v7}, Lcom/android/systemui/statusbar/preference/StatusBarPreference;->setEnable(Z)V
.line 80
iget-object v2, p0, Lcom/android/systemui/statusbar/preference/QuickSettings;->mSettingItems:[Lcom/android/systemui/statusbar/preference/StatusBarPreference;
aget-object v2, v2, v8
invoke-virtual {v2, v7}, Lcom/android/systemui/statusbar/preference/StatusBarPreference;->setEnable(Z)V
.line 85
sget-boolean v2, Lcom/android/systemui/statusbar/StatusBarFlag;->HTC_QS_TASK_MANAGER:Z
if-nez v2, :cond_0
.line 86
iget-object v2, p0, Lcom/android/systemui/statusbar/preference/QuickSettings;->mSettingItems:[Lcom/android/systemui/statusbar/preference/StatusBarPreference;
aget-object v2, v2, v10
invoke-virtual {v2, v7}, Lcom/android/systemui/statusbar/preference/StatusBarPreference;->setEnable(Z)V
.line 92
:cond_0
iget-object v2, p0, Lcom/android/systemui/statusbar/preference/QuickSettings;->mSettingItems:[Lcom/android/systemui/statusbar/preference/StatusBarPreference;
aget-object v2, v2, v11
invoke-virtual {v2, v7}, Lcom/android/systemui/statusbar/preference/StatusBarPreference;->setEnable(Z)V
Also change
Code:
.line 94
.local v0, cm:Landroid/net/ConnectivityManager;
if-eqz v0, :cond_2
.line 95
invoke-virtual {v0}, Landroid/net/ConnectivityManager;->getTetherableWifiRegexs()[Ljava/lang/String;
move-result-object v1
.line 96
.local v1, hotspotRegexs:[Ljava/lang/String;
array-length v2, v1
if-eqz v2, :cond_1
invoke-virtual {v0}, Landroid/net/ConnectivityManager;->isTetheringSupported()Z
move-result v2
if-nez v2, :cond_2
.line 97
:cond_1
to
Code:
.line 94
.local v0, cm:Landroid/net/ConnectivityManager;
if-eqz v0, :cond_[COLOR="Red"]1[/COLOR]
.line 95
invoke-virtual {v0}, Landroid/net/ConnectivityManager;->getTetherableWifiRegexs()[Ljava/lang/String;
move-result-object v1
.line 96
.local v1, hotspotRegexs:[Ljava/lang/String;
array-length v2, v1
if-eqz v2, :cond_[COLOR="Red"]0[/COLOR]
invoke-virtual {v0}, Landroid/net/ConnectivityManager;->isTetheringSupported()Z
move-result v2
if-nez v2, :cond_[COLOR="Red"]1[/COLOR]
.line 97
:cond_[COLOR="Red"]0[/COLOR]
For the extended power menu and reboot options, you need to edit android.policy.jar. Take one from a stock rom and compare the decompiled version to one from a custom rom (I usually use SteelH's ROM). I cannot remember exactly which files are changed.
Ty sir. I found some old transparency zips on my computer. Ill post them here in case anyone else wants them.

[GUIDE][HOW TO] Toggle to choose AOSP Lockscreen **11DEC**

For TouchWiz Jelly Bean Roms (LSJ)
This is a noob proof guide, very easy to do, and made to involve less :cond_ possible.
Is not a clean guide for developers, infact i will use existing parts of code (not used) to make the toggle.
Obviously, if u are a developer and have a little experience with smali code language and patience with cond you can figure this out easily
requirements:
-apktool use (i won t teach u how to use apktool, i assume u can use it)
-attention
this tutorial is made on 2 parts:
-create a switch to change circle lockscreen with aosp lockscreen
-create a toggle to set the aosp lockscreen when checked
ready?
PART 1
We need to decompile android.policy.jar for first.
navigate: smali/com/android/internal/policy/impl/LockPatternKeyguardView.smali
look for .method createLockScreen()Landroid/view/View; and add the red lines
Code:
.method createLockScreen()Landroid/view/View;
.registers 7
.prologue
.line 1319
[COLOR="Red"]iget-object v0, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "aosp_lock"
const/4 v2, 0x0
invoke-static {v0, v1, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
if-nez v0, :cond_mirko
[/COLOR]
new-instance v0, Lcom/android/internal/policy/impl/sec/CircleLockScreen;
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/sec/CircleLockScreen;-><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 :goto_ddd[/COLOR]
.line 1325
[COLOR="Red"]:cond_mirko
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
[/COLOR]
.local v0, lockView:Landroid/view/View;
[COLOR="Red"]:goto_ddd[/COLOR]
invoke-direct {p0, v0}, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->initializeTransportControlView(Landroid/view/View;)V
first part is done
recompile and push it on /system/framework
PART 2
this is the not clean part, i have not created new codes for a toggle, but i used an unused code with the form i needed (checkbox preference).
I decompiled SecSettings.apk /smali/com/android/settings/LockscreenSettings.smali
the unused code i used is "mSayCommand" one, infact has the checkbox preference form i needed as we can see
Code:
.field private mSayCommand:Landroid/preference/CheckBoxPreference;
ok let s start second part, we need to change all "mSayCommand" to "mAospLock" and change the keyword from "wake_up_lock_screen" to "aosp_lock" in order to recall the first part of the mod we made in android.policy.jar
red part is what we add, and purple what we delete.
Code:
[COLOR="Red"].field private mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
.field private mCameraShortCut:Landroid/preference/SwitchPreferenceScreen;
.field private mClock:Landroid/preference/CheckBoxPreference;
.field private mDualclock:Landroid/preference/SwitchPreferenceScreen;
.field private mHelpText:Landroid/preference/CheckBoxPreference;
.field private mInformationTicker:Landroid/preference/SwitchPreferenceScreen;
.field private mInkEffect:Landroid/preference/PreferenceScreen;
.field mInkEffectSummary:[I
.field private mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;
.field private mLockScreenShortcut:Landroid/preference/SwitchPreferenceScreen;
.field private mMotionDialog:Landroid/app/AlertDialog;
.field private mRippleEffect:Landroid/preference/CheckBoxPreference;
[COLOR="DarkOrchid"].field private mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
...
Code:
.line 319
:cond_f8
[COLOR="DarkOrchid"] iget-object v4, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v4, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
if-eqz v4, :cond_10e
.line 320
[COLOR="DarkOrchid"]iget-object v7, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v7, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
[COLOR="DarkOrchid"]const-string v8, "wake_up_lock_screen"[/COLOR]
[COLOR="Red"]const-string v8, "aosp_lock"[/COLOR]
invoke-static {v4, v8, v6}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v4
if-eqz v4, :cond_146
move v4, v5
:goto_10b
invoke-virtual {v7, v4}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
Code:
.line 225
const-string v9, "say_your_wakeup"
invoke-virtual {p0, v9}, Lcom/android/settings/LockScreenSettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v9
check-cast v9, Landroid/preference/CheckBoxPreference;
[COLOR="DarkOrchid"] iput-object v9, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iput-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
.line 227
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getActivity()Landroid/app/Activity;
move-result-object v9
invoke-static {v9}, Lcom/android/settings/Utils;->isTablet(Landroid/content/Context;)Z
move-result v9
if-eqz v9, :cond_20d
.line 228
[COLOR="DarkOrchid"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getResources()Landroid/content/res/Resources;
move-result-object v10
const v11, 0x7f090d6f
invoke-virtual {v10, v11}, Landroid/content/res/Resources;->getString(I)Ljava/lang/String;
move-result-object v10
invoke-virtual {v9, v10}, Landroid/preference/CheckBoxPreference;->setSummary(Ljava/lang/CharSequence;)V
as u can see I left untouched keyword "say_your_wakeup", it s not a wrong writing, i left it and i will use that keyword in future steps.
Code:
.line 254
[COLOR="DarkOrchid"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
if-eqz v9, :cond_26d
.line 255
[COLOR="DarkOrchid"]invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getPreferenceScreen()Landroid/preference/PreferenceScreen;
move-result-object v9
iget-object v10, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;
invoke-virtual {v9, v10}, Landroid/preference/PreferenceScreen;->removePreference(Landroid/preference/Preference;)Z
[/COLOR]
we delete this part of code to make the option visible, infact i said we re using an unused part of code, and has been hidden from preference screen.
Code:
.line 259
:cond_276
const/4 v9, 0x0
invoke-static {v9}, Lcom/android/settings/Utils;->isTablet(Landroid/content/Context;)Z
move-result v9
if-nez v9, :cond_287
[COLOR="DarkOrchid"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
if-eqz v9, :cond_296
if-eqz v7, :cond_296
iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mCameraShortCut:Landroid/preference/SwitchPreferenceScreen;
if-nez v9, :cond_296
Code:
.line 262
:cond_296
iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mCameraShortCut:Landroid/preference/SwitchPreferenceScreen;
if-nez v9, :cond_2af
[COLOR="DarkOrchid"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
if-nez v9, :cond_2af
if-nez v7, :cond_2af
Code:
.line 356
:cond_b3
[COLOR="DarkOrchid"]iget-object v4, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v4, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
invoke-virtual {p2, v4}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v4
if-eqz v4, :cond_1e
.line 357
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
[COLOR="DarkOrchid"]const-string v5, "wake_up_lock_screen"[/COLOR]
[COLOR="Red"]const-string v5, "aosp_lock"[/COLOR]
[COLOR="DarkOrchid"]iget-object v6, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;[/COLOR]
[COLOR="Red"]iget-object v6, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;[/COLOR]
invoke-virtual {v6}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v6
if-eqz v6, :cond_ce
smali part is done, and now the toggle is set and working
last part is to edit our unused part of the code in res/xml folder, lockscreen_settings.xml
Code:
[COLOR="DarkOrchid"]<CheckBoxPreference android:title="@string/samsung_unlock_option_say_your_wakeup_command_to_unlock_screen" android:key="say_your_wakeup" android:summary="@string/wakeup_in_lockscreen_summary" />
[/COLOR]
[COLOR="Red"]<CheckBoxPreference android:title="@string/your_string" android:key="say_your_wakeup" android:summary="@string/your_summary_string" />[/COLOR]
asu can see we have again the keyword i said before "say_your_wakeup" , if u want u can change it, but change it in the smali part too if not the toggle won t work.
Now simply add the strings in /res/values/strings.xml
Code:
<string name="your_string">AOSP Lockscreen</string>
<string name="your_summary_string">Original Jelly Bean Lockscreen</string>
that s it.
easy and noob proof
and this is the result
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Hey there bro A really nice tutorial, I miss you and all of XDA xD
where are you legend?
LegendK95 said:
Hey there bro A really nice tutorial, I miss you and all of XDA xD
Click to expand...
Click to collapse
Hello broooo hurry up, we have to work we have to work we have to work
malavan said:
where are you legend?
Click to expand...
Click to collapse
hello buddy, he is studying hard u.u in mid-june will be among us again
Great work mirko!
Very good stuff
Bologna said:
Great work mirko! Thanks a lot!
Click to expand...
Click to collapse
thank u mate means much for me some your congrats
Heyy,
Great tut! Thanks a lot!
I'm trying to get this to work on LP9
Button shows up correctly in settings, but I get a little compiling error of policy.jar.
The error I get is an undefined "goto_14" in line 3008.
There's 2 "goto_14" 's in LockPatternKeyguardView...
The one you pointed out and this seconde one in line 3008...
So I also changed the second one in "goto_1e" and after that the .dex compiles without errors...
Phone starts up with AOSP Lockscreen, but after that a bootloop...
Could you have a look at LP9's LockPatternKeyguardView.smali?
Here it is with the changes made to it, following exactly your tut:
http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/LockPatternKeyguardView.smali
Thanks a lot in advance for looking into it!
Edit: Here it is zipped: http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/LockPatternKeyguardView.zip
The Undertakerr said:
Heyy,
Great tut! Thanks a lot!
I'm trying to get this to work on LP9
Button shows up correctly in settings, but I get a little compiling error of policy.jar.
The error I get is an undefined "goto_14" in line 3008.
There's 2 "goto_14" 's in LockPatternKeyguardView...
The one you pointed out and this seconde one in line 3008...
So I also changed the second one in "goto_1e" and after that the .dex compiles without errors...
Phone starts up with AOSP Lockscreen, but after that a bootloop...
Could you have a look at LP9's LockPatternKeyguardView.smali?
Here it is with the changes made to it, following exactly your tut:
http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/LockPatternKeyguardView.smali
Thanks a lot in advance for looking into it!
Click to expand...
Click to collapse
hello sure!
I told that mod was for LPF, probably there s some diff with LP9.
Let me watch into
PS: please upload your smali file, not a link with text
Here it is my man, and give my greetings to Doctor Maroun!
http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/LockPatternKeyguardView.zip
The Undertakerr said:
Here it is my man, and give my greetings to Doctor Maroun!
http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/LockPatternKeyguardView.zip
Click to expand...
Click to collapse
I m sure he will be, he s a smart guy
please the unmodified one mate I didn t explained myself good
Mirko ddd said:
I m sure he will be, he s a smart guy
please the unmodified one mate I didn t explained myself good
Click to expand...
Click to collapse
Here's the original LP9 LockPatternKeyguardView.smali :
http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/ORIGINAL LP9 LockPatternKeyguardView.smali.zip
Thanks a lot!
The Undertakerr said:
Here's the original LP9 LockPatternKeyguardView.smali :
http://dl.dropbox.com/u/25779832/SGS2/ALLES ICS/ORIGINAL LP9 LockPatternKeyguardView.smali.zip
Thanks a lot!
Click to expand...
Click to collapse
here it is
let me know about
https://rapidshare.com/files/145593662/LockPatternKeyguardViewMirkoddd.zip
Mirko ddd said:
here it is
let me know about
https://rapidshare.com/files/145593662/LockPatternKeyguardViewMirkoddd.zip
Click to expand...
Click to collapse
You're the man!!
Will let you know within 10 minutes
EDIT:
The good news: It doesn't give bootloop anymore!!
The bad news: It stays on AOSP Lockscreen. Doesn't matter if I untick the aosp toggle or not, stays on aosp lockscreen.
Even a reboot doesn't change it...
Will try tommorow again, will start all over and make the toggle in settings. Maybe something went wrong over there....
Thanks very much for you help though, tommorow I'll report back ok?
The Undertakerr said:
You're the man!!
Will let you know within 10 minutes
Click to expand...
Click to collapse
haha no u are the man, I am the kid
The Undertakerr said:
You're the man!!
Will let you know within 10 minutes
EDIT:
The good news: It doesn't give bootloop anymore!!
The bad news: It stays on AOSP Lockscreen. Doesn't matter if I untick the aosp toggle or not, stays on aosp lockscreen.
Even a reboot doesn't change it...
Will try tommorow again, will start all over and make the toggle in settings. Maybe something went wrong over there....
Thanks very much for you help though, tommorow I'll report back ok?
Click to expand...
Click to collapse
just check if keyword match with the one assigned into Settings xml/display_settings.xml
that s the only thing that makes me think about ur prob
get ready for the how to for camera mod!
Tonight
lpd
I mirko and thanks for your work
I try with lpd rom but it doesn't work the display settins is right....but when I enable or disable aosp lockscreen there is not change in the lock
There is the zip with the changes, and here there is the zip with the original files.
Can you see if I made something wrong?
Thank you
.malo2000 said:
I mirko and thanks for your work
I try with lpd rom but it doesn't work the display settins is right....but when I enable or disable aosp lockscreen there is not change in the lock
There is the zip with the changes, and here there is the zip with the original files.
Can you see if I made something wrong?
Thank you
Click to expand...
Click to collapse
https://rapidshare.com/files/3030748809/silvia.rar
.malo2000 said:
I mirko and thanks for your work
I try with lpd rom but it doesn't work the display settins is right....but when I enable or disable aosp lockscreen there is not change in the lock
There is the zip with the changes, and here there is the zip with the original files.
Can you see if I made something wrong?
Thank you
Click to expand...
Click to collapse
Mirko, I believe you've left out a part of the patch. We are adding a brand new setting, so you need to add the code to handle when it's clicked (usually in onPreferenceTreeClick) and thus save the global setting (ultimately a call to putInt).
jeboo said:
Mirko, I believe you've left out a part of the patch. We are adding a brand new setting, so you need to add the code to handle when it's clicked (usually in onPreferenceTreeClick) and thus save the global setting (ultimately a call to putInt).
Click to expand...
Click to collapse
yay u r right jeboo, in fact i wrote that this was for LPF only, and i wanted not to make a full how to for rearrange that mod for different bases.
I have really few few few time, and i realize i can t manage a thread with several requests or specific helpings.
I read what shoman94 told in ur thread, and maybe it should be better to give to you the honor to talk about this mod, what do u think about?
Let me know asap mate

Developing

I am slowly getting through the basics of apk decompiling, Editing, Debugging & recompiling.
Using tools like Apk Tool, Winrar, Notepad++ Winmerge, Adb .
first time I have touched an android or even done any kind of stuff like this was Early August 2012. So not long at all, now i have a question to the more experienced Devs. Eg; Lets just say I dont want increasing ringtone How do you pin point where in the apk to start editing i mean there are heaps of files its like looking for a needle in a haystack. One way I came close and pin pointed it is using a previous made mod and then used Winmerge to compare the differences, Problem is the differences in these to Apks is not just the Increasing ringtone, so when I winmerged them it picked out out the other differences Now this deffinatley narrowed it down. I have a feeling it has something to do with the Callnotifier.xml is this the only Xml?
Also Lets just say you dont have another apk to compare it to , how to you find out this stuff..
Another thing is I want to cook up a rom, but the way I want to do it is modding my own rom untill I am happy with it and then creating something like a nandroid without my personal data. then making it flashable for people. What tools is best used for this? I was thinking editing my nandroid and adding it to a cwm flash. but I think there is an easier way.
Thanks for you help
btemtd said:
I am slowly getting through the basics of apk decompiling, Editing, Debugging & recompiling.
Using tools like Apk Tool, Winrar, Notepad++ Winmerge, Adb .
first time I have touched an android or even done any kind of stuff like this was Early August 2012. So not long at all, now i have a question to the more experienced Devs. Eg; Lets just say I dont want increasing ringtone How do you pin point where in the apk to start editing i mean there are heaps of files its like looking for a needle in a haystack. One way I came close and pin pointed it is using a previous made mod and then used Winmerge to compare the differences, Problem is the differences in these to Apks is not just the Increasing ringtone, so when I winmerged them it picked out out the other differences Now this deffinatley narrowed it down. I have a feeling it has something to do with the Callnotifier.xml is this the only Xml?
Also Lets just say you dont have another apk to compare it to , how to you find out this stuff..
Another thing is I want to cook up a rom, but the way I want to do it is modding my own rom untill I am happy with it and then creating something like a nandroid without my personal data. then making it flashable for people. What tools is best used for this? I was thinking editing my nandroid and adding it to a cwm flash. but I think there is an easier way.
Thanks for you help
Click to expand...
Click to collapse
In my point of view,this is no shortcut,this is experience have been modified in the way
correct me,maybe i'm wrong!
Disable Increasing ringtone @secphone.apk\com\android\phone\Ringer$1.smali
delete every this code
Code:
setstreamvolume
thanks for your input.....It would now be good to have someone that has done this mod, to give us the 100% answer and maybe some extra advise/tips/tricks from their personal book of knowledge
Try the Android hacking forum on XDA
http://forum.xda-developers.com/
jje
I search, search and search the net for info on the mod i want. Some can be difficult to find the guides for.
If searching fails ill ask a dev for some info.
When it comes to comparing apks I will only do that if I know where the change needs to be then trial and error
Sent from my GT-I9305 using XDA Premium HD app
btemtd said:
thanks for your input.....It would now be good to have someone that has done this mod, to give us the 100% answer and maybe some extra advise/tips/tricks from their personal book of knowledge
Click to expand...
Click to collapse
I've 100% done this mod
disable increasing ringtone
http://www.mediafire.com/?72la46qi95j1d7b
leamoor said:
I've 100% done this mod
disable increasing ringtone
http://www.mediafire.com/?72la46qi95j1d7b
Click to expand...
Click to collapse
is this Disable Increasing ONLY mod?
And could you let me know what files inside the Secphone.apk you edited just for curiosty? was it the one file you stated above? Or did you port this mod?
btemtd said:
is this Disable Increasing ONLY mod?
And could you let me know what files inside the Secphone.apk you edited just for curiosty? Or did you port this mod?
Click to expand...
Click to collapse
yes,only disable Increasing ringtone!
this is exactly what i said @#2
decompile secphone/smali/com/android/phone/Ringer$1
delete red sentences
Code:
#setter for: Lcom/android/phone/Ringer;->mOriginRingtoneVolume:I
invoke-static {v1, v2}, Lcom/android/phone/Ringer;->access$702(Lcom/android/phone/Ringer;I)I
.line 571
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
iget-object v1, v1, Lcom/android/phone/Ringer;->mAudioManager:Landroid/media/AudioManager;
[COLOR="Red"]invoke-virtual {v1, v6, v4, v5}, Landroid/media/AudioManager;->setStreamVolume(III)V[/COLOR]
.line 573
const/4 v1, 0x7
const-wide/16 v2, 0x7d0
invoke-virtual {p0, v1, v2, v3}, Lcom/android/phone/Ringer$1;->sendEmptyMessageDelayed(IJ)Z
.line 578
:cond_4
:goto_2
invoke-virtual {v0}, Landroid/media/Ringtone;->play()V
.line 579
iget-object v2, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
monitor-enter v2
.line 580
:try_start_1
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mFirstRingStartTime:J
invoke-static {v1}, Lcom/android/phone/Ringer;->access$900(Lcom/android/phone/Ringer;)J
move-result-wide v3
const-wide/16 v5, 0x0
cmp-long v1, v3, v5
if-gez v1, :cond_5
.line 581
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
invoke-static {}, Landroid/os/SystemClock;->elapsedRealtime()J
move-result-wide v3
#setter for: Lcom/android/phone/Ringer;->mFirstRingStartTime:J
invoke-static {v1, v3, v4}, Lcom/android/phone/Ringer;->access$902(Lcom/android/phone/Ringer;J)J
.line 583
:cond_5
monitor-exit v2
goto/16 :goto_0
:catchall_0
move-exception v1
monitor-exit v2
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
throw v1
.line 546
:catchall_1
move-exception v1
:try_start_2
monitor-exit v2
:try_end_2
.catchall {:try_start_2 .. :try_end_2} :catchall_1
throw v1
.line 563
:cond_6
invoke-virtual {v0, v5}, Landroid/media/Ringtone;->setRepeat(Z)V
goto :goto_1
.line 574
:cond_7
const-string v1, "extra_ringer"
invoke-static {v1}, Lcom/android/phone/PhoneFeature;->hasFeature(Ljava/lang/String;)Z
move-result v1
if-eqz v1, :cond_4
.line 575
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mExtraRinger:Lcom/android/phone/ExtraRinger;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$800(Lcom/android/phone/Ringer;)Lcom/android/phone/ExtraRinger;
move-result-object v1
invoke-virtual {v1}, Lcom/android/phone/ExtraRinger;->startExtraRinger()V
goto :goto_2
.line 589
:pswitch_2
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
const-string v2, "mRingHandler: PLAY_TTS..."
#calls: Lcom/android/phone/Ringer;->log(Ljava/lang/String;Z)V
invoke-static {v1, v2, v4}, Lcom/android/phone/Ringer;->access$400(Lcom/android/phone/Ringer;Ljava/lang/String;Z)V
.line 591
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
iget-object v2, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
iget-object v2, v2, Lcom/android/phone/Ringer;->mContext:Landroid/content/Context;
invoke-static {v2, v4}, Lcom/android/phone/CallTextToSpeech;->getInstance(Landroid/content/Context;I)Lcom/android/phone/CallTextToSpeech;
move-result-object v2
#setter for: Lcom/android/phone/Ringer;->mCallTextToSpeech:Lcom/android/phone/CallTextToSpeech;
invoke-static {v1, v2}, Lcom/android/phone/Ringer;->access$1002(Lcom/android/phone/Ringer;Lcom/android/phone/CallTextToSpeech;)Lcom/android/phone/CallTextToSpeech;
.line 592
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mRingHandler:Landroid/os/Handler;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$1100(Lcom/android/phone/Ringer;)Landroid/os/Handler;
move-result-object v1
if-eqz v1, :cond_0
.line 593
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mRingHandler:Landroid/os/Handler;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$1100(Lcom/android/phone/Ringer;)Landroid/os/Handler;
move-result-object v1
const/4 v2, 0x5
invoke-virtual {v1, v2}, Landroid/os/Handler;->removeMessages(I)V
goto/16 :goto_0
.line 598
:pswitch_3
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
const-string v2, "mRingHandler: STOP_RING..."
#calls: Lcom/android/phone/Ringer;->log(Ljava/lang/String;Z)V
invoke-static {v1, v2, v4}, Lcom/android/phone/Ringer;->access$400(Lcom/android/phone/Ringer;Ljava/lang/String;Z)V
.line 599
iget-object v0, p1, Landroid/os/Message;->obj:Ljava/lang/Object;
.end local v0 #r:Landroid/media/Ringtone;
check-cast v0, Landroid/media/Ringtone;
.line 600
.restart local v0 #r:Landroid/media/Ringtone;
if-eqz v0, :cond_9
.line 602
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mCallTextToSpeech:Lcom/android/phone/CallTextToSpeech;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$1000(Lcom/android/phone/Ringer;)Lcom/android/phone/CallTextToSpeech;
move-result-object v1
if-eqz v1, :cond_8
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mCallTextToSpeech:Lcom/android/phone/CallTextToSpeech;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$1000(Lcom/android/phone/Ringer;)Lcom/android/phone/CallTextToSpeech;
move-result-object v1
invoke-virtual {v1}, Lcom/android/phone/CallTextToSpeech;->IsSpeakingTts()Z
move-result v1
if-eqz v1, :cond_8
.line 603
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mCallTextToSpeech:Lcom/android/phone/CallTextToSpeech;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$1000(Lcom/android/phone/Ringer;)Lcom/android/phone/CallTextToSpeech;
move-result-object v1
invoke-virtual {v1}, Lcom/android/phone/CallTextToSpeech;->stopTts()V
.line 604
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#setter for: Lcom/android/phone/Ringer;->mCallTextToSpeech:Lcom/android/phone/CallTextToSpeech;
invoke-static {v1, v8}, Lcom/android/phone/Ringer;->access$1002(Lcom/android/phone/Ringer;Lcom/android/phone/CallTextToSpeech;)Lcom/android/phone/CallTextToSpeech;
.line 606
:cond_8
invoke-virtual {v0}, Landroid/media/Ringtone;->stop()V
.line 610
:goto_3
invoke-virtual {p0}, Lcom/android/phone/Ringer$1;->getLooper()Landroid/os/Looper;
move-result-object v1
invoke-virtual {v1}, Landroid/os/Looper;->quit()V
goto/16 :goto_0
.line 608
:cond_9
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
new-instance v2, Ljava/lang/StringBuilder;
invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V
const-string v3, "- STOP_RING with null ringtone! msg = "
invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v2
invoke-virtual {v2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
move-result-object v2
invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v2
#calls: Lcom/android/phone/Ringer;->log(Ljava/lang/String;Z)V
invoke-static {v1, v2, v4}, Lcom/android/phone/Ringer;->access$400(Lcom/android/phone/Ringer;Ljava/lang/String;Z)V
goto :goto_3
.line 614
:pswitch_4
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
new-instance v2, Ljava/lang/StringBuilder;
invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V
const-string v3, "RETURN_ORIGIN_VOLUME: "
invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v2
iget-object v3, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mOriginRingtoneVolume:I
invoke-static {v3}, Lcom/android/phone/Ringer;->access$700(Lcom/android/phone/Ringer;)I
move-result v3
invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
move-result-object v2
invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v2
#calls: Lcom/android/phone/Ringer;->log(Ljava/lang/String;Z)V
invoke-static {v1, v2, v4}, Lcom/android/phone/Ringer;->access$400(Lcom/android/phone/Ringer;Ljava/lang/String;Z)V
.line 615
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
iget-object v1, v1, Lcom/android/phone/Ringer;->mAudioManager:Landroid/media/AudioManager;
iget-object v2, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mOriginRingtoneVolume:I
invoke-static {v2}, Lcom/android/phone/Ringer;->access$700(Lcom/android/phone/Ringer;)I
move-result v2
[COLOR="Red"] invoke-virtual {v1, v6, v2, v5}, Landroid/media/AudioManager;->setStreamVolume(III)V[/COLOR]
.line 616
const-string v1, "extra_ringer"
invoke-static {v1}, Lcom/android/phone/PhoneFeature;->hasFeature(Ljava/lang/String;)Z
move-result v1
if-eqz v1, :cond_0
.line 617
iget-object v1, p0, Lcom/android/phone/Ringer$1;->this$0:Lcom/android/phone/Ringer;
#getter for: Lcom/android/phone/Ringer;->mExtraRinger:Lcom/android/phone/ExtraRinger;
invoke-static {v1}, Lcom/android/phone/Ringer;->access$800(Lcom/android/phone/Ringer;)Lcom/android/phone/ExtraRinger;
I am so confused now as i just tried to decompile the same secphone.apk as i did before which worked, it also worked now but it gave this message
with your apk and my own something like could not decode replacing by false value: drawable *****bla bla/calll video icon.png
My apk said could not find 9patch chunk in file and all of a sudden it is doing this i did nothing!! each apk repeated this message with a few differnet files. Now how and why would it do this for no reason. it has always decompiled flawlessly. now it seems like there are missing files weirddd.
PS how did you locate that line, It would be almost in possible to search for that with no leads
btemtd said:
I am so confused now as i just tried to decompile the same secphone.apk as i did before which worked, it also worked now but it gave this message
with your apk and my own something like could not decode replacing by false value: drawable *****bla bla/calll video icon.png
My apk said could not find 9patch chunk in file and all of a sudden it is doing this i did nothing!! each apk repeated this message with a few differnet files. Now how and why
Click to expand...
Click to collapse
This is the method i from i9000 alreay know(i decompile some devs mod and fround it)
What version apktool are you used?Modifed code apk some apktool can not compile and decompile them
maybe for this reason,i used two sets of apktool to compile and decompile jelly bean apk
i'm use apktool 1.4.3 to decomplie,apktool 1.4.2 to compile,hope this can help.
but the funny thing this only just happened now it showing these weird errors, but the file is decompiled , but before it nevr showed these errors. They are more like files or certain things not found... not really errors. thanks anyways
here is the screen shot of these weird messages i have NEVER seen them before when decompiing does anyone know what they are, and why is it saying that
OK I removed that line that you said setstreamvolume etc,,,,,, now check out what happened wen i tried to compile it. I really dont get it now this would of happened if i didnt remove the line as it already happened even when i decompiled
has anyone seen this
btemtd said:
OK I removed that line that you said setstreamvolume etc,,,,,, now check out what happened wen i tried to compile it. I really dont get it now this would of happened if i didnt remove the line as it already happened even when i decompiled
has anyone seen this
Click to expand...
Click to collapse
Because your apktool can not compile modified apk
try use another apktool compile them
upload your apk here,for test compile and decompile
leamoor said:
Because your apktool can not compile modified apk
try use another apktool compile them
upload your apk here,for test compile and decompile
Click to expand...
Click to collapse
but this seems too strange i already made a mod 5x6 touchwiz layout... and it compiled perfectt.
Do you think i hould get the latest apktool?
btemtd said:
but this seems too strange i already made a mod 5x6 touchwiz layout... and it compiled perfectt.
Do you think i hould get the latest apktool?
Click to expand...
Click to collapse
Yes,this is strange,but sometimes happen ,
apktool I will suggestion you get the latest one!

[MOD][GUIDE][JB 4.1.2][MULTI-THREAD/NATIVE] Lockscreen Blur Effect/MULTITHREAD

Lockscreen Blur Effect
EDIT : Updated guide with Native function. Now it is ~60% faster​
I wanna share this mod with you which i made for my HarshJelly ROM. Before starting guide let's see what it does. Actually idea came from GravityBox Module.
What it does : It'll simply blur the background activity which you left before locking device (something like iOS 7's notification bar). Here are some caps to make it more clear.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Yeah this mod is compatible with all Lockscreens (AOSP, Sammy's circle lockscreen, pattern etc). I tested this mod on my SGSA running stock TW 4.1.2. Since all TW roms are almost same, it should work on all TW 4.1.2 ROMs.
Before starting tutorial, let me clear one thing that i won't respond to posts without full log. If you found any difficulty, feel free to ask me but please keep in mind above sentence.
What is required?
android.policy.jar
Apktool
Notepad++
So, let's begin...
Decompile android.policy.jar
Navigate to : com\android\internal\policy\impl\sec
Download attached file, extract it and put WallpaperWidget$1.smali to above folder.
In the same folder, open WallpaperWidget.smali
before #instance field add following code
Code:
# static fields
.field static mutex_acquired:Z
Search for .field private mEnhancedWallpaper:Lcom/android/internal/policy/impl/sec/EnhancedWallpaperWidget; and add this below it
Code:
.field private mHandler:Landroid/os/Handler;
Search for iput-boolean v2, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mIsLiveWallpaper:Z and add this below
Code:
new-instance v0, Landroid/os/Handler;
invoke-direct {v0}, Landroid/os/Handler;-><init>()V
iput-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mHandler:Landroid/os/Handler;
after # direct methods add following code
Code:
.method static constructor <clinit>()V
.locals 1
const-string v0, "harsh"
invoke-static {v0}, Ljava/lang/System;->loadLibrary(Ljava/lang/String;)V
const/4 v0, 0x1
sput-boolean v0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mutex_acquired:Z
return-void
.end method
Now search for .method public constructor <init>(Landroid/content/Context;Landroid/content/res/ConfigurationV and replace whole method with following :
Code:
.method public constructor <init>(Landroid/content/Context;Landroid/content/res/Configuration;)V
.locals 5
const/4 v4, 0x0
const/4 v3, -0x1
const/4 v2, 0x1
invoke-direct {p0, p1}, Landroid/widget/FrameLayout;-><init>(Landroid/content/Context;)V
const-string v0, "WallpaperWidget"
iput-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->TAG:Ljava/lang/String;
iput-boolean v2, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mIsLiveWallpaper:Z
new-instance v0, Landroid/os/Handler;
invoke-direct {v0}, Landroid/os/Handler;-><init>()V
iput-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mHandler:Landroid/os/Handler;
const/4 v0, 0x0
iput-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mLockScreenWallpaperImage:Landroid/widget/ImageView;
const-string v0, "/data/data/com.sec.android.gallery3d/lockscreen_wallpaper.jpg"
iput-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->PORTRAIT_WALLPAPER_IMAGE_PATH:Ljava/lang/String;
iput-object p1, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mContext:Landroid/content/Context;
invoke-virtual {p1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "lockscreen_wallpaper"
invoke-static {v0, v1, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
if-ne v0, v2, :cond_0
iput-boolean v4, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mIsLiveWallpaper:Z
:cond_0
iget-boolean v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mIsLiveWallpaper:Z
if-eqz v0, :cond_1
:goto_0
return-void
:cond_1
new-instance v0, Landroid/widget/ImageView;
invoke-direct {v0, p1}, Landroid/widget/ImageView;-><init>(Landroid/content/Context;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mLockScreenWallpaperImage:Landroid/widget/ImageView;
iget-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mLockScreenWallpaperImage:Landroid/widget/ImageView;
sget-object v1, Landroid/widget/ImageView$ScaleType;->CENTER_CROP:Landroid/widget/ImageView$ScaleType;
invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setScaleType(Landroid/widget/ImageView$ScaleType;)V
iget-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mLockScreenWallpaperImage:Landroid/widget/ImageView;
invoke-virtual {p0, v0, v3, v3}, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->addView(Landroid/view/View;II)V
invoke-direct {p0}, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->BlurImage()V
goto :goto_0
.end method
.method private BlurImage()V
.locals 2
new-instance v0, Ljava/lang/Thread;
new-instance v1, Lcom/android/internal/policy/impl/sec/WallpaperWidget$1;
invoke-direct {v1, p0}, Lcom/android/internal/policy/impl/sec/WallpaperWidget$1;-><init>(Lcom/android/internal/policy/impl/sec/WallpaperWidget;)V
invoke-direct {v0, v1}, Ljava/lang/Thread;-><init>(Ljava/lang/Runnable;)V
invoke-virtual {v0}, Ljava/lang/Thread;->start()V
return-void
.end method
.method static synthetic access$0(Lcom/android/internal/policy/impl/sec/WallpaperWidget;Landroid/graphics/Bitmap;Landroid/graphics/Bitmap;I)V
.locals 0
invoke-direct {p0, p1, p2, p3}, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->blurImage(Landroid/graphics/Bitmap;Landroid/graphics/Bitmap;I)V
return-void
.end method
.method static synthetic access$1(Lcom/android/internal/policy/impl/sec/WallpaperWidget;)Landroid/os/Handler;
.locals 1
iget-object v0, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mHandler:Landroid/os/Handler;
return-object v0
.end method
.method private native blurImage(Landroid/graphics/Bitmap;Landroid/graphics/Bitmap;I)V
.end method
Now search for # virtual methods and add this code after it
Code:
.method public updateWallpaper()V
.locals 3
const-string v1, "/data/data/com.sec.android.gallery3d/lockscreen_wallpaper.jpg"
iput-object v1, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mWallpaperPath:Ljava/lang/String;
new-instance v0, Landroid/graphics/drawable/BitmapDrawable;
invoke-virtual {p0}, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->getResources()Landroid/content/res/Resources;
move-result-object v1
iget-object v2, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mWallpaperPath:Ljava/lang/String;
invoke-direct {v0, v1, v2}, Landroid/graphics/drawable/BitmapDrawable;-><init>(Landroid/content/res/Resources;Ljava/lang/String;)V
iget-object v1, p0, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->mLockScreenWallpaperImage:Landroid/widget/ImageView;
invoke-virtual {v1, v0}, Landroid/widget/ImageView;->setImageDrawable(Landroid/graphics/drawable/Drawable;)V
return-void
.end method
Follow xperiacle's guide for TRANSPARENT STATUSBAR on lockscreen http://forum.xda-developers.com/showthread.php?t=2384892 (this is required, don't worry, it won't make it transparent)
From the extracted files, push libharsh.so to /system/lib/libharsh.so and chmod it to 644 (rw-r--r--)
Make sure that /data/data/com.sec.android.gallery3d/lockscreen_wallpaper.png & /data/data/com.sec.android.gallery3d/lockscreen_wallpaper.jpg file exists before you reboot your device. If it doesn't then put any valid png file there with name lockscreen_wallpaper.png/lockscreen_wallpaper.jpg and chmod it to 777
We're done :highfive: compile it and push it to device :good:
To add toggle for it, read here
Click to expand...
Click to collapse
What we're doing here?
Basically we are taking screenshot when device is getting locked and then we apply blur effect and sets it as wallpaper.
I know there are many way's to do it but i've preferred hacking WallpaperWidget's constructor. You can go for another way if you want.
Another thing to tell is that it depend on you device that how much time it'll require to do this process. On my device it nearly take 2 seconds (it depends on background). Multithreading can also be used. Read second post for more info and other tweaks., By default we're using Multi threading
Tips, Tricks & FAQs
Bugs & Remedies :
If multithreading is not enabled & device is woke up suddenly after locking then sometimes device stays unlocked for a moment --> Enabled multithreading or don't wake up device soon after locking it
[*] When mutithreading is enabled & device is suddenly woke up (soon after locking), it shows older image --> Disable mutithreading or don't wake up device soon after locking it
All bug are solved..
Click to expand...
Click to collapse
As this tutorial is written for 4.1.2 (API 16), we don't have native image processing support (which came in API 17).This is the reason why it takes long time to blur image. As told above, i' trying to implement native method for blurring image anybody interested in it can help me.
Tweaks :
Blur Radius : (Value in Hex)
Code:
.local v4, out:Landroid/graphics/Bitmap;
const/16 v5, [COLOR="Red"]0x19[/COLOR]
(lower radius --> better performance)
JPEG Quility: (Value in Hex)
Code:
.local v1, bytes:Ljava/io/ByteArrayOutputStream;
sget-object v5, Landroid/graphics/Bitmap$CompressFormat;->JPEG:Landroid/graphics/Bitmap$CompressFormat;
const/16 v6, [COLOR="red"]0x64[/COLOR]
Lower Quality --> better performance, weird colors
Click to expand...
Click to collapse
Changelog:
26th May 2014 --> Solved bug with delay while locking, Uses Multi Threading by default
xth February 2014 --> Native function Implementation (x > 6 )
6th February 2014 --> Initial Release
Click to expand...
Click to collapse
GReat Work!!!!!!
Amazing Job, Harsh as usual you surprise us every time....Man keep it UP!!
Thankz a Ton..!:good::good::good::good::good::good::good:
when i use this, can i still use normal wallpapers if i want? or does that need a toggle or something like that?
mjz2cool said:
when i use this, can i still use normal wallpapers if i want? or does that need a toggle or something like that?
Click to expand...
Click to collapse
+1
@BOOTMGR, Please make a short tutorial (if possible) for setting up a Toggle to switch it on or off from the Settings app :good:
Updated thread with new implementation. Now we are using Native function to blur image which is ~60% faster than previous implementation. Follow tutorial again if you've already done so.
mjz2cool said:
when i use this, can i still use normal wallpapers if i want? or does that need a toggle or something like that?
Click to expand...
Click to collapse
Sami Kabir said:
+1
@BOOTMGR, Please make a short tutorial (if possible) for setting up a Toggle to switch it on or off from the Settings app :good:
Click to expand...
Click to collapse
Adding toggle in secsetting is easy but only reason behind not providing it is that some people would have enabled AOSP lockscreen in that case method will be slightly different. But you can follow this tutorial to add toggle for it using build.prop
How to add Toggle :
Follow main tutorial
Inside WallpaperWidget.smali, search for invoke-direct {p0}, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->BlurImage()V and add following code above it
Code:
const-string v0, "ro.harsh.blurlockscreen"
invoke-static {v0, v2}, Landroid/os/SystemProperties;->getBoolean(Ljava/lang/String;Z)Z
move-result v0
if-eqz v0, :cond_2
Search below for .end method (2 - 3 lines down) and add this below it
Code:
:cond_2
invoke-direct {p0}, Lcom/android/internal/policy/impl/sec/WallpaperWidget;->setLockScreenWallpaper()V
goto :goto_0
That's all. Compile it.
Now you can toggle its state by adding ro.harsh.blurlockscreen=true or ro.harsh.blurlockscreen=false
You can also type in terminal setprop ro.harsh.blurlockscreen true/false to toggle state on the fly.
Click to expand...
Click to collapse
off topic: You keep doing stock jb more and more better
I'm Sorry But i'm Naive I cannot Follow this tutorial Can you Make a Flashable zip Plz Plz Plz Plz Plzzzzzzzzzzzzzzzzzzzzz
rajeev994 said:
I'm Sorry But i'm Naive I cannot Follow this tutorial Can you Make a Flashable zip Plz Plz Plz Plz Plzzzzzzzzzzzzzzzzzzzzz
Click to expand...
Click to collapse
He did on his ROM.
shut_down said:
He did on his ROM.
Click to expand...
Click to collapse
No he did not I'm using his harshjelly
Even if he did can you tell me how to do that
Sent from my GT-I9070 using Tapatalk 4
rajeev994 said:
No he did not I'm using his harshjelly
Even if he did can you tell me how to do that
Sent from my GT-I9070 using Tapatalk 4
Click to expand...
Click to collapse
It is written here step by step what to do.
If it is not, then I am sure he will add it to next release.
Upgrading Android OS...
Opening apllications...
I'm getting this again and again after I reboot my device, I think the files aren't compatible with my 4.1.2 TW deodexed..
but this mod looks so cool, I want this
http://www.xda-developers.com/android/blur-the-lock-screen-on-your-samsung-galaxy-s-advance/
You got to the portal
Seems interesting, great work! btw is this tut possible for CM11 roms? I would like to try compiling this on our CM11 builds
Is there anyway to make this into an xposed module?
Geddd said:
Upgrading Android OS...
Opening apllications...
I'm getting this again and again after I reboot my device, I think the files aren't compatible with my 4.1.2 TW deodexed..
but this mod looks so cool, I want this
Click to expand...
Click to collapse
It should be. Check again that & make sure you did everything properly. Did you pushed libharsh.so to /system/lib and changed its permission?
JovieBrett said:
Seems interesting, great work! btw is this tut possible for CM11 roms? I would like to try compiling this on our CM11 builds
Click to expand...
Click to collapse
You can do it easily by Xposed. Gravitybox doesnot suppot this on 4.1.2 because of unavailable API
francop311 said:
Is there anyway to make this into an xposed module?
Click to expand...
Click to collapse
Making this available through xposed is very easy. I make module later when i'll be free.
Awesoem!!! Looks Cool!
BOOTMGR said:
It should be. Check again that & make sure you did everything properly. Did you pushed libharsh.so to /system/lib and changed its permission?
Yes bro, I did follow the steps carefully and push the lib file (rw-r-r). I tried to do it again now it boot up but my homescreen is just blinking with black screen. If you have enough time can you please check my work?
here's my output classout folder and my untouched android policy..
if you're just not busy bro, I can wait. Thank you.
Click to expand...
Click to collapse
Geddd said:
BOOTMGR said:
It should be. Check again that & make sure you did everything properly. Did you pushed libharsh.so to /system/lib and changed its permission?
Yes bro, I did follow the steps carefully and push the lib file (rw-r-r). I tried to do it again now it boot up but my homescreen is just blinking with black screen. If you have enough time can you please check my work?
here's my output classout folder and my untouched android policy..
if you're just not busy bro, I can wait. Thank you.
Click to expand...
Click to collapse
Compile attached sources (don't forget to add META-INF folder). There were some additional things in your constructor. Please if it doesn't work then provide me full log.
Click to expand...
Click to collapse
BOOTMGR said:
Geddd said:
Compile attached sources (don't forget to add META-INF folder). There were some additional things in your constructor. Please if it doesn't work then provide me full log.
Click to expand...
Click to collapse
Still no luck sorry but I don't know how to make a log/logcat..
Anyway, but thanks again sir.
Click to expand...
Click to collapse

[GUIDE] How To Add -Apps Edge/Contacts/Task Panel - For Galaxy S5 - UX Port Roms [MM]

Hello Xda Users,
This Guide is for Adding Edge Panels To Latest Samsung UX Based Roms
What's Required:
*Apktool for Decompiling/Recompiling jars
*Notepad++ For Editing Smalis
Steps:
1. Open your " system/etc/floating_feature.xml " with Notepad++
And
Find The Following Code:
Code:
<SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE></SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE
<SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE_STRIPE></SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE_STRIPE>
REPLACE IT WITH:
Code:
<SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE>[COLOR="DarkGreen"]people,task,circle,panel[/COLOR]</SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE>
<SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE_STRIPE>[COLOR="darkgreen"]-1[/COLOR]</SEC_FLOATING_FEATURE_COMMON_CONFIG_EDGE_STRIPE>
Now you must use ApkTool to decompile/Make Changes to smalis/Recompile
*Use Tickle My Android Apktool or Any other Apktool
2. Now Decompile your " Services.jar "
Find Red Text and Add Green Lines:
LOCATE TO:
smali/com/android/server/SystemServer.smali
Click to expand...
Click to collapse
Open up "SystemServer.smali" with Notepad++
SEARCH FOR:
Code:
[COLOR="Red"]const-string/jumbo v6, "spengestureservice"[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
Code:
const-string/jumbo v6, "spengestureservice"
new-instance v7, Lcom/android/server/smartclip/SpenGestureManagerService;
move-object/from16 v0, v218
invoke-direct {v7, v5, v0}, Lcom/android/server/smartclip/SpenGestureManagerService;-><init>(Landroid/content/Context;Lcom/android/server/wm/WindowManagerService;)V
invoke-static {v6, v7}, Landroid/os/ServiceManager;->addService(Ljava/lang/String;Landroid/os/IBinder;)V
:try_end_85
.catch Ljava/lang/Throwable; {:try_start_85 .. :try_end_85} :catch_53
:goto_57
const-string v6, "2"
invoke-static {v6}, Ljava/lang/Integer;->valueOf(Ljava/lang/String;)Ljava/lang/Integer;
move-result-object v6
invoke-virtual {v6}, Ljava/lang/Integer;->intValue()I
move-result v192
const/4 v6, 0x2
move/from16 v0, v192
if-lt v0, v6, :cond_32
move-object/from16 v0, p0
iget-object v6, v0, Lcom/android/server/SystemServer;->mSystemServiceManager:Lcom/android/server/SystemServiceManager;
const-string v7, "com.android.server.aod.AODManagerService"
invoke-virtual {v6, v7}, Lcom/android/server/SystemServiceManager;->startService(Ljava/lang/String;)Lcom/android/server/SystemService;
:cond_32
:try_start_86
const-string v6, "SystemServer"
Now add the Green lines:
Code:
const-string/jumbo v6, "spengestureservice"
new-instance v7, Lcom/android/server/smartclip/SpenGestureManagerService;
move-object/from16 v0, v218
invoke-direct {v7, v5, v0}, Lcom/android/server/smartclip/SpenGestureManagerService;-><init>(Landroid/content/Context;Lcom/android/server/wm/WindowManagerService;)V
invoke-static {v6, v7}, Landroid/os/ServiceManager;->addService(Ljava/lang/String;Landroid/os/IBinder;)V
:try_end_85
.catch Ljava/lang/Throwable; {:try_start_85 .. :try_end_85} :catch_53
:goto_57
[COLOR="DarkGreen"]move-object/from16 v0, p0
iget-object v6, v0, Lcom/android/server/SystemServer;->mSystemServiceManager:Lcom/android/server/SystemServiceManager;
const-string v7, "com.android.server.cocktailbar.CocktailBarManagerService"
invoke-virtual {v6, v7}, Lcom/android/server/SystemServiceManager;->startService(Ljava/lang/String;)Lcom/android/server/SystemService;[/COLOR]
const-string v6, "2"
invoke-static {v6}, Ljava/lang/Integer;->valueOf(Ljava/lang/String;)Ljava/lang/Integer;
move-result-object v6
invoke-virtual {v6}, Ljava/lang/Integer;->intValue()I
move-result v192
const/4 v6, 0x2
move/from16 v0, v192
if-lt v0, v6, :cond_32
move-object/from16 v0, p0
iget-object v6, v0, Lcom/android/server/SystemServer;->mSystemServiceManager:Lcom/android/server/SystemServiceManager;
const-string v7, "com.android.server.aod.AODManagerService"
invoke-virtual {v6, v7}, Lcom/android/server/SystemServiceManager;->startService(Ljava/lang/String;)Lcom/android/server/SystemService;
:cond_32
:try_start_86
const-string v6, "SystemServer"
LOCATE TO:
smali/com/android/server/power/PowerManagerService.smali
Click to expand...
Click to collapse
SEARCH FOR:
Code:
[COLOR="Red"]const-string v8, "SEC_PRODUCT_FEATURE_COMMON_SUPPORT_COCKTAIL_FW: false"[/COLOR]
REPLACE IT WITH:
Code:
[COLOR="darkgreen"]const-string v8, "SEC_PRODUCT_FEATURE_COMMON_SUPPORT_COCKTAIL_FW: true"[/COLOR]
LOCATE TO:
smali/com/android/server/notification/NotificationManagerService$6.smali
Click to expand...
Click to collapse
SEARCH FOR:
Code:
[COLOR="Red"].method public enqueueEdgeNotification(Ljava/lang/String;Ljava/lang/String;ILandroid/os/Bundle;I)V
[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
Code:
.method public enqueueEdgeNotification(Ljava/lang/String;Ljava/lang/String;ILandroid/os/Bundle;I)V
.locals 8
return-void
.end method
Now Replace the Whole method with this one:
Code:
[COLOR="darkgreen"].method public enqueueEdgeNotification(Ljava/lang/String;Ljava/lang/String;ILandroid/os/Bundle;I)V
.locals 8
# invokes: Lcom/android/server/notification/NotificationManagerService;->checkCallerIsSystemOrSameApp(Ljava/lang/String;)V
invoke-static {p1}, Lcom/android/server/notification/NotificationManagerService;->access$3700(Ljava/lang/String;)V
iget-object v0, p0, Lcom/android/server/notification/NotificationManagerService$6;->this$0:Lcom/android/server/notification/NotificationManagerService;
invoke-static {}, Landroid/os/Binder;->getCallingUid()I
move-result v3
invoke-static {}, Landroid/os/Binder;->getCallingPid()I
move-result v4
move-object v1, p1
move-object v2, p2
move v5, p3
move-object v6, p4
move v7, p5
invoke-virtual/range {v0 .. v7}, Lcom/android/server/notification/NotificationManagerService;->enqueueEdgeNotificationInternal(Ljava/lang/String;Ljava/lang/String;IIILandroid/os/Bundle;I)V
return-void
.end method[/COLOR]
In Same Smali
SEARCH FOR:
Code:
[COLOR="Red"].method public removeEdgeNotification(Ljava/lang/String;ILandroid/os/Bundle;I)V
[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
Code:
.method public removeEdgeNotification(Ljava/lang/String;ILandroid/os/Bundle;I)V
.locals 7
return-void
.end method
Now Replace the Whole method with this one:
Code:
[COLOR="darkgreen"].method public removeEdgeNotification(Ljava/lang/String;ILandroid/os/Bundle;I)V
.locals 7
# invokes: Lcom/android/server/notification/NotificationManagerService;->checkCallerIsSystemOrSameApp(Ljava/lang/String;)V
invoke-static {p1}, Lcom/android/server/notification/NotificationManagerService;->access$3700(Ljava/lang/String;)V
invoke-static {}, Landroid/os/Binder;->getCallingPid()I
move-result v0
invoke-static {}, Landroid/os/Binder;->getCallingUid()I
move-result v1
const/4 v3, 0x1
const/4 v4, 0x0
const-string v5, "cancelNotificationWithTag"
move v2, p4
move-object v6, p1
invoke-static/range {v0 .. v6}, Landroid/app/ActivityManager;->handleIncomingUser(IIIZZLjava/lang/String;Ljava/lang/String;)I
move-result p4
iget-object v0, p0, Lcom/android/server/notification/NotificationManagerService$6;->this$0:Lcom/android/server/notification/NotificationManagerService;
invoke-static {}, Landroid/os/Binder;->getCallingUid()I
move-result v1
invoke-static {}, Landroid/os/Binder;->getCallingPid()I
move-result v2
move-object v3, p1
move v4, p2
move-object v5, p3
move v6, p4
invoke-virtual/range {v0 .. v6}, Lcom/android/server/notification/NotificationManagerService;->removeEdgeNotificationInternal(IILjava/lang/String;ILandroid/os/Bundle;I)V
return-void
.end method[/COLOR]
Done
3. Now Recompile your " services.jar "
4. *Now Decompile your " Framework.jar "
LOCATE TO:
smali/android/app/NotificationManager.smali
Click to expand...
Click to collapse
SEARCH FOR:
Code:
[COLOR="Red"].method constructor <init>(Landroid/content/Context;Landroid/os/Handler;)V[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
Code:
.method constructor <init>(Landroid/content/Context;Landroid/os/Handler;)V
.locals 3
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
iput-object p1, p0, Landroid/app/NotificationManager;->mContext:Landroid/content/Context;
return-void
.end method
Now add the Green lines:
Code:
.method constructor <init>(Landroid/content/Context;Landroid/os/Handler;)V
[COLOR="DarkGreen"].locals 4[/COLOR]
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
iput-object p1, p0, Landroid/app/NotificationManager;->mContext:Landroid/content/Context;
[COLOR="darkgreen"]new-instance v0, Landroid/app/NotificationManager$EdgeNotificationManager;
invoke-direct {v0, p1}, Landroid/app/NotificationManager$EdgeNotificationManager;-><init>(Landroid/content/Context;)V
iput-object v0, p0, Landroid/app/NotificationManager;->mEdgeNotificationManager:Landroid/app/NotificationManager$EdgeNotificationManager;[/COLOR]
return-void
.end method
LOCATE TO:
smali/android/app/SystemServiceRegistry.smali
Click to expand...
Click to collapse
SEARCH FOR:
Code:
[COLOR="Red"]const-string/jumbo v1, "multiwindow_facade"[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
Code:
const-string/jumbo v1, "multiwindow_facade"
const-class v2, Lcom/samsung/android/multiwindow/MultiWindowFacade;
new-instance v3, Landroid/app/SystemServiceRegistry$83;
invoke-direct {v3}, Landroid/app/SystemServiceRegistry$83;-><init>()V
invoke-static {v1, v2, v3}, Landroid/app/SystemServiceRegistry;->registerService(Ljava/lang/String;Ljava/lang/Class;Landroid/app/SystemServiceRegistry$ServiceFetcher;)V
const-string v1, "2"
invoke-static {v1}, Ljava/lang/Integer;->valueOf(Ljava/lang/String;)Ljava/lang/Integer;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/Integer;->intValue()I
move-result v0
const/4 v1, 0x2
if-lt v0, v1, :cond_1
const-string v1, "AODManagerService"
const-class v2, Lcom/samsung/android/aod/AODManager;
new-instance v3, Landroid/app/SystemServiceRegistry$87;
invoke-direct {v3}, Landroid/app/SystemServiceRegistry$87;-><init>()V
invoke-static {v1, v2, v3}, Landroid/app/SystemServiceRegistry;->registerService(Ljava/lang/String;Ljava/lang/Class;Landroid/app/SystemServiceRegistry$ServiceFetcher;)V
:cond_1
const-string/jumbo v1, "spengestureservice"
Now add the Green lines:
Code:
const-string/jumbo v1, "multiwindow_facade"
const-class v2, Lcom/samsung/android/multiwindow/MultiWindowFacade;
new-instance v3, Landroid/app/SystemServiceRegistry$83;
invoke-direct {v3}, Landroid/app/SystemServiceRegistry$83;-><init>()V
invoke-static {v1, v2, v3}, Landroid/app/SystemServiceRegistry;->registerService(Ljava/lang/String;Ljava/lang/Class;Landroid/app/SystemServiceRegistry$ServiceFetcher;)V
[COLOR="darkgreen"]const-string v1, "CocktailBarService"
const-class v2, Lcom/samsung/android/cocktailbar/CocktailBarManager;
new-instance v3, Landroid/app/SystemServiceRegistry$85;
invoke-direct {v3}, Landroid/app/SystemServiceRegistry$85;-><init>()V
invoke-static {v1, v2, v3}, Landroid/app/SystemServiceRegistry;->registerService(Ljava/lang/String;Ljava/lang/Class;Landroid/app/SystemServiceRegistry$ServiceFetcher;)V[/COLOR]
const-string v1, "2"
invoke-static {v1}, Ljava/lang/Integer;->valueOf(Ljava/lang/String;)Ljava/lang/Integer;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/Integer;->intValue()I
move-result v0
const/4 v1, 0x2
if-lt v0, v1, :cond_1
const-string v1, "AODManagerService"
const-class v2, Lcom/samsung/android/aod/AODManager;
new-instance v3, Landroid/app/SystemServiceRegistry$87;
invoke-direct {v3}, Landroid/app/SystemServiceRegistry$87;-><init>()V
invoke-static {v1, v2, v3}, Landroid/app/SystemServiceRegistry;->registerService(Ljava/lang/String;Ljava/lang/Class;Landroid/app/SystemServiceRegistry$ServiceFetcher;)V
:cond_1
const-string/jumbo v1, "spengestureservice"
5. Now Download
The " SystemServiceRegistry$85.smali " and
Add it to " framework.jar\smali\android\app "
Download From Here ->> View attachment SystemServiceRegistry$85.rar
Done
6. Now Recompile your " framework.jar "
7. Download the Attached
System Folder For " Edge Apks, Permissions Xmls "
Add them to correct location into your System Folder
Download From Here ->> https://www.androidfilehost.com/?fid=457095661767134120
Thank you
If Anyone has Access code Error, then only follow this post #2
Then Match the Access Code in the two smalis as below
LOCATE TO:
smali/com/android/server/notification/NotificationManagerService$6.smali
Click to expand...
Click to collapse
SEARCH FOR:
Code:
[COLOR="Red"].method public enqueueEdgeNotification(Ljava/lang/String;Ljava/lang/String;ILandroid/os/Bundle;I)V
[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
See the Red Code, the access code should be same in NotificationManagerService.smali Also
Code:
.method public enqueueEdgeNotification(Ljava/lang/String;Ljava/lang/String;ILandroid/os/Bundle;I)V
.locals 8
# invokes: Lcom/android/server/notification/NotificationManagerService;->checkCallerIsSystemOrSameApp(Ljava/lang/String;)V
invoke-static {p1}, Lcom/android/server/notification/NotificationManagerService;->[COLOR="Red"][B]access$3700[/B][/COLOR](Ljava/lang/String;)V
iget-object v0, p0, Lcom/android/server/notification/NotificationManagerService$6;->this$0:Lcom/android/server/notification/NotificationManagerService;
LOCATE TO:
smali/com/android/server/notification/NotificationManagerService.smali
Click to expand...
Click to collapse
SEARCH FOR:
Code:
[COLOR="Red"].method static synthetic access$3700(Ljava/lang/String;)V
[/COLOR]
YOU SHOULD SEE SOMETHING LIKE THIS:
See the Red Code, the access code is same as in NotificationManagerService$6.smali
Code:
.method static synthetic [COLOR="Red"][B]access$3700[/COLOR][/B](Ljava/lang/String;)V
.locals 0
invoke-static {p0}, Lcom/android/server/notification/NotificationManagerService;->checkCallerIsSystemOrSameApp(Ljava/lang/String;)V
return-void
.end method
Also make sure that access$3700 access right on NotificationManagerService
Hi mate @yash92duster, do you know how to make the background to blur? really needed... thank's before
Axl_Rush said:
Hi mate @yash92duster, do you know how to make the background to blur? really needed... thank's before
Click to expand...
Click to collapse
What background?
Explain more
Where you needed blur?
yash92duster said:
What background?
Explain more
Where you needed blur?
Click to expand...
Click to collapse
I mean, i want to make this blur. I have change in system/lib/libsurface.so but my phone dont even boot.
Axl_Rush said:
I mean, i want to make this blur. I have change in system/lib/libsurface.so but my phone dont even boot.
Click to expand...
Click to collapse
if you have S5 then that blur lib will work
it works fine on S5 G900F and G900H - no issues
if you tried this mod and blur lib on different device
specify the device model, stock rom or port rom
if you had tried on A Series device then native blur wont work
if J series also in some variants it wont work
so give more info so that i can see if i can help
yash92duster said:
if you have S5 then that blur lib will work
it works fine on S5 G900F and G900H - no issues
if you tried this mod and blur lib on different device
specify the device model, stock rom or port rom
if you had tried on A Series device then native blur wont work
if J series also in some variants it wont work
so give more info so that i can see if i can help
Click to expand...
Click to collapse
Oh I see.. Well ok my friend...
My device is J700F running on stock MM Indonesia firmware
I appreciate for your work and for your help my friend.. thank U
and sorry for my bad english
Axl_Rush said:
Oh I see.. Well ok my friend...
My device is J700F running on stock MM Indonesia firmware
I appreciate for your work and for your help my friend.. thank U
and sorry for my bad english
Click to expand...
Click to collapse
you can try to enable the EDGE PANELS in your J Series Device
but
Blur lib wont work on J series ( Many tried and failed )
only way for you is to use ACER BLUR to edge panels
Check for acer blur in
https://forum.xda-developers.com/showthread.php?t=2799050
https://forum.xda-developers.com/ga...ified-development/devs-helpingd-devs-t3321679
yash92duster said:
you can try to enable the EDGE PANELS in your J Series Device
but
Blur lib wont work on J series ( Many tried and failed )
only way for you is to use ACER BLUR to edge panels
Check for acer blur in
https://forum.xda-developers.com/showthread.php?t=2799050
https://forum.xda-developers.com/ga...ified-development/devs-helpingd-devs-t3321679
Click to expand...
Click to collapse
Ok i will try it.... thank's mate :good::good:
@yash92duster : this method really working on pure stock S5 MM? I tried many times but always FC when swipe... from another guide also..and tried your framework ans services.jar that you share on that guide, but still FC.
maybe something missing on pure stock. If anyone have success on pure stock, please share the framework & service.jar, me and others will greatly appreciate it.
thanks working fine in AJ A8 Rom
@yash92duster
nice guide, very well done. I was wondering if this would work on Nougat 7.X.X too...
I am trying to port that Galaxy Tab A, but when I decompile framework.jar, nothing really...in fact, its framework.jar is only 14kb size..so probably Samsung move that stuff somewhere in Galaxy Tab A...no idea..
jazzespresso said:
@yash92duster
nice guide, very well done. I was wondering if this would work on Nougat 7.X.X too...
I am trying to port that Galaxy Tab A, but when I decompile framework.jar, nothing really...in fact, its framework.jar is only 14kb size..so probably Samsung move that stuff somewhere in Galaxy Tab A...no idea..
Click to expand...
Click to collapse
Bad deodex
Lol
yash92duster said:
Bad deodex
Lol
Click to expand...
Click to collapse
oh crap...yeah saw -- Framework\arm folder is still there...funny though, it deodexed some, but not all...
what deodex utility you use usually?
jazzespresso said:
oh crap...yeah saw -- Framework\arm folder is still there...funny though, it deodexed some, but not all...
what deodex utility you use usually?
Click to expand...
Click to collapse
Use
Assayyed
It works perfectly till 7.0
7.1.1 also works in assayyed but for framework folder alone use flumics tool
yash92duster said:
Use
Assayyed
It works perfectly till 7.0
7.1.1 also works in assayyed but for framework folder alone use flumics tool
Click to expand...
Click to collapse
yeah I used Assayyed cook my ROM, so assumed it deodexed fine, then found out today, it is not...
it seems like, build ROM with Assayyed Kitchen, and switch over to flumics tool to deodex and copy back to Assayyed and finish the build
I got all figured out now..
following your guide up until framework.jar, smali/android/app/SystemServiceRegistry.smali, and search for "multiwindow_facade", which does not find in the file (found all other though) but i added Green lines change in the file anyway...
have not tested yet, we will see if it works:good:
jazzespresso said:
yeah I used Assayyed cook my ROM, so assumed it deodexed fine, then found out today, it is not...
it seems like, build ROM with Assayyed Kitchen, and switch over to flumics tool to deodex and copy back to Assayyed and finish the build
I got all figured out now..
following your guide up until framework.jar, smali/android/app/SystemServiceRegistry.smali, and search for "multiwindow_facade", which does not find in the file (found all other though) but i added Green lines change in the file anyway...
have not tested yet, we will see if it works:good:
Click to expand...
Click to collapse
Better ask in right place
This is not kitchen thread:silly:
yash92duster said:
Better ask in right place
This is not kitchen thread:silly:
Click to expand...
Click to collapse
wasn't really kitchen question, read my post again
Screenshots?

Categories

Resources