[MOD] Inverted Full Screen KeyBoard/Text edit(Landscape) - Verizon Samsung Galaxy S 4

Finally tracked this one down, and just have to share this...
This Mod was found by @EMSpilot and @Gunthermic.. emspilot found the routine, and from there we figured the rest.. Give him a big kudos..
This is a MOD for Dev's to incorperate, this is NOT an End User MOD.
I have broken this down to each part of the inversion for those that want complete control over the Full Screen KeyBoard Layout.
1. Text Color
2. Cusor Color
3. BackGround Color
4. HighLight Color
What:
Framework.jar
framework-res.apk
Decompile Framework.jar file
Add/Change
Subtract/Delete
Go to:
smali\android\inputmethodservice\InputMethodService.smali
Search for:
.method startExtractingText(Z)V
Look for this code:
1. Text Color:
Code:
iget-object v8, v2, Landroid/view/inputmethod/EditorInfo;->hintText:Ljava/lang/CharSequence;
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setHint(Ljava/lang/CharSequence;)V
Right under that is:
Code:
const/4 v8, 0x0
const/4 v9, 0x0
const/4 v10, 0x0
invoke-static {v8, v9, v10}, Landroid/graphics/Color;->rgb(III)I
move-result v8
invoke-static {v8}, Landroid/content/res/ColorStateList;->valueOf(I)Landroid/content/res/ColorStateList;
The above code controls the text coloring on the Text Box. You have two options:
You can change the v8, v9, v10 which is the RGB value (0x0) is Black in this case and change them to -0x1 for each one to make text color white.
The second option you can do if you want a special color without having to figure out RGB color coding is to add:
const v8, smali colorcode (for example -0xCC9934(DarkHorse Blue)) below move-result v8.. like so...
invoke-static {v8, v9, v10}, Landroid/graphics/Color;->rgb(III)I
Code:
move-result v8
[COLOR="Blue"]const v8, -0xCC9934[/COLOR]
invoke-static {v8}, Landroid/content/res/ColorStateList;->valueOf(I)Landroid/content/res/ColorStateList;
Okay the next three items are much easier:
Right under the code for Text Coloring is the rest of the Inversion and other Changes
Code:
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setTextColor(Landroid/content/res/ColorStateList;)V
const/high16 v8, -0x100 # Cusor Color
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setCursorColor(I)V
.line 3261
const/4 v8, -0x1 #Background Color
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setBackgroundColor(I)V
.line 3265
const v8, -0x86350e #HighLight Cusor Color
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setHighlightColor(I)V
Code Changes: An Example of my changes
Code:
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setTextColor(Landroid/content/res/ColorStateList;)V
[COLOR="Blue"]const v8, -0x100 [/COLOR]#Cusor Color(Yellow)
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setCursorColor(I)V
[COLOR="Blue"]const v8, -0x1000000 [/COLOR]#BackGround(Black)
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setBackgroundColor(I)V
[COLOR="Blue"]const v8, -0xCC9934[/COLOR] #HighLight Cusor Color.(DarkHorse Blue)
invoke-virtual {v1, v8}, Landroid/inputmethodservice/ExtractEditText;->setHighlightColor(I)V
Okay Save that. One more Item that needs to be done complete the Inversion!!!
framework/res/layout/input_method_extract_view.xml
Line 5 needs to be changed to complete the inversion(makes the black appear around the Send button)
Code:
<FrameLayout android:id="@id/inputExtractAccessories" [COLOR="Blue"]android:background="#ff000000"[/COLOR] android:layout_width="wrap_content" android:layout_height="fill_parent" android:paddingStart="8.0dip" android:paddingEnd="8.0dip">
<android.inputmethodservice.ExtractButton android:layout_gravity="center" android:id="@id/inputExtractAction" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<android.inputmethodservice.ExtractButton android:layout_gravity="center" android:id="@id/inputExtractEditButton" android:visibility="invisible" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/extract_edit_menu_button" />
</FrameLayout>
Save and Compile framework.jar and framework-res.apk..
Score!!!!

Related

[GUIDE][MOD][GB]Settings Shortcut in StatusBar [New method] 25/02/2013

Well,this new method is much much easier than the old method.Minimal smali editing is involved.So even newbies can follow it.
Click to expand...
Click to collapse
You are going to need
1.SystemUI.apk
2.Apk manager,virtuos ten studio or any apk compiling/decompiling tool
3.Notepad++
4.Patience and some time.
Click to expand...
Click to collapse
STEP 1Decompile your SystemUI.apk and go to status_bar_expanded.xml.Open the file and look for this (stock systemUI).
Code:
<com.android.systemui.statusbar.CarrierLabel android:textSize="17.659973dip" android:textColor="#ffffffff" android:layout_gravity="center_vertical" android:orientation="vertical" android:paddingBottom="1.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="5.0dip" android:layout_marginTop="1.0dip" android:layout_weight="1.0" />
paste this code below that
Code:
<ImageView android:layout_gravity="center_vertical" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/ic_notify_quicksettings"[COLOR="Red"] android:onClick="settingsButton"[/COLOR] />
Now save the file.
Code:
[COLOR="Red"] android:onClick="settingsButton"[/COLOR]
is an xml attribute used to call a method when pressing something.Now the settingsButton is the name of the method.
Note;It doesnt matter where you put the code for settings button in statusbar expanded.The above steps are for sgy users.You can put that code anywhere you want.But think logical and use common sense.
STEP 2 Now we can add the method settingsButton to StatusBarService.smali.Open the file and look for the code
Code:
# virtual methods
Paste this method below
Code:
.method public settingsButton(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 1717
invoke-virtual {p1}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v0
new-instance v1, Landroid/content/Intent;
const-string v2, "android.settings.SETTINGS"
invoke-direct {v1, v2}, Landroid/content/Intent;-><init>(Ljava/lang/String;)V
const/high16 v2, 0x1000
invoke-virtual {v1, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
invoke-virtual {p0}, Lcom/android/systemui/statusbar/StatusBarService;->animateCollapse()V
.line 1720
return-void
.end method
Now save the file.
android.settings.SETTINGS is the intent for calling settings app activity.You can change the intent to call diffrent activities.For example
android.settings.WIRELESS_SETTINGS -wireless and network settings
android.settings.WIFI_SETTINGS -Wifi settings
android.intent.action.POWER_USAGE_SUMMARY -Battery usage summary
Click to expand...
Click to collapse
STEP 3Now download and extract this Settings_shortcut_drawables.zip.Put the ic_notify_quicksettings.xml inside your drawable folder and the the other two pngs inside drawable-ldpi folder.
STEP 4Now compile and push.
Before asking doubts think twice always.If there is any error in the codes,do let me know.Happy to help.​
Click to expand...
Click to collapse
Old method
Actually this mod is not made by me.I've just ported it and found the way to implement this in other roms.I've studied the SystemUI.apk from the theme by C.O.D.<D.J> for creed's rom.So all credit goes to him
EDIT:There is a small correction in the code
Code:
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/StatusBarService$8;-><init>(Lcom/android/systemui/statusbar/StatusBarService;)V
.I've forgot to add <init> after 'StatusBarService$8;->' in the guide.Thanks to 'chevanlol360' for pointing out this error.
Click to expand...
Click to collapse
It's easy if you follow every step correctly
STEP 1: Decompile the SystemUI.apk.There are several threads around xda to show you how to decompile an apk.Navigate to res/layout/ and find status_bar_expanded.xml.Find the following code in the file
Code:
<com.android.systemui.statusbar.CarrierLabel android:textSize="17.659973dip" android:textColor="#ffffffff" android:layout_gravity="center_vertical" android:orientation="vertical" android:paddingBottom="1.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="5.0dip" android:layout_marginTop="1.0dip" android:layout_weight="1.0" />
Paste this code just below it
Code:
<ImageView android:layout_gravity="center_vertical" android:id="@id/settings_button" android:paddingLeft="0.0dip" android:paddingTop="0.0dip" android:paddingRight="8.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/ic_notify_quicksettings" android:contentDescription="@string/accessibility_settings_button" />
Now save and close the file.
STEP 2.Open res/values/strings.xml.And add this line at the end
Code:
<string name="accessibility_settings_button">System settings.</string>
Save and close the file
STEP 3.Open res/values/ids.xml and paste this code at the end
Code:
<item type="id" name="settings_button">false</item>
Save and close the file.
STEP 4.Now extract the files from the attached zip.Take "ic_notify_quicksettings.xml' and put it in res/drawable/.Take 'ic_settings_normal.png' and 'ic_settings_pressed.png' and put it in res/drawable-ldpi/.
Now recompile the apk and push it to system/app to make sure the settings button is there and everything look right.Now decompile that systemUI.apk again.Navigate to res/values/ .We need to find an id from public.xml
STEP 5.Now open public.xml and find this line
Code:
<public type="id" name="settings_button" id="[COLOR="Red"]0x7f090027[/COLOR]" />
Remember the id highlighted in red above.We need to use it.
STEP 6.Open StatusBarService.smali and find this line of code
Code:
.field mScrollView:Landroid/widget/ScrollView;
Paste this code below it
Code:
.field mSettingsBut:Landroid/view/View;
.field private mSettingsButListener:Landroid/view/View$OnClickListener;
Now find this code
Code:
iput-object v0, p0, Lcom/android/systemui/statusbar/StatusBarService;->mStopTracing:Ljava/lang/Runnable;
Paste this code below
Code:
.line 1703
new-instance v0, Lcom/android/systemui/statusbar/StatusBarService$8;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/StatusBarService$8;-><init>(Lcom/android/systemui/statusbar/StatusBarService;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/StatusBarService;->mSettingsButListener:Landroid/view/View$OnClickListener;
return-void
Now again find this code
Code:
iput v7, p0, Lcom/android/systemui/statusbar/StatusBarService;->mEdgeBorder:I
And paste this code below
Code:
.line 333
const v7, [COLOR="Red"]0x7f090027[/COLOR]
invoke-virtual {v1, v7}, Lcom/android/systemui/statusbar/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v7
iput-object v7, p0, Lcom/android/systemui/statusbar/StatusBarService;->mSettingsBut:Landroid/view/View;
.line 334
iget-object v7, p0, Lcom/android/systemui/statusbar/StatusBarService;->mSettingsBut:Landroid/view/View;
iget-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mSettingsButListener:Landroid/view/View$OnClickListener;
invoke-virtual {v7, v8}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
The id highlighted in red must be the same as the id from public.xml.So make sure it's the same.Now save and close the file.
STEP 7.Take 'StatusBarService$8.smali' from the attached zip an put it in com/android/systemui/statusbar/.
STEP 8.Now recompile the apk and push it to system/app/ and put the permission rw--r--r--.
If you want to get the feel of it in your stock statusbar i've made one for you just in case. Download it from here:
DOWNLOAD
{
"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"
}
Flash it through recovery.If you are running an odexed rom,delete SystemUI.odex from system/app before you flash the zip.​
Awesome tutorial....
Will impliment this in my upcoming custom rom....lol
great tutorial, but stuck on first step as i cant find those lines in my statusbarexpanded.xml , btw i have a galaxy gio but here is my systemui, can you take a look? :good:
alkspo said:
great tutorial, but stuck on first step as i cant find those lines in my statusbarexpanded.xml , btw i have a galaxy gio but here is my systemui, can you take a look? :good:
Click to expand...
Click to collapse
I'll look into it.I'm not near my pc.Actually step 1 puts the settings left to carrier text.You can add that code before the code for clear button.
sent while doin' some burnouts
alright, will tr, thanks
How to move 15toogle to down settings button
alkspo said:
great tutorial, but stuck on first step as i cant find those lines in my statusbarexpanded.xml , btw i have a galaxy gio but here is my systemui, can you take a look? :good:
Click to expand...
Click to collapse
if the Statusbar have this code :
Code:
.line 338
.local v4, qsv:Lcom/android/systemui/statusbar/quickpanel/QuickSettingsView;
const-string v8, "ro.csc.sales_code"
invoke-static {v8}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v1
.line 339
.local v1, code:Ljava/lang/String;
const-string v8, "XEC"
invoke-virtual {v8, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v8
if-eqz v8, :cond_1
you can delete it ,
If the statusbar have this :
Code:
.line 340
const v8, 0x7f030003
invoke-static {p1, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
move-result-object v4
.end local v4 #qsv:Lcom/android/systemui/statusbar/quickpanel/QuickSettingsView;
check-cast v4, Lcom/android/systemui/statusbar/quickpanel/QuickSettingsView;
.line 348
.restart local v4 #qsv:Lcom/android/systemui/statusbar/quickpanel/QuickSettingsView;
:goto_0
iget-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mExpandedView:Lcom/android/systemui/statusbar/ExpandedView;
invoke-virtual {v8, v4, v13}, Lcom/android/systemui/statusbar/ExpandedView;->addView(Landroid/view/View;I)V
and delete this :
Code:
.line 344
:cond_1
const v8, 0x3030003
invoke-static {p1, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
move-result-object v4
check-cast v4, Lcom/lidroid/systemui/quickpanel/PowerWidget;
.local v4, qsv:Lcom/lidroid/systemui/quickpanel/PowerWidget;
invoke-virtual {v4}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setupWidget()V
goto :goto_0
you can change into :
so the line like as :
Code:
.line 337
const/4 v4, 0x0
.line 344
const v8, 0x3030003
invoke-static {p1, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
move-result-object v4
check-cast v4, Lcom/lidroid/systemui/quickpanel/PowerWidget;
.line 348
.local v4, qsv:Lcom/lidroid/systemui/quickpanel/PowerWidget;
const/4 v9, 0x1
invoke-virtual {v4}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setupWidget()V
iget-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mExpandedView:Lcom/android/systemui/statusbar/ExpandedView;
invoke-virtual {v8, v4, v9}, Lcom/android/systemui/statusbar/ExpandedView;->addView(Landroid/view/View;I)V
.line 352
new-instance v8, Landroid/widget/LinearLayout;
invoke-direct {v8, p1}, Landroid/widget/LinearLayout;-><init>(Landroid/content/Context;)V
iput-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mMiniCon:Landroid/widget/LinearLayout;
.line 353
iget-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mMiniCon:Landroid/widget/LinearLayout;
const/4 v9, 0x1
invoke-virtual {v8, v9}, Landroid/widget/LinearLayout;->setOrientation(I)V
.line 354
iget-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mExpandedView:Lcom/android/systemui/statusbar/ExpandedView;
invoke-virtual {v8, v12}, Lcom/android/systemui/statusbar/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v8
check-cast v8, Landroid/widget/LinearLayout;
iget-object v9, p0, Lcom/android/systemui/statusbar/StatusBarService;->mMiniCon:Landroid/widget/LinearLayout;
invoke-virtual {v8, v9, v13}, Landroid/widget/LinearLayout;->addView(Landroid/view/View;I)V
.line 358
const v8, 0x7f030005
invoke-static {p1, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
move-result-object v8
check-cast v8, Lcom/android/systemui/statusbar/CallOnGoingView;
iput-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mCallOnGoingView:Lcom/android/systemui/statusbar/CallOnGoingView;
.line 359
iget-object v8, p0, Lcom/android/systemui/statusbar/StatusBarService;->mCallOnGoingView:Lcom/android/systemui/statusbar/CallOnGoingView;
iput-object p0, v8, Lcom/android/systemui/statusbar/CallOnGoingView;->mService:Lcom/android/systemui/statusbar/StatusBarService;
.line 361
return-void
.end method
Here you go , iam modify you systemui . view you new systemui . and Trying to Experiment xD . view my attatch
and i thinks the Guide not working on CM .
Thanks you, AWESOME Guide
Thanks for this tutorial mate! awesome as always will try this after i come back..
Boooom..! Pin! Thanks for this great tut bro... now i know.. i really mis the smalis.. haha i really hate smali...
____________________________________
Reserve for future use..
send thru postal codes supported with busybox command again
thanks for doing it for me, but my device is mdpi not hdpi, so will not work, can you make it again?
alkspo said:
thanks for doing it for me, but my device is mdpi not hdpi, so will not work, can you make it again?
Click to expand...
Click to collapse
If the resolution png (too small) with a resolution of handle you then I rename a ldpi, if png (fit) with a screen resolution of your handle then I rename a mdpi, if the png does not fit the screen resolution of your handle (too big) then I rename a hdpi .
thats trick to make png no zoom ( big or small icon ) . and make to past you screen resolution .
try my mods . push to system/app
sorry for bad english
oh i see what you mean, yes so it wont zoom in thanks, i tried it but it looks a bit messed up, can you put the date and the setting and x button under the toggles? or is that too much trouble ? o: i like have the toggle at the very top, and might fix overlap if do that thanks alot here is screenie
Thanks for the tut
Inviato dal mio GT-S5830i con Tapatalk 2
The codes in sgyd differ a little bit... failed on my first try... trying it again
hell_lock said:
The codes in sgyd differ a little bit... failed on my first try... trying it again
Click to expand...
Click to collapse
Try it in your sgy.It's easier to port if it works.
sent while doin' some burnouts
b16h22 said:
Try it in your sgy.It's easier to port if it works.
sent while doin' some burnouts
Click to expand...
Click to collapse
Yudhiez managed to make it fully working for me, but the date and settings and clear button is on top of toggles, while the one in your screenshot is below, how do i rearrange it? o:
Haha told it to samsoul16 bro he had this questions now u explain it good thanks pressed
Sent from my GT-S5360 using Xparent ICS Blue Tapatalk 2
Wow this tutorial is great. Thanks friend.
HYPOCRITES I'm gonna do it blind
HYPOCRITES your messiah was never mine!
beautiful. :good:
Galaxy Ace s5830i
Hey,I tried to add this is Galaxy Ace S5830i.
I don't have StatusBarService$7.smali,so I renamed StatusBarService$8.smali to StatusBarService$7.smali,and changed all the StatusBarService$8 lines to StatusBarService$7,the same in StatuBarService.smali,but it still not working,can you help me?
This work on stock deodex? Will try
Sent from my GT-S5360 using xda premium

[MOD/GUIDE] Xperia Jelly Bean Style SystemUI | Customize Your Own Statusbar! [18/3]

Hi,
Well, I try to theme ICS systemui to Xperia JB style like Xperia Z.
But this so far the only I can do for now. I hope you guys like it.
More to come. Stay tuned.
Project Finished
Changelog
20/2: Initial release.
21/2: Fixed all statusbar background that cause FC on some user.
03/3: Style Z added. Change colour according to themes colour. (Special thanks to erorcun for the trick)
05/3: Style S added. Thanks to destroyy.
15/3: Special style added. Modified to look more like JB statusbar notification.
18/3: CM style added. Thanks to SpaceCaker.
Preview
{
"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"
}
Brand new statusbar background style.
Style 1
Style 2
Style 3 (Fullscreen)
Style 4
Style Z (Change Color According to Themes)
Style S (Change Color According to Themes)
Style ZN6 (Change Color According to Themes)
Style CM (Change Color According to Themes)
Note
1. Before installing this, please delete any quickpanel setting or systemuipreferences if you using tab systemui before.
2. My systemui support smallapp.
3. Please PM me asking for permission first, if you want to incorporate it into your ROMs.
4. Style 1-4 is known to work for some user only. You need a luck for these
Instruction
1. Flash Universal_part_1.zip and reboot. Did the statusbar appear?
If it doesnt, probably there have problem with your rom. Flash stock rom via flashtool first.
2. If the statusbar appeared, continue to flash Style_x.zip via recovery.
3. Reboot you phone.
Credits
Niaboc79 for original xperia t systemui.
serajr for helping me in smali editing.
leloiboi for some tip and help.
Ticklefish for his tutorial.
erorcun for his trick to change colour according to theme.
destroyy for Sammy style.
SpaceCaker for CM style.
I'm do this for free. Damn... this take huge amount of time especially the smali editing.
Dont just know how to download and flash. Try appreciate my work by hit
.
[Guide/Tutorial] Customize Your Own Statusbar!
[Guide/Tutorial] Customize Your Own Statusbar!
Hi, again.
Some user keep PM'ing me how to change that, that and etc.
So I decide to do a simple guide to customize your own statusbar.
Make sure you have a basic knowledge to compile/decompile apk.
Change Statusbar Background Color
Decompile systemui.apk and navigate to SystemUI/res/values/drawables.xml and edit this line:
Code:
<item type="drawable" name="status_bar_background">#[COLOR="Red"]ff1a1a1a[/COLOR]</item>
Change red content to what ever you line. For more hex color reference, go here
For black color, change it to ff000000.
Save and compile back.
(This method only applicable for Style_Z and later version)
For style 1-4, change status_bar_background.png in drawable-hdpi folder
Look for transparent statusbar? Go here..
Change Navigation Button Background Color
Decompile systemui.apk and navigate to SystemUI/res/layout/navigation_bar.xml and edit this line.
Code:
<com.android.systemui.statusbar.phone.NavigationBarView android:id="@id/nav_background" [COLOR="Red"]android:background="#ff000000"[/COLOR] android:layout_width="fill_parent" android:layout_height="fill_parent" android:directionality="none"
Change red content to what ever you line. For more hex color reference, go here
The original Xperia Z nav backgroud color is ff1a1a1a.
Save and compile back
Change Clock Colour on Statusbar
Decompile systemui.apk and navigate to SystemUI/res/layout/status_bar.xml and find this line:
Code:
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
And change it to this
Code:
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:textColor="#[COLOR="Red"]ff09afed[/COLOR]" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
Change the red content to what ever colour you like. For more hex color reference, go here
Remember! You can also change carrier label color, date, and etc. Just look respective line and xml.
Add Seconds To Statusbar Clock
Decompile systemui.apk and navigate to SystemUI/res/layout/status_bar.xml and find this line:
Code:
[COLOR="Blue"]<com.android.systemui.statusbar.policy.Clock[/COLOR] android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
And replace blue line above with following red line:
Code:
<[COLOR="Red"]DigitalClock[/COLOR] android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
Save change you have made and recompile back.
It easy, right?
Hide Clock,Battery Percentage and etc.
Hide clock.
Decompile systemui.apk and navigate to SystemUI/res/layout/status_bar.xml and find this line:
Code:
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="6.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
and change to this:
Code:
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="6.0dip" [COLOR="Red"]android:visibility="gone"[/COLOR] android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
Hide battery percentage
Find this line:
Code:
<TextView android:layout_gravity="left|center" android:id="@id/battery_text" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" style="@style/StatusBarNotificationText" />
change to this:
Code:
<TextView android:layout_gravity="left|center" android:id="@id/battery_text" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" style="@style/StatusBarNotificationText" [COLOR="Red"]android:visibility="gone"[/COLOR] />
Remember! Just added red word at the end of line you want to hide if you want to hide content on statusbar.
Add Battery Percentage On Statusbar.
Decompile systemui.apk and navigate to SystemUI/res/layout/status_bar.xml and find this line:
Code:
<LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/signal_battery_cluster" android:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
<include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_view" />
<ImageView android:id="@id/battery" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
And add red line below:
Code:
<LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/signal_battery_cluster" android:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
<include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_view" />
[COLOR="Red"]<TextView android:layout_gravity="left|center" android:id="@id/battery_text" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" style="@style/StatusBarNotificationText" />[/COLOR]
<ImageView android:id="@id/battery" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
Save change you have made. After that, look for this smali file:
PhoneStatusBar.smali
Code:
.line 358
iget-object v10, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
const v9, 0x7f0e0028
invoke-virtual {v4, v9}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Landroid/widget/ImageView;
invoke-virtual {v10, v9}, Lcom/android/systemui/statusbar/policy/BatteryController;->addIconView(Landroid/widget/ImageView;)V
and add red lines below:
Code:
.line 358
iget-object v10, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
const v9, 0x7f0e0028
invoke-virtual {v4, v9}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Landroid/widget/ImageView;
invoke-virtual {v10, v9}, Lcom/android/systemui/statusbar/policy/BatteryController;->addIconView(Landroid/widget/ImageView;)V
[COLOR="Red"].line 13
iget-object v10, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
const v9, 0x7f0e0061
invoke-virtual {v4, v9}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Landroid/widget/TextView;
invoke-virtual {v10, v9}, Lcom/android/systemui/statusbar/policy/BatteryController;->addLabelView(Landroid/widget/TextView;)V[/COLOR]
also change the const v9, 0x7f0e0061 to your own value, look for it inside public.xml
Recompile back and flash.
Temporary Hide Statusbar When We Pull SystemUI/Fullscreen (For Advanced User Only)
Find this smali file:
PhoneStatusBar.smali:
Here when the expanded view is about to become visible, we hide the main status bar view (red):
Code:
[B].method private makeExpandedVisible()V[/B]
.line 1194
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const/4 v1, 0x2
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->requestFocus(I)Z
.line 1195
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/TrackingView;->setVisibility(I)V
[COLOR="red"].line 1900
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const/4 v1, 0x4
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->setVisibility(I)V[/COLOR]
goto :goto_0
.end method
Here when the expanded view is gone, we show the main status bar view again (red):
Code:
[B].method performCollapse()V[/B]
.line 1278
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedDialog:Landroid/app/Dialog;
invoke-virtual {v0}, Landroid/app/Dialog;->getWindow()Landroid/view/Window;
move-result-object v0
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedParams:Landroid/view/WindowManager$LayoutParams;
invoke-virtual {v0, v1}, Landroid/view/Window;->setAttributes(Landroid/view/WindowManager$LayoutParams;)V
.line 1279
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
const/16 v1, 0x8
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/TrackingView;->setVisibility(I)V
[COLOR="Red"].line 1900
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->setVisibility(I)V[/COLOR]
.line 1281
iget v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisabled:I
const/high16 v1, 0x2
and-int/2addr v0, v1
if-nez v0, :cond_2
.line 1282
const/4 v0, 0x1
const/high16 v1, 0x10a
invoke-virtual {p0, v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setNotificationIconVisibility(ZI)V
.line 1285
:cond_2
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpanded:Z
if-eqz v0, :cond_0
.line 1288
iput-boolean v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpanded:Z
.line 1289
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPostCollapseCleanup:Ljava/lang/Runnable;
if-eqz v0, :cond_0
.line 1290
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPostCollapseCleanup:Ljava/lang/Runnable;
invoke-interface {v0}, Ljava/lang/Runnable;->run()V
.line 1291
const/4 v0, 0x0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPostCollapseCleanup:Ljava/lang/Runnable;
goto :goto_0
.end method
Now look for:
Code:
Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
You´ll get 6 matches/lines with something like:
Code:
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result v2
Insert red line (respect line spaces) only within following methods:
Code:
.method doAnimation()V
.method doRevealAnimation()V
.method getExpandedHeight(I)I
.method prepareTracking(IZ)V
.method updateExpandedViewPos(I)V
DON´T INSERT INSIDE THIS METHOD:
Code:
.method interceptTouchEvent(Landroid/view/MotionEvent;)Z
Code:
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result v2
[COLOR="red"]const/4 v2, 0x0[/COLOR]
(remember to change v2 to the same as "move-result v?")
Save and Compile. If you still got an error or force close on statusbar, just compare with style 3.
Change Color According to ThemeAccent Color (For Expert User Only)
Download the ThemeUtils.zip in attachment and extract it to smali/com/blah.../blah... You can put ThemeUtils.smali in any directory in smali folder. But when we want to run this file, we need to specific the directory where we put the file. For example,
I put in smali/com/sonymobile/systemui/statusbar/tools/
You will know what I mean
Something have to run this file and provide context object. For example, the main file which contain context object in systemui.apk is SystemUIService.smali. So look for this line:
Code:
.line 91
iget-object v6, p0, Lcom/android/systemui/SystemUIService;->mServices:[Lcom/android/systemui/SystemUI;
aget-object v6, v6, v4
iput-object p0, v6, Lcom/android/systemui/SystemUI;->mContext:Landroid/content/Context;
And added following red line:
Code:
.line 91
iget-object v6, p0, Lcom/android/systemui/SystemUIService;->mServices:[Lcom/android/systemui/SystemUI;
aget-object v6, v6, v4
iput-object p0, v6, Lcom/android/systemui/SystemUI;->mContext:Landroid/content/Context;
[COLOR="Red"]invoke-static {p0}, Lcom/sonymobile/systemui/statusbar/tools/ThemeUtils;->init(Landroid/content/Context;)V[/COLOR]
And save it.
If you want to change the clock color in expanded statusbar for example, find this line in com/android/systemui/statusbar/phone/PhoneStatusBar.smali
Code:
.field mExpanded:Z
.field mExpandedContents:Landroid/view/View;
.field mExpandedDialog:Landroid/app/Dialog;
And add red line:
Code:
.field mExpanded:Z
[COLOR="Red"].field mExpandedClock:Landroid/widget/TextView;[/COLOR]
.field mExpandedContents:Landroid/view/View;
.field mExpandedDialog:Landroid/app/Dialog;
Find this line:
Code:
.line 1227
const/16 v0, -0x2710
invoke-virtual {p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateExpandedViewPos(I)V
And add red line below:
Code:
.line 1227
const/16 v0, -0x2710
invoke-virtual {p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateExpandedViewPos(I)V
[COLOR="Red"]iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedClock:Landroid/widget/TextView;
invoke-static {}, Lcom/sonymobile/systemui/statusbar/tools/ThemeUtils;->getAccentColor()I
move-result v1
invoke-virtual {v0, v1}, Landroid/widget/TextView;->setTextColor(I)V
[/COLOR]
Find this line:
Code:
.line 343
const v9, 0x7f0e003e
invoke-virtual {v1, v9}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Lcom/android/systemui/statusbar/policy/DateView;
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
And add red line below:
Code:
.line 343
const v9, 0x7f0e003e
invoke-virtual {v1, v9}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Lcom/android/systemui/statusbar/policy/DateView;
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
[COLOR="Red"]const v9, 0x7f0e0095
invoke-virtual {v1, v9}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Landroid/widget/TextView;
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedClock:Landroid/widget/TextView;[/COLOR]
Now look for this line:
Code:
.line 1083
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v1, 0x7f0e002b
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
And add red line below:
Code:
.line 1083
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v1, 0x7f0e002b
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
[COLOR="Red"]move-result-object v1
.line 1084
if-eqz v1, :cond_0
.line 1085
if-eqz p1, :cond_1
const/4 v0, 0x0
:goto_0
invoke-virtual {v1, v0}, Landroid/view/View;->setVisibility(I)V
.line 1087
:cond_0
invoke-virtual {p0, p1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->showClockExp(Z)V
return-void
.line 1085
:cond_1
const/16 v0, 0x8
goto :goto_0
.end method
.method public showClockExp(Z)V
.locals 2
.parameter
.prologue
.line 1083
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, 0x7f0e0095
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;[/COLOR]
And save change.
If you want to change the color for button toggle according to theme (colorizing button), look for ToolsButton.smali (com/sonymobile/systemui/statusbar/tools).
Fine this line:
Code:
.method private updateIcon()V
.locals 5
.prologue
.line 239
iget-object v3, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mStateIcons:Ljava/util/HashMap;
iget v4, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mState:I
invoke-static {v4}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v4
invoke-virtual {v3, v4}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v2
check-cast v2, Ljava/lang/Integer;
And change to this:
Code:
.method private updateIcon()V
.locals [COLOR="Red"]6[/COLOR]
.prologue
[COLOR="Red"].line 239
const/4 v5, 0x0
.local v5, applyFilter:Z[/COLOR]
iget-object v3, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mStateIcons:Ljava/util/HashMap;
iget v4, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mState:I
[COLOR="Red"]const/4 v1, 0x1
if-eq v4, v1, :cond_0
const/4 v5, 0x1
:cond_0[/COLOR]
invoke-static {v4}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v4
invoke-virtual {v3, v4}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v2
check-cast v2, Ljava/lang/Integer;
Now look for this line:
Code:
.line 241
.local v1, icon:Landroid/graphics/Bitmap;
if-eqz v2, :cond_0
And change the value to this
Code:
.line 241
.local v1, icon:Landroid/graphics/Bitmap;
if-eqz v2, :[COLOR="Red"]cond_1[/COLOR]
Look for following line:
Code:
.line 249
:cond_0
:goto_0
iget-object v3, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mIcon:Lcom/sonymobile/systemui/uicomponents/Image;
invoke-virtual {v3, v1}, Lcom/sonymobile/systemui/uicomponents/Image;->setBitmap(Landroid/graphics/Bitmap;)V
And change to following red content:
Code:
.line 249
:[COLOR="Red"]cond_1[/COLOR]
:goto_0
iget-object v3, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mIcon:Lcom/sonymobile/systemui/uicomponents/Image;
[COLOR="Red"]invoke-virtual {v3, v1, v5}[/COLOR], Lcom/sonymobile/systemui/uicomponents/Image;->setBitmap(Landroid/graphics/Bitmap;[COLOR="Red"]Z[/COLOR])V
Look for following line and delete red line:
Code:
.line 250
[COLOR="Red"]iget-object v3, p0, Lcom/sonymobile/systemui/statusbar/tools/ToolsButton;->mIcon:Lcom/sonymobile/systemui/uicomponents/Image;[/COLOR]
invoke-virtual {v3}, Lcom/sonymobile/systemui/uicomponents/Image;->invalidate()V
Find this line:
Code:
.line 251
return-void
And add red line below:
Code:
.line 251
[COLOR="Red"].end local v5 #applyFilter:Z[/COLOR]
return-void
Look for following line:
Code:
.line 244
:catch_0
move-exception v0
And like usual, add following line:
Code:
.line 244
[COLOR="Red"].restart local v5 #applyFilter:Z[/COLOR]
:catch_0
move-exception v0
And save change you have made.
Now the last part is change the image.smali (com/sonymobile/systemui/uicomponents/)
Look for following line and add red line:
Code:
# instance fields
[COLOR="Red"].field protected mApplyFilter:Z[/COLOR]
.field protected mBitmap:Landroid/graphics/Bitmap;
.field protected final mMatrix:Landroid/graphics/Matrix;
.field protected mScalingX:F
.field protected mScalingY:F
Look for following line:
Code:
.method public constructor <init>(Ljava/lang/String;Landroid/graphics/Bitmap;)V
.locals 1
.parameter "id"
.parameter "image"
.prologue
const/high16 v0, 0x3f80
And change to this:
Code:
.method public constructor <init>(Ljava/lang/String;Landroid/graphics/Bitmap;)V
[COLOR="Red"].locals 2[/COLOR]
.parameter "id"
.parameter "image"
.prologue
const/high16 v0, 0x3f80
[COLOR="Red"]const/4 v1, 0x0[/COLOR]
Look for this line:
Code:
.line 54
invoke-virtual {p0, p2}, Lcom/sonymobile/systemui/uicomponents/Image;->setBitmap(Landroid/graphics/Bitmap;)V
Change the entire line to this:
Code:
.line 54
[COLOR="red"]invoke-virtual {p0, p2, v1}, Lcom/sonymobile/systemui/uicomponents/Image;->setBitmap(Landroid/graphics/Bitmap;Z)V[/COLOR]
Find this line:
Code:
.method public onDraw(Landroid/graphics/Canvas;FF)V
.locals 3
.parameter "canvas"
.parameter "x"
.parameter "y"
.prologue
const/high16 v1, 0x3f80
And change to this:
Code:
.method public onDraw(Landroid/graphics/Canvas;FF)V
[COLOR="red"].locals 5[/COLOR]
.parameter "canvas"
.parameter "x"
.parameter "y"
.prologue
const/high16 v1, 0x3f80
Look for this line:
Code:
.line 181
iget-object v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
if-eqz v0, :cond_1
...
Code:
.line 181
iget-object v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
if-eqz v0, [COLOR="red"]:cond_2[/COLOR]
Look for this code:
Code:
.line 182
iget v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mScalingX:F
cmpl-float v0, v0, v1
if-nez v0, :cond_0
iget v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mScalingY:F
cmpl-float v0, v0, v1
if-eqz v0, :cond_2
Change to this:
Code:
.line 182
iget v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mScalingX:F
cmpl-float v0, v0, v1
if-nez v0, :cond_0
iget v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mScalingY:F
cmpl-float v0, v0, v1
if-eqz v0, [COLOR="Red"]:cond_3[/COLOR]
Look this line:
Code:
.line 185
iget-object v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
iget-object v1, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mMatrix:Landroid/graphics/Matrix;
iget-object v2, p0, Lcom/sonymobile/systemui/uicomponents/Component;->mPaint:Landroid/graphics/Paint;
Add red line below:
Code:
.line 185
iget-object v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
iget-object v1, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mMatrix:Landroid/graphics/Matrix;
iget-object v2, p0, Lcom/sonymobile/systemui/uicomponents/Component;->mPaint:Landroid/graphics/Paint;
[COLOR="red"]iget-boolean v4, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mApplyFilter:Z
const/4 v3, 0x0
if-eqz v4, :cond_1
invoke-static {}, Lcom/sonymobile/systemui/statusbar/tools/ThemeUtils;->getAccentColorFilter()Landroid/graphics/ColorFilter;
move-result-object v3
:cond_1
invoke-virtual {v2, v3}, Landroid/graphics/Paint;->setColorFilter(Landroid/graphics/ColorFilter;)Landroid/graphics/ColorFilter;[/COLOR]
invoke-virtual {p1, v0, v1, v2}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;Landroid/graphics/Matrix;Landroid/graphics/Paint;)V
Now look for this line:
Code:
.line 190
:cond_1
:goto_0
return-void
And change to this value:
Code:
.line 190
[COLOR="Red"]:cond_2[/COLOR]
:goto_0
return-void
Look for following line:
Code:
.line 187
:cond_2
iget-object v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
iget-object v1, p0, Lcom/sonymobile/systemui/uicomponents/Component;->mPaint:Landroid/graphics/Paint;
invoke-virtual {p1, v0, p2, p3, v1}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;FFLandroid/graphics/Paint;)V
And change to this value/add red line:
Code:
.line 187
[COLOR="red"]:cond_3[/COLOR]
iget-object v0, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
iget-object v1, p0, Lcom/sonymobile/systemui/uicomponents/Component;->mPaint:Landroid/graphics/Paint;
[COLOR="red"]iget-boolean v4, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mApplyFilter:Z
const/4 v3, 0x0
if-eqz v4, :cond_4
invoke-static {}, Lcom/sonymobile/systemui/statusbar/tools/ThemeUtils;->getAccentColorFilter()Landroid/graphics/ColorFilter;
move-result-object v3
:cond_4
invoke-virtual {v1, v3}, Landroid/graphics/Paint;->setColorFilter(Landroid/graphics/ColorFilter;)Landroid/graphics/ColorFilter;[/COLOR]
invoke-virtual {p1, v0, p2, p3, v1}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;FFLandroid/graphics/Paint;)V
Look this line:
Code:
.method public setBitmap(Landroid/graphics/Bitmap;Z)V
.locals 2
.parameter "bitmap"
.prologue
const/4 v1, 0x0
And ...
Code:
.method public setBitmap(Landroid/graphics/Bitmap;Z)V
.locals 2
.parameter "bitmap"
[COLOR="red"].parameter "filter"[/COLOR]
.prologue
const/4 v1, 0x0
And LAST one
Code:
.line 73
:cond_0
:goto_0
iput-object p1, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
And... you know what I mean, right?
Code:
.line 73
:cond_0
:goto_0
iput-object p1, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mBitmap:Landroid/graphics/Bitmap;
[COLOR="red"]iput-boolean p2, p0, Lcom/sonymobile/systemui/uicomponents/Image;->mApplyFilter:Z[/COLOR]
erorcun is here said:
You are missing 2 thing. In older versions statusbar clock and expanded clocks' ids are same, so it will not work on normal systemui and you should add 0 to setbitmap's last parameters in ninepatchimage.smali.
Click to expand...
Click to collapse
Remember!
The png you want to colorize must be in white color.
This may take more than two hour. So, patient is require for this.
Good luck
End for now. Will post again if I find something useful.
nice done bro, can you make style 2 also without percentage in statusbar and there is no clock in status bar is that right?
Pandemic said:
nice done bro, can you make style 2 also without percentage in statusbar and there is no clock in status bar is that right?
Click to expand...
Click to collapse
I know you will request something like this.
No clock, no percentage and black background on statusbar.
ZN6 said:
I know you will request something like this.
btw here. No clock and percentage on statusbar.
Click to expand...
Click to collapse
thanks bro
yes i pressed it
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Plz can u send me step by step installation process??
As a beginer i need ur help..,it would b very thankfull:thumbup:
Sent from my ST25i using xda app-developers app
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
shourya jain said:
Plz can u send me step by step installation process??
As a beginer i need ur help..,it would b very thankfull:thumbup:
Sent from my ST25i using xda app-developers app
Click to expand...
Click to collapse
First, download any file that you like.
Put it in your sdcard. Reboot your phone into recovery. Select file you have put in your sdcard. Wait...and reboot your phone.
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.
screen shot?
support small apps?
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Now what really happend is that all my status bar is gone n i m unable to set any wallpaper n my home button is also nt working
Sent from my ST25i using xda app-developers app
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
silverbios said:
screen shot?
Click to expand...
Click to collapse
You didnt see the screenshot on the first post?
shourya jain said:
Now what really happend is that all my status bar is gone n i m unable to set any wallpaper n my home button is also nt working
Sent from my ST25i using xda app-developers app
Click to expand...
Click to collapse
What syatemui mod that you are using before?
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.
not work on my sola!!
try to fix it
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
What to do plz help
Sent from my ST25i using xda app-developers app
shourya jain said:
What to do plz help
Sent from my ST25i using xda app-developers app
Click to expand...
Click to collapse
dude please read what he ask to you :/
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
No system mod..just stock ics rom
Sent from my ST25i using xda app-developers app
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
You post xperia 2011???
Gửi từ ST18i của tôi bằng cách sử dụng Tapatalk 2
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
There's a big chance to not working if you use tab systemui with preferences.
Here try this.
Delete systemui.apk and systemuipreferences.apk. After that reboot your phone. You will lost statusbar. Reboot you phone again and flash my systemui. If still doesnt work...flash on clean stock rom.
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.
support small apps?
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
anhmat122 said:
You post xperia 2011???
Gửi từ ST18i của tôi bằng cách sử dụng Tapatalk 2
Click to expand...
Click to collapse
And it not working on xperia 2011 phone.
Will try to make one if I have a time.
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.
anhmat122 said:
You post xperia 2011???
Gửi từ ST18i của tôi bằng cách sử dụng Tapatalk 2
Click to expand...
Click to collapse
dont i understand me you??
i dont get you thats why i talk like this and what thread is this no 2011, but 2012 !!
Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Delete systemui.apk and and systemuiprefernces.apk fom system/app?? If yes i'll delete it right now... And then rebot it again and install the zip u uploaded..right?
Sent from my ST25i using xda app-developers app

[MOD] [GUIDE] AOSP lock screen with toggle

How to enable AOSP lockscreen for the S4​
As always, for reasons of keeping things simple I use my Rom Control file to house all my MOD settings. Its easier to add and remove code and never changes with updates.
We will be working with three files:
SecSettings
framework-res
android.policy
We will begin with SecSettings
Navigate to res/values/strings and add the following:
Code:
<string name="lockscreen_title">Enable AOSP lockscreen</string>
<string name="lockscreen_summary">Choose AOSP or TW lockscreen</string>
Navigate to res/xml/rom_settings (or your xml of choice) and add the following:
Code:
<CheckBoxPreference android:title="@string/lockscreen_title" android:key="aosp_lock_enabled" android:summary="@string/lockscreen_summary" />
Navigate to smali/com/android/settings/didact/RomSettings.smali (or your settings smali of choice) and add the following:
The first lines just describe what method to add the code to. Dont copy them into the file.
Code:
.field mAospLock:Landroid/preference/CheckBoxPreference;
Code:
[B]In .method public onCreate(Landroid/os/Bundle;)V.....[/B]
:goto_4
invoke-virtual {v4, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
const-string v1, "aosp_lock_enabled"
invoke-virtual {p0, v1}, Lcom/android/settings/didact/RomSettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v1
check-cast v1, Landroid/preference/CheckBoxPreference;
iput-object v1, p0, Lcom/android/settings/didact/RomSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
iget-object v4, p0, Lcom/android/settings/didact/RomSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/didact/RomSettings;->getActivity()Landroid/app/Activity;
move-result-object v1
invoke-virtual {v1}, Landroid/app/Activity;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const-string v5, "aosp_lock_enabled"
invoke-static {v1, v5, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v1
if-ne v1, v2, :cond_5
move v1, v2
:goto_5
invoke-virtual {v4, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
Code:
[B]in .method public onPreferenceTreeClick(Landroid/preference/PreferenceScreen;Landroid/preference/Preference;)Z[/B]
:cond_9
invoke-static {v2, v3, v0}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_0
:cond_a
iget-object v2, p0, Lcom/android/settings/didact/RomSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
if-ne p2, v2, :cond_1
invoke-virtual {p0}, Lcom/android/settings/didact/RomSettings;->getActivity()Landroid/app/Activity;
move-result-object v2
invoke-virtual {v2}, Landroid/app/Activity;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v2
const-string v3, "aosp_lock_enabled"
check-cast p2, Landroid/preference/CheckBoxPreference;
invoke-virtual {p2}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v4
if-eqz v4, :cond_b
move v0, v1
:cond_b
invoke-static {v2, v3, v0}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_0
.end method
Thats it for SecSettings. Again, you may wish to add these mods to lockscreen settings ot your own xml control. If you want to add them to lockscreen settings, have a look at my guide for the S3, it goes into how to do that. Now on to Framework-res in the next section......
AOSP Lockscreen with toggle, part 2.....framework-res​​
In this file we will be doing two things:
Centering the glowpad in your screen
adding lock targets with camera (stock only adds unlock).
Navigate to res/layout/keyguard_selector_view.xml and replace the whole file with the following:
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.internal.policy.impl.keyguard.KeyguardSelectorView android:orientation="vertical" android:id="@id/keyguard_selector_view" android:clipChildren="false" android:clipToPadding="false" android:layout_width="fill_parent" android:layout_height="fill_parent" android:contentDescription="@string/keyguard_accessibility_slide_unlock" android:layout_maxHeight="@dimen/keyguard_security_height" android:layout_maxWidth="420.0dip"
xmlns:prvandroid="http://schemas.android.com/apk/prv/res/android"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:gravity="center" android:layout_gravity="center" android:clipChildren="false" android:clipToPadding="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<include android:layout_width="fill_parent" android:layout_height="wrap_content" layout="@layout/keyguard_message_area" />
<View android:id="@id/keyguard_selector_view_frame" android:background="@drawable/kg_bouncer_bg_white" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginLeft="16.0dip" android:layout_marginRight="16.0dip" />
<include layout="@layout/keyguard_glow_pad_container" />
<include android:layout_gravity="bottom|center" android:id="@id/keyguard_selector_fade_container" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="0.0dip" layout="@layout/keyguard_eca" />
</FrameLayout>
</com.android.internal.policy.impl.keyguard.KeyguardSelectorView>
Navigate to res/layout/keyguard_glow_pad_view.xml and replace the entire file with the following:
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.internal.widget.multiwaveview.GlowPadView android:gravity="center" android:layout_gravity="center" android:orientation="horizontal" android:id="@id/glow_pad_view" android:layout_width="wrap_content" android:layout_height="wrap_content" prvandroid:innerRadius="@dimen/glowpadview_inner_radius" android:contentDescription="@string/keyguard_accessibility_slide_area" prvandroid:targetDescriptions="@array/lockscreen_target_descriptions_with_camera" prvandroid:directionDescriptions="@array/lockscreen_direction_descriptions" prvandroid:outerRingDrawable="@drawable/ic_lockscreen_outerring" prvandroid:pointDrawable="@drawable/ic_lockscreen_glowdot" prvandroid:glowRadius="@dimen/glowpadview_glow_radius" prvandroid:firstItemOffset="@integer/kg_glowpad_rotation_offset" prvandroid:magneticTargets="true" prvandroid:allowScaling="true" prvandroid:targetDrawables="@array/lockscreen_targets_with_camera" prvandroid:handleDrawable="@drawable/ic_lockscreen_handle" prvandroid:outerRadius="@dimen/glowpadview_target_placement_radius" prvandroid:vibrationDuration="20" prvandroid:snapMargin="@dimen/glowpadview_snap_margin" prvandroid:feedbackCount="1"
xmlns:prvandroid="http://schemas.android.com/apk/prv/res/android"
xmlns:android="http://schemas.android.com/apk/res/android" />
Thats it for framework-res. The last section is for android.policy
AOSP Lockscreen with toggle part 3, android.policy​
This last part will add the AOSP functionality with toggle.
Navigate to smali/com/android/internal/policy/impl/keyguard/KeyguardHostView.smali
Add the following:
Code:
.field private mAospLock:I
Find .method private getLayoutIdFor(Lcom/android/internal/policy/impl/keyguard/KeyguardSecurityModel$SecurityModeI
Replace from pswitch_0 to pswitch_1 with the following code:
Code:
:pswitch_0
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mContext:Landroid/content/Context;
invoke-virtual {v2}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v2
const-string v3, "aosp_lock_enabled"
invoke-static {v2, v3, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v2
iput v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mAospLock:I
iget v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mAospLock:I
if-eqz v2, :cond_nocrt
const v1, 0x1090084
goto :goto_1
:cond_nocrt
const v1, 0x1090091
goto :goto_1
:pswitch_1
Thats it. Recompile and push the files to your phone. Enjoy AOSP Lockscreen.
I am currently working to add more functions such as weather and added shortcuts so stay tuned....
Thanks Button!!
Nice!! I assume we would need to add the rom control bits you talk about. Where are they? They are not already there are they?
hlxanthus said:
Nice!! I assume we would need to add the rom control bits you talk about. Where are they? They are not already there are they?
Click to expand...
Click to collapse
No, you don't have to. I just geared this tutorial around the idea that you would. You can add it to any XML you want, just have to follow the flow of the xml you add it to.
Looks cool! Can you post some screenshots?
awesome job like always thanks
xShockz said:
Looks cool! Can you post some screenshots?
Click to expand...
Click to collapse
I will tomorrow, in bed now. Unless someone else has it going and would like to post a pic.
Nice work as always my man.
In order to get the AOSP lock screen working I had to set "Screen lock" to "Swipe" and "Unlock effect" to "None" in Lock screen settings.
Is that how it works or did I screw something up?
upndwn4par said:
Nice work as always my man.
In order to get the AOSP lock screen working I had to set "Screen lock" to "Swipe" and "Unlock effect" to "None" in Lock screen settings.
Is that how it works or did I screw something up?
Click to expand...
Click to collapse
It works for me no matter how I have the unlock effect.
Is this the actual aosp lockscreen or just the similar one that has the fixed unlock shortcuts?
Sent from my SCH-I545 using Tapatalk 4 Beta
andybones said:
It works for me no matter how I have the unlock effect.
Click to expand...
Click to collapse
Hmmmm...maybe I need to go through this again....
Edit:
Works perfect. Just needed to clean up some code.
Is it possible to get this in a zip file?
Sent from my SCH-I545 using xda app-developers app
I am having a it of an issue. I can't find pswitch_0 nor pswitch_1
Can someone direct me? I'm in keyguardhostview.smali
Error I'm getting while recompiling android.policy
Code:
C:\AndroidApktool>android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[3630,7] Label "goto_1" is not defined.
android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[3635,10] Label "goto_1" is not defined.
android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[0,0] mismatched tree node: UP expecting I_CATCHES
android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[3648,4] mismatched tree node: I_STATEMENT_FORMAT21c_STRING expecting <UP>
And here's the code that I have ended.
.method private getLayoutIdFor(Lcom/android/internal/policy/impl/keyguard/KeyguardSecurityModel$SecurityModeI
.registers 6
const/4 v0, 0x1
const/4 v1, 0x0
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mContext:Landroid/content/Context;
invoke-virtual {v2}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v2
const-string v3, "onehand_pattern_enabled"
invoke-static {v2, v3, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v2
if-ne v2, v0, :cond_1c
:goto_10
sget-object v2, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView$21;->$SwitchMap$com$android$internal$policy$impl$keyguard$KeyguardSecurityModel$SecurityMode:[I
invoke-virtual {p1}, Lcom/android/internal/policy/impl/keyguard/KeyguardSecurityModel$SecurityMode;->ordinal()I
move-result v3
aget v2, v2, v3
packed-switch v2, switch_data_90
:goto_1b
return v1
:cond_1c
move v0, v1
goto :goto_10
switch_0
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mContext:Landroid/content/Context;
invoke-virtual {v2}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v2
const-string v3, "aosp_lock_enabled"
invoke-static {v2, v3, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v2
iput v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mAospLock:I
iget v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;->mAospLock:I
if-eqz v2, :cond_nocrt
const v1, 0x1090084
goto :goto_1
:cond_nocrt
const v1, 0x1090091
goto :goto_1
switch_1
switch_1e << this is the first pswitch I see [/b]
Click to expand...
Click to collapse
dscblu said:
Is it possible to get this in a zip file?
Sent from my SCH-I545 using xda app-developers app
Click to expand...
Click to collapse
I second this.
Sent from my SCH-I545 using xda premium
Adrozz07 said:
Is this the actual aosp lockscreen or just the similar one that has the fixed unlock shortcuts?
Sent from my SCH-I545 using Tapatalk 4 Beta
Click to expand...
Click to collapse
Still wondering about this.
Sent from my SCH-I545 using Tapatalk 4 Beta
Hmm i'm on 4.2.2 TW
The outerring become smaller when i set gravity to center, but when i set it to left or right, it become normal.
any idea how to fix it?
Faye Reagan said:
Hmm i'm on 4.2.2 TW
The outerring become smaller when i set gravity to center, but when i set it to left or right, it become normal.
any idea how to fix it?
Click to expand...
Click to collapse
In keyguard_selector_view.xml you can change the size and position of the ring. You just need to play around a little.
upndwn4par said:
In keyguard_selector_view.xml you can change the size and position of the ring. You just need to play around a little.
Click to expand...
Click to collapse
Well i just play around, it's back to normal again after playing with android.policy since play with keyguard_selector_view.xml didn't works
mgbotoe said:
I am having a it of an issue. I can't find pswitch_0 nor pswitch_1
Can someone direct me? I'm in keyguardhostview.smali
Error I'm getting while recompiling android.policy
Code:
C:\AndroidApktool>android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[3630,7] Label "goto_1" is not defined.
android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[3635,10] Label "goto_1" is not defined.
android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[0,0] mismatched tree node: UP expecting I_CATCHES
android.policy\com\android\internal\policy\impl\keyguard\KeyguardHostView.smali[3648,4] mismatched tree node: I_STATEMENT_FORMAT21c_STRING expecting <UP>
And here's the code that I have ended.
Click to expand...
Click to collapse
Did you solve your issue yet? As i am facing exactly the same problem.. :/
Mr.Yawnie said:
Did you solve your issue yet? As i am facing exactly the same problem.. :/
Click to expand...
Click to collapse
naw, i gave up on this a while ago lol
mgbotoe said:
naw, i gave up on this a while ago lol
Click to expand...
Click to collapse
It's so frustrating!! haha. I know your comments were quite a long time ago but i decided to give it a try if you found the issue

[GUIDE]4.2.2 Statusbar for Samsung 4.1.2 ROM with Live Tiles

4.2.2 Style Stausbar for Samsung 4.1.2 ROM​
(This tutorial is originally made for SGSA but it should work with all samsung 4.1.2 ROMs)
Before we begin let me give credit to original author of this mod @SpaceCaker i'm just gonna tell you how to port it to Samsung JB 4.1.2 ROM.
(SpaceCaker's original Thread here)
Note: Throughout the tutorial we'll travel sequentially, i mean when i ask you to search for something and you find more than two matches, then choose the immediate one which comes after previous modification.
So let's begin
- Decompile SystemUI.apk
- Navigate to res/layout
- tw_status_bar.xml
search for
Code:
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:orientation="vertical" android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
Add this below it
Code:
<com.android.systemui.statusbar.StatusBarServiceLRPull android:layout_width="fill_parent" android:layout_height="wrap_content">
- Now search for
Code:
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
Add this above it
Code:
</com.android.systemui.statusbar.StatusBarServiceLRPull>
- Save file
Click to expand...
Click to collapse
- tw_status_bar_expanded.xml
replace
Code:
<FrameLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginBottom="@dimen/tw_close_handle_underlap">
with
Code:
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginBottom="@dimen/close_handle_underlap">
below it there will be <include /> clause add this line below it
Code:
</LinearLayout>
below it there'll be <TextView /> add these lines below it
Code:
<com.spacecaker.SpaceLayOut android:layout_width="fill_parent" android:layout_height="fill_parent">
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content">
<include layout="@layout/quickpanel_quick_settings_space" />
</LinearLayout>
<FrameLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginBottom="@dimen/tw_close_handle_underlap">
- Now search for
Code:
<com.android.systemui.statusbar.phone.CloseDragHandle
and add this code above it
Code:
</com.spacecaker.SpaceLayOut>
- Save file
Click to expand...
Click to collapse
- tw_status_bar_expanded_header.xml
search for
Code:
<RelativeLayout android:id="@id/settings_button" android:background="@drawable/tw_quick_panel_setting_button_bg" android:focusable="true" android:visibility="visible" android:layout_width="@dimen/status_bar_expanded_setting_width" android:layout_height="39.0dip">
replace it with below code
Code:
<RelativeLayout android:id="@id/settings_button" android:background="@drawable/tw_quick_panel_setting_button_bg" android:focusable="true" android:visibility="invisible" android:layout_width="0.100000024dip" android:layout_height="0.100000024dip">
<ImageView android:id="@id/settings_button_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/tw_quickpanel_icon_settings" android:scaleType="center" android:layout_centerHorizontal="true" android:layout_centerVertical="true" android:contentDescription="@string/accessibility_settings_button" />
</RelativeLayout>
<RelativeLayout android:background="@drawable/tw_quick_panel_setting_button_bg" android:focusable="true" android:visibility="visible" android:layout_width="@dimen/status_bar_expanded_setting_width" android:layout_height="39.0dip">
- Search below for
Code:
android:contentDescription="@string/accessibility_settings_button"
and add this above it
Code:
android:onClick="mOpenSettings"
- Below after </RelativeLayout> add this code
Code:
<com.spacecaker.ButtonBurst android:id="@id/spacebuttonburst" android:layout_width="31.0dip" android:layout_height="34.0dip" android:scaleType="center" />
- Save file.
Click to expand...
Click to collapse
- Navigate to /res/values and add these lines to ids.xml
Code:
<item type="id" name="spaceybeaneyheader">false</item>
<item type="id" name="jbclock">false</item>
<item type="id" name="spacebuttonburst">false</item>
<item type="id" name="recent_app_button">false</item>
Click to expand...
Click to collapse
- Add these lines to end of the file Styles.xml
Code:
<style name="S3.Clear" parent="@*android:style/Widget.Button">
<item name="android:textAppearance">?android:textAppearanceSmallInverse</item>
<item name="android:textColor">#ffffffff</item>
<item name="android:gravity">center</item>
<item name="android:background">@drawable/tw_btn_default_small</item>
<item name="android:focusable">true</item>
<item name="android:clickable">true</item>
</style>
- Save files
Click to expand...
Click to collapse
- Download attached files and extract them in the directory where apk is decompiled.Now compile and again decompile APK.
Click to expand...
Click to collapse
- Go to /res/values/public.xml and search these
Code:
<public type="drawable" name="btn_tg"
<public type="drawable" name="btn_toggles_normal"
- Open smali/com/spacecaker/ButtonBurst.smali and search this
Code:
const v3, 0x7f020180
replace red part with id you got from
Code:
<public type="drawable" name="btn_toggles_normal"
- Now find this
Code:
const v3, 0x7f02017f
replace red part with id you got from
Code:
<public type="drawable" name="btn_tg"
Click to expand...
Click to collapse
- Open smali/com/android/systemui/SystemUIService.smali and add this to end of file
Code:
.method public mOpenSettings(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.settings"
const-string v2, "com.android.settings.Settings"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public ProfileButton(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.contacts"
const-string v2, "com.android.contacts.activities.PeopleActivity"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public camera_tile(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.sec.android.app.camera"
const-string v2, "com.sec.android.app.camera.Camera"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public turn_off_light(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "turn.off.the.lights"
const-string v2, "turn.off.the.lights.LockerActivity"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public torch_toggle(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.teslacoilsw.flashlight"
const-string v2, "com.teslacoilsw.flashlight.TeslaLEDToggle"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public dormant_toggle(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.settings"
const-string v2, "com.android.settings.dormantmode.DormantmodeSettings"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public tether_toggle(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.settings"
const-string v2, "com.android.settings.TetherSettings"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public app_toggle(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.settings"
const-string v2, "com.android.settings.RunningServices"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public bat_toggle(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.settings"
const-string v2, "com.android.settings.fuelgauge.PowerUsageSummary"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
.method public SpaceCakerButton(Landroid/view/View;)V
.locals 3
.parameter "v"
.prologue
.line 2431
new-instance v0, Landroid/content/Intent;
invoke-direct {v0}, Landroid/content/Intent;-><init>()V
.line 2432
const-string v1, "com.android.settings"
const-string v2, "com.android.settings.Settings"
invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->setClassName(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
const/high16 v2, 0x1000
invoke-virtual {v0, v2}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;
move-result-object v0
.line 2433
invoke-virtual {p0, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
const-string v1, "statusbar"
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/app/StatusBarManager;
invoke-virtual {v0}, Landroid/app/StatusBarManager;->collapse()V
.line 1720
return-void
.end method
Click to expand...
Click to collapse
That's all compile apk and push it to device.
(Torch and Sleep tiles won't work unless you install TeslaLED and Turn Off the Lights app from market)
You can refer to SpaceCaker's thread for more info and tutorial for how to add new tiles.
If you get any errors/FCs report here along with full log.
(i won't quote posts without logcat and ask for logcat, i'll simply ignore them)
How to add Live Tiles
So now you've setup layout for 4.2 statusbar.Now its time to add some live tiles here.
What you'll get
At the moment i've only created live tiles for Battery and WiFi (those are the only ones which are fairly noticeable and widely used).Live tile for battery shows battery level and WiFi tile shows AP name and signal level when connected.See below screenshot for more info.
(More tiles will be added later when i'll get some time)
So let's begin
- Add thses lines to res/values/ids.xml
Code:
<item type="id" name="harsh_batt">false</item>
<item type="id" name="harsh_wifi">false</item>
<item type="id" name="harsh_bat_img">false</item>
<item type="id" name="harsh_wifi_img">false</item>
Click to expand...
Click to collapse
- Now open \res\layout\quickpanel_quick_settings_space.xml
- Every tile here is wrapped up within <FrameLayout></FrameLayout>.So now select one of frameLayout which will be your battery tile.This framelayout will include one ImageView (for indication of battery tile) and one TextView (for showing battery in %).Create them if you haven't.
- Now remove
Code:
android:src="@drawable/set"
or whatever drawable you've associated to that ImageView.
- Add
Code:
android:id="@id/harsh_bat_img"
for same ImageView.
- We'll do the same for TextView.Remove
Code:
android:text="Battery"
and add
Code:
android:id="@id/harsh_batt"
for that TextView.
- Now let's do the same for WiFi tile.Select FrameLayout for that tile and do following changes for that FrameLayout
- Remove
Code:
android:src="@drawable/set"
for the <ImageView> and add
Code:
android:id="@id/harsh_wifi_img"
- Now for <TextView>, remove
Code:
android:text="xxx"
and add
Code:
android:id="@id/harsh_wifi"
- Thats all.Save the files.
Click to expand...
Click to collapse
- Download the attached file and extract it to decompiled directory.
- Compile APK and decompiled it back so that public ids get generated.
- Now keep you res/values/public.xml open.
Click to expand...
Click to collapse
- Open smali\com\spacecaker\SpaceLayOut.smali
- Add
Code:
.field draw:Landroid/graphics/drawable/Drawable;
.field iv:Landroid/widget/ImageView;
before .field private mContext:Landroid/content/Context;
- Add
Code:
.field res:Landroid/content/res/Resources;
.field t:Landroid/widget/TextView;
.field userName:Ljava/lang/String;
after .field private mUpdating:Z
- Now search for .method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSetV and add following lines before return-void
Code:
invoke-virtual {p0}, Lcom/spacecaker/SpaceLayOut;->getResources()Landroid/content/res/Resources;
move-result-object v0
iput-object v0, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
- search for .method private update(Z)V and add this below .line 46 (i.e. at the starting of the method)
Code:
invoke-virtual {p0}, Lcom/spacecaker/SpaceLayOut;->getBatteryState()V
.line 256
invoke-virtual {p0}, Lcom/spacecaker/SpaceLayOut;->getWifiInfo()V
- Now add the following lines after # virtual methods.
Code:
.method public getBatteryState()V
.locals 13
.prologue
.line 31
const v10, 0x7f0d012c
invoke-virtual {p0, v10}, Lcom/spacecaker/SpaceLayOut;->findViewById(I)Landroid/view/View;
move-result-object v10
check-cast v10, Landroid/widget/TextView;
iput-object v10, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
.line 32
const v10, 0x7f0d012e
invoke-virtual {p0, v10}, Lcom/spacecaker/SpaceLayOut;->findViewById(I)Landroid/view/View;
move-result-object v10
check-cast v10, Landroid/widget/ImageView;
iput-object v10, p0, Lcom/spacecaker/SpaceLayOut;->iv:Landroid/widget/ImageView;
.line 33
new-instance v3, Landroid/content/IntentFilter;
const-string v10, "android.intent.action.BATTERY_CHANGED"
invoke-direct {v3, v10}, Landroid/content/IntentFilter;-><init>(Ljava/lang/String;)V
.line 34
.local v3, ifilter:Landroid/content/IntentFilter;
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->mContext:Landroid/content/Context;
const/4 v11, 0x0
invoke-virtual {v10, v11, v3}, Landroid/content/Context;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
move-result-object v1
.line 35
.local v1, batteryStatus:Landroid/content/Intent;
const-string v10, "level"
const/4 v11, -0x1
invoke-virtual {v1, v10, v11}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
move-result v5
.line 36
.local v5, level:I
const-string v10, "scale"
const/4 v11, -0x1
invoke-virtual {v1, v10, v11}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
move-result v7
.line 37
.local v7, scale:I
const-string v10, "status"
const/4 v11, -0x1
invoke-virtual {v1, v10, v11}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
move-result v8
.line 38
.local v8, status:I
const/4 v10, 0x2
if-eq v8, v10, :cond_0
const/4 v10, 0x5
if-eq v8, v10, :cond_0
const/4 v4, 0x0
.line 39
.local v4, isCharging:Z
:goto_0
const-string v10, "plugged"
const/4 v11, -0x1
invoke-virtual {v1, v10, v11}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I
move-result v2
.line 40
.local v2, chargePlug:I
const/4 v10, 0x2
if-ne v2, v10, :cond_1
const/4 v9, 0x1
.line 41
.local v9, usbCharge:Z
:goto_1
int-to-float v10, v5
int-to-float v11, v7
div-float v6, v10, v11
.line 42
.local v6, net_battery:F
const/high16 v10, 0x42c8
mul-float/2addr v10, v6
invoke-static {v10}, Ljava/lang/Math;->round(F)I
move-result v0
.line 43
.local v0, batteryPct:I
if-eqz v4, :cond_3
.line 44
if-eqz v9, :cond_2
.line 45
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
new-instance v11, Ljava/lang/StringBuilder;
invoke-static {v0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;
move-result-object v12
invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
const-string v12, "%"
invoke-virtual {v11, v12}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v11
const-string v12, " (USB)"
invoke-virtual {v11, v12}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v11
invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v11
invoke-virtual {v10, v11}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 52
:goto_2
:try_start_0
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
iget-object v11, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
const v12, 0x7f0202ff
invoke-virtual {v11, v12}, Landroid/content/res/Resources;->getXml(I)Landroid/content/res/XmlResourceParser;
move-result-object v11
invoke-static {v10, v11}, Landroid/graphics/drawable/Drawable;->createFromXml(Landroid/content/res/Resources;Lorg/xmlpull/v1/XmlPullParser;)Landroid/graphics/drawable/Drawable;
move-result-object v10
iput-object v10, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
:try_end_0
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0
.line 55
:goto_3
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
invoke-virtual {v10, v0}, Landroid/graphics/drawable/Drawable;->setLevel(I)Z
.line 56
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->iv:Landroid/widget/ImageView;
iget-object v11, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
invoke-virtual {v10, v11}, Landroid/widget/ImageView;->setBackground(Landroid/graphics/drawable/Drawable;)V
.line 57
return-void
.line 38
.end local v0 #batteryPct:I
.end local v2 #chargePlug:I
.end local v4 #isCharging:Z
.end local v6 #net_battery:F
.end local v9 #usbCharge:Z
:cond_0
const/4 v4, 0x1
goto :goto_0
.line 40
.restart local v2 #chargePlug:I
.restart local v4 #isCharging:Z
:cond_1
const/4 v9, 0x0
goto :goto_1
.line 47
.restart local v0 #batteryPct:I
.restart local v6 #net_battery:F
.restart local v9 #usbCharge:Z
:cond_2
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
new-instance v11, Ljava/lang/StringBuilder;
invoke-static {v0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;
move-result-object v12
invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
const-string v12, "%"
invoke-virtual {v11, v12}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v11
const-string v12, " (AC)"
invoke-virtual {v11, v12}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v11
invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v11
invoke-virtual {v10, v11}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
goto :goto_2
.line 49
:cond_3
iget-object v10, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
new-instance v11, Ljava/lang/StringBuilder;
invoke-static {v0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;
move-result-object v12
invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
const-string v12, "%"
invoke-virtual {v11, v12}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v11
invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v11
invoke-virtual {v10, v11}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
goto :goto_2
.line 53
:catch_0
move-exception v10
goto :goto_3
.end method
.method public getWifiInfo()V
.locals 7
.prologue
.line 59
const v4, 0x7f0d012d
invoke-virtual {p0, v4}, Lcom/spacecaker/SpaceLayOut;->findViewById(I)Landroid/view/View;
move-result-object v4
check-cast v4, Landroid/widget/TextView;
iput-object v4, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
.line 60
const v4, 0x7f0d012f
invoke-virtual {p0, v4}, Lcom/spacecaker/SpaceLayOut;->findViewById(I)Landroid/view/View;
move-result-object v4
check-cast v4, Landroid/widget/ImageView;
iput-object v4, p0, Lcom/spacecaker/SpaceLayOut;->iv:Landroid/widget/ImageView;
.line 61
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->mContext:Landroid/content/Context;
const-string v5, "wifi"
invoke-virtual {v4, v5}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v3
check-cast v3, Landroid/net/wifi/WifiManager;
.line 62
.local v3, wm:Landroid/net/wifi/WifiManager;
invoke-virtual {v3}, Landroid/net/wifi/WifiManager;->getWifiState()I
move-result v2
.line 63
.local v2, wifiState:I
packed-switch v2, :pswitch_data_0
.line 86
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
const-string v5, "Error"
invoke-virtual {v4, v5}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 89
:goto_0
return-void
.line 67
:pswitch_0
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
const-string v5, "Wi-Fi"
invoke-virtual {v4, v5}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 69
:try_start_0
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
iget-object v5, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
const v6, 0x7f020322
invoke-virtual {v5, v6}, Landroid/content/res/Resources;->getXml(I)Landroid/content/res/XmlResourceParser;
move-result-object v5
invoke-static {v4, v5}, Landroid/graphics/drawable/Drawable;->createFromXml(Landroid/content/res/Resources;Lorg/xmlpull/v1/XmlPullParser;)Landroid/graphics/drawable/Drawable;
move-result-object v4
iput-object v4, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
:try_end_0
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_1
.line 72
:goto_1
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->iv:Landroid/widget/ImageView;
iget-object v5, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
invoke-virtual {v4, v5}, Landroid/widget/ImageView;->setBackground(Landroid/graphics/drawable/Drawable;)V
goto :goto_0
.line 75
:pswitch_1
invoke-virtual {v3}, Landroid/net/wifi/WifiManager;->getConnectionInfo()Landroid/net/wifi/WifiInfo;
move-result-object v1
.line 76
.local v1, wifiInfo:Landroid/net/wifi/WifiInfo;
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->t:Landroid/widget/TextView;
invoke-virtual {v1}, Landroid/net/wifi/WifiInfo;->getSSID()Ljava/lang/String;
move-result-object v5
invoke-virtual {v4, v5}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 77
invoke-virtual {v1}, Landroid/net/wifi/WifiInfo;->getRssi()I
move-result v4
const/4 v5, 0x5
invoke-static {v4, v5}, Landroid/net/wifi/WifiManager;->calculateSignalLevel(II)I
move-result v0
.line 79
.local v0, signalLevel:I
:try_start_1
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
iget-object v5, p0, Lcom/spacecaker/SpaceLayOut;->res:Landroid/content/res/Resources;
const v6, 0x7f020300
invoke-virtual {v5, v6}, Landroid/content/res/Resources;->getXml(I)Landroid/content/res/XmlResourceParser;
move-result-object v5
invoke-static {v4, v5}, Landroid/graphics/drawable/Drawable;->createFromXml(Landroid/content/res/Resources;Lorg/xmlpull/v1/XmlPullParser;)Landroid/graphics/drawable/Drawable;
move-result-object v4
iput-object v4, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
:try_end_1
.catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_0
.line 82
:goto_2
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
invoke-virtual {v4, v0}, Landroid/graphics/drawable/Drawable;->setLevel(I)Z
.line 83
iget-object v4, p0, Lcom/spacecaker/SpaceLayOut;->iv:Landroid/widget/ImageView;
iget-object v5, p0, Lcom/spacecaker/SpaceLayOut;->draw:Landroid/graphics/drawable/Drawable;
invoke-virtual {v4, v5}, Landroid/widget/ImageView;->setBackground(Landroid/graphics/drawable/Drawable;)V
goto :goto_0
.line 80
:catch_0
move-exception v4
goto :goto_2
.line 70
.end local v0 #signalLevel:I
.end local v1 #wifiInfo:Landroid/net/wifi/WifiInfo;
:catch_1
move-exception v4
goto :goto_1
.line 63
nop
:pswitch_data_0
.packed-switch 0x0
:pswitch_0
:pswitch_0
:pswitch_0
:pswitch_1
.end packed-switch
.end method
Click to expand...
Click to collapse
- Search for
Code:
const v15, 0x7f0d012c
change public id which you get from
Code:
<public type="id" name="harsh_batt"
in public.xml
- Search for
Code:
const v15, 0x7f0d012e
change public id which you get from
Code:
<public type="id" name="harsh_bat_img"
- Search for
Code:
const v15, 0x7f0202ff
change public id which you get from
Code:
<public type="drawable" name="harsh_stat_battery"
- Search for
Code:
const v8, 0x7f0d012d
change public id which you get from
Code:
<public type="id" name="harsh_wifi"
- Search for
Code:
const v8, 0x7f0d012f
change public id which you get from
Code:
<public type="id" name="harsh_wifi_img"
- Search for
Code:
const v8, 0x7f020322
change public id which you get from
Code:
<public type="drawable" name="wifi_tile"
- Search for
Code:
const v8, 0x7f020300
change public id which you get from
Code:
<public type="drawable" name="harsh_stat_wifi"
Click to expand...
Click to collapse
- Thats it.Now save your file and compile APK and push it to device.
Tips,Tricks & FAQs
Changelog:
13/12/13 --> Initial Release
27/12/13 --> Optimized code.Reduced lags when live tiles are implemented.Live tiles will update only when statusbar is pulled down.
Tips, Tricks & FAQs:
If battery indicator or any other image don't look in center, define paddings like android:layout_marginTop="30.0dip"
If you've added more than 3 rows, then you need to enclose it in <ScrollView> in order to make it scrollable.
Even though i've named them Live tiles, they're not actually live like original 4.2.2 statusbar. They'll update only when tile layout is drawn (i mean expanded).But this has one advantage that addition overhead to system is gone.
Associate android: onClick="foobar" attribute to FrameLayout instead of ImageView so that clicking anywhere on the tile can execute defined method.
Each <LinearLayout> shows one row which have 3 FrameLayout by default.If you'll add/remove FrameLayout then width of tiles will be set accordingly.
screenshot will be? I would like to see the final result
Status bar disappeared. What to do? Galaxy ace 2 android 4.1.2
ildar2099 said:
Status bar disappeared. What to do? Galaxy ace 2 android 4.1.2
Click to expand...
Click to collapse
First...read the OP. Especially the underlined line at the bottom
Nice guide btw
Sent from my GT-I9305 using Tapatalk
Code:
pkTools152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_july' has no default translation in C:\ApkT
ools152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_june' has no default translation in C:\ApkT
ools152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_march' has no default translation in C:\Apk
Tools152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_may' has no default translation in C:\ApkTo
ols152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_november' has no default translation in C:\
ApkTools152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_october' has no default translation in C:\A
pkTools152\SystemUI\res; found: mk
aapt: warning: string 'month_shortest_september' has no default translation in C:
\ApkTools152\SystemUI\res; found: mk
aapt: warning: string 'no_such_item' has no default translation in C:\ApkTools152
\SystemUI\res; found: bg cs da de el en_US es_ES es_US et fi fr ga hr hu is it kk
ko lt lv mk nb nl pl pt_PT ro ru sk sl sr sv tr uk
aapt: warning: string 'pm' has no default translation in C:\ApkTools152\SystemUI\
res; found: mk
aapt: warning: string 'quickpanel_data_roaming_disable_toast' has no default tran
slation in C:\ApkTools152\SystemUI\res; found: bg cs da de el en_US es_ES es_US e
t fi fr ga hr hu is it kk ko lt lv mk nb nl pl pt_PT ro ru sk sl sr sv tr uk
aapt: warning: string 'quickpanel_data_roaming_enable_toast' has no default trans
lation in C:\ApkTools152\SystemUI\res; found: bg cs da de el en_US es_ES es_US et
fi fr ga hr hu is it kk ko lt lv mk nb nl pl pt_PT ro ru sk sl sr sv tr uk
aapt: warning: string 'today' has no default translation in C:\ApkTools152\System
UI\res; found: mk
aapt: warning: string 'tomorrow' has no default translation in C:\ApkTools152\Sys
temUI\res; found: mk
aapt: warning: string 'twelve_hour_time_format' has no default translation in C:\
ApkTools152\SystemUI\res; found: mk
aapt: warning: string 'yesterday' has no default translation in C:\ApkTools152\Sy
stemUI\res; found: mk
I: Building apk file...
SystemUI - complete
All done!
My original SystemUI.apk
They're just apktool warnings. You need a logcat of the system ui fc not the compile log
Sent from my GT-I9305 using Tapatalk
Goldie said:
They're just apktool warnings. You need a logcat of the system ui fc not the compile log
Sent from my GT-I9305 using Tapatalk
Click to expand...
Click to collapse
where to find it?
ildar2099 said:
where to find it?
Click to expand...
Click to collapse
You should have a dumpstate_app_error.txt.gz in data/log. If not then you need to google how to take a logcat
Sent from my GT-I9305 using Tapatalk
Goldie said:
You should have a dumpstate_app_error.txt.gz in data/log. If not then you need to google how to take a logcat
Sent from my GT-I9305 using Tapatalk
Click to expand...
Click to collapse
can be more?
Sent from my GT-I8160 using xda app-developers app
Great tutorial, I would like to try this on Note but one question , is the zip file same for xhdpi phones?
nice tutorial thank you..
tommorow i will try it :good:
just awesome. Thank you for all Mr.Harsh
got it working, but there's 1 problem, when not charging, there's no icons in the statusbar, and i can only use the last used dropdown.
when it is charging, i can use both (left and right) and the statusbar looks normal. any idea what that could be? i'll upload the logcat later, unless you know what this problem is.
-edit- it seems that the statusbar and mod work like expected when in the lockscreen, and when there is a notification (when charging over usb there is a notification, so that's why it also works the way it should when charging, it also doesn't work when charging normally). because of this i can't upload a logcat, cause when using my pc (via usb) the statusbar works normally, and when using terminal emulator there is a notification, so then it also works normally.
---------- Post added at 11:47 PM ---------- Previous post was at 11:05 PM ----------
nevermind, i disabled the clock with some xml editing, and apparently that causes the disappearing of the icons and the functionality of the left/right pull.
so for anybody that for some reason removed the clock, it causes this bug (maybe it isn't a bug, i don't know yet) to happen.
ildar2099 said:
My original SystemUI.apk
Click to expand...
Click to collapse
Yep, as Goldie told they're just warnings, if statusbar has disappeared then you must have done something wrong.Post logcat here.
(Here is a tut about how to take logcat: http://forum.xda-developers.com/showthread.php?t=2303834 )
kmokhtar79 said:
Great tutorial, I would like to try this on Note but one question , is the zip file same for xhdpi phones?
Click to expand...
Click to collapse
You'll need to replace icons in drawable-hdpi folder else they'll look too small.But if you're gonna test it then try with those icons then you'll just need to replace those icons by better icons.
mjz2cool said:
got it working, but there's 1 problem, when not charging, there's no icons in the statusbar, and i can only use the last used dropdown.
when it is charging, i can use both (left and right) and the statusbar looks normal. any idea what that could be? i'll upload the logcat later, unless you know what this problem is.
-edit- it seems that the statusbar and mod work like expected when in the lockscreen, and when there is a notification (when charging over usb there is a notification, so that's why it also works the way it should when charging, it also doesn't work when charging normally). because of this i can't upload a logcat, cause when using my pc (via usb) the statusbar works normally, and when using terminal emulator there is a notification, so then it also works normally.
---------- Post added at 11:47 PM ---------- Previous post was at 11:05 PM ----------
nevermind, i disabled the clock with some xml editing, and apparently that causes the disappearing of the icons and the functionality of the left/right pull.
so for anybody that for some reason removed the clock, it causes this bug (maybe it isn't a bug, i don't know yet) to happen.
Click to expand...
Click to collapse
Have you modified statusbar before?
Anyways i'm glad that you got it working..
ildar2099 said:
can be more?
Sent from my GT-I8160 using xda app-developers app
Click to expand...
Click to collapse
http://forum.xda-developers.com/showthread.php?t=2303834
mr.harsh said:
4.2.2 Style Stausbar for Samsung 4.1.2 ROM​
(This tutorial is originally made for SGSA but it should work with all samsung 4.1.2 ROMs)
Before we begin let me give credit to original author of this mod @SpaceCaker i'm just gonna tell you how to port it to Samsung JB 4.1.2 ROM.
(SpaceCaker's original Thread here)
Note: Throughout the tutorial we'll travel sequentially, i mean when i ask you to search for something and you find more than two matches, then choose the immediate one which comes after previous modification.
So let's begin
- Decompile SystemUI.apk
- Navigate to res/layout
That's all compile apk and push it to device.
(Torch and Sleep tiles won't work unless you install TeslaLED and Turn Off the Lights app from market)
You can refer to SpaceCaker's thread for more info and tutorial for how to add new tiles.
If you get any errors/FCs report here along with full log.
Click to expand...
Click to collapse
thanks b4 for your guide:good: but after i try this guide not work for me my systemUI FC i hope you help me.. (sorry for bad my English)
Edit: SOLVED my mistake incorrect one line to edit
is there a way to add actual toggles? i tried using the guides to add lidroid toggles, and then the guide to get them in a grid, but i can't seem to get the lidroid toggles to work.
abdoel_046 said:
thanks b4 for your guide:good: but after i try this guide not work for me my systemUI FC i hope you help me.. (sorry for bad my English)
Click to expand...
Click to collapse
No log = No help
mjz2cool said:
is there a way to add actual toggles? i tried using the guides to add lidroid toggles, and then the guide to get them in a grid, but i can't seem to get the lidroid toggles to work.
Click to expand...
Click to collapse
You need to override methods in such a way that they toggles the state of wifi/bluetooth etc instead of launching activity.I did it but problem was that tiles won't get updated after toggling state.SpaceCaker has made update() method private/ non-static (of course there was reason to do so) so we can't call is after changing state.To make it work in that i'll need to code whole things again but i don't have such time.May be in future i'll do that...
BTW, lidroid toggles are easy to port and arrange them in grid.
mr.harsh said:
No log = No help
You need to override methods in such a way that they toggles the state of wifi/bluetooth etc instead of launching activity.I did it but problem was that tiles won't get updated after toggling state.SpaceCaker has made update() method private/ non-static (of course there was reason to do so) so we can't call is after changing state.To make it work in that i'll need to code whole things again but i don't have such time.May be in future i'll do that...
BTW, lidroid toggles are easy to port and arrange them in grid.
Click to expand...
Click to collapse
already solved.. sorry mr.harsh i wrong edit one line it is make systemUI FC..

Need help with MCU update

So Long story short i have an android 4.1 double din in my car and i briked it. How? There is a setting called
model select and that setting does something to the MCU and when i selected the model (there was only 1) and the unit rebooted all native apps force close. Settings application opens but when i try to factory reset, update software, update MCU, or select model it force closes. I did manage to root the device and install terminal emulator and root explorer. the update files fro the system are encrypted and we dont know of any other way to update the Mcu to another version. So that is why i am here. to see if anyone could help and maybe reverse engineer and figure out how setting aplication updates the MCU.
I did decompile settings apk and found this in /smali/com/android/settings/AutoSettings.smali
PHP:
const-string v1, "mcu_update"
invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, :cond_2
new-instance v0, Landroid/app/AlertDialog$Builder;
invoke-virtual {p0}, Lcom/android/settings/AutoSettings;->getActivity()Landroid/app/Activity;
move-result-object v1
invoke-direct {v0, v1}, Landroid/app/AlertDialog$Builder;-><init>(Landroid/content/Context;)V
invoke-virtual {v0, v2}, Landroid/app/AlertDialog$Builder;->setIcon(I)Landroid/app/AlertDialog$Builder;
move-result-object v0
const v1, 0x7f0b068e
invoke-virtual {v0, v1}, Landroid/app/AlertDialog$Builder;->setTitle(I)Landroid/app/AlertDialog$Builder;
move-result-object v0
new-instance v1, Lcom/android/settings/aK;
invoke-direct {v1, p0}, Lcom/android/settings/aK;-><init>(Lcom/android/settings/AutoSettings;)V
invoke-virtual {v0, v3, v1}, Landroid/app/AlertDialog$Builder;->setPositiveButton(ILandroid/content/DialogInterface$OnClickListener;)Landroid/app/AlertDialog$Builder;
move-result-object v0
invoke-virtual {v0, v4, v5}, Landroid/app/AlertDialog$Builder;->setNegativeButton(ILandroid/content/DialogInterface$OnClickListener;)Landroid/app/AlertDialog$Builder;
move-result-object v0
invoke-virtual {v0}, Landroid/app/AlertDialog$Builder;->show()Landroid/app/AlertDialog;
goto :goto_0
:cond_2
invoke-virtual {p2}, Landroid/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v0
in res/values/public.xml i found this: (Note: car update is Model Choose in strings.xml)
PHP:
<public type="string" name="mcu_version" id="0x7f0b067e" />
<public type="string" name="mcu_version_default" id="0x7f0b067f" />
<public type="string" name="mcu_update_title" id="0x7f0b068c" />
<public type="string" name="mcu_update_summary" id="0x7f0b068d" />
<public type="string" name="sure_mcu_update" id="0x7f0b068e" />
<public type="string" name="car_update_title" id="0x7f0b06a4" />
<public type="string" name="car_update_summary" id="0x7f0b06a5" />
<public type="string" name="sure_car_update" id="0x7f0b06a6" />
in smali/com/android/settings/CarActivity.smali i found this
PHP:
.method protected onListItemClick(Landroid/widget/ListView;Landroid/view/View;IJ)V
.locals 3
new-instance v0, Landroid/app/AlertDialog$Builder;
invoke-direct {v0, p0}, Landroid/app/AlertDialog$Builder;-><init>(Landroid/content/Context;)V
const v1, 0x1080027
invoke-virtual {v0, v1}, Landroid/app/AlertDialog$Builder;->setIcon(I)Landroid/app/AlertDialog$Builder;
move-result-object v0
const v1, 0x7f0b06a6
invoke-virtual {v0, v1}, Landroid/app/AlertDialog$Builder;->setTitle(I)Landroid/app/AlertDialog$Builder;
move-result-object v0
const v1, 0x7f0b03d4
new-instance v2, Lcom/android/settings/by;
invoke-direct {v2, p0, p3}, Lcom/android/settings/by;-><init>(Lcom/android/settings/CarActivity;I)V
invoke-virtual {v0, v1, v2}, Landroid/app/AlertDialog$Builder;->setPositiveButton(ILandroid/content/DialogInterface$OnClickListener;)Landroid/app/AlertDialog$Builder;
move-result-object v0
const v1, 0x7f0b03d5
const/4 v2, 0x0
invoke-virtual {v0, v1, v2}, Landroid/app/AlertDialog$Builder;->setNegativeButton(ILandroid/content/DialogInterface$OnClickListener;)Landroid/app/AlertDialog$Builder;
move-result-object v0
invoke-virtual {v0}, Landroid/app/AlertDialog$Builder;->show()Landroid/app/AlertDialog;
return-void
.end method
thats probably as far as i can get since i dont know much and nothing about smali. so if some one could help please do so thanks :fingers-crossed:

Categories

Resources