[MOD/GUIDE] Xperia Jelly Bean Style SystemUI | Customize Your Own Statusbar! [18/3] - Sony Xperia S, Acro S, Ion

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. And delete systemui.odex if it present.
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 this
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.
Credit
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.

very very very nice :good::good::good:

Sv: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Are you skilled in porting apps also?
Sent from my LT26i using xda app-developers app

Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
DenmarkRootN00b said:
Are you skilled in porting apps also?
Sent from my LT26i using xda app-developers app
Click to expand...
Click to collapse
What app you want to port?
Ask erorcun becoz he have more experience in porting app than me.
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.

Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
I'm using stock ics 2.55 rooted
Notification bar is disappeared (
Sent from my LT26i using xda premium

Style_1 not working with Home Launcher Xperia Z V2 port by Thilina C:crying:
http://forum.xda-developers.com/showthread.php?t=2102397
xperia ion

ZN6 said:
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.
Click to expand...
Click to collapse
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.

Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
boncaunhaquynhanh said:
Style_1 not working with Home Launcher Xperia Z V2 port by Thilina C:crying:
http://forum.xda-developers.com/showthread.php?t=2102397
xperia ion
Click to expand...
Click to collapse
This mod has nothing to do with home launcher
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.

Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Thread update. Please follow instruction on the first post. I have fix the systemui didnt appeared by some of people here.
Give your feedback guy.

Sv: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Can I use it with rooted stock 45 or only with 55? Thanks in advance
Sent from my LT26i using Tapatalk2

Works perfectly on my ION 6.1.E.3.7! Possibility of adding quickpanel settings?

farvin said:
Can I use it with rooted stock 45 or only with 55? Thanks in advance
Sent from my LT26i using Tapatalk2
Click to expand...
Click to collapse
Work on any stock ics based.

Sv: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
THX do I need to have a Rom with small app function or would your mod give that function?
Sendt fra min LT26i med Tapatalk2

Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
farvin said:
THX do I need to have a Rom with small app function or would your mod give that function?
Sendt fra min LT26i med Tapatalk2
Click to expand...
Click to collapse
Just search on xda about smallapp mod.
And no, my mod doesnt include smallapp.
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.

Awesome
This SystemUI is awesome!!
Hope you can creat quickpanel or tab setting
sorry for my bad english

Re: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
Great work
Sent from my LT26ii using xda app-developers app

Excellent work. Exactly what i wanted

like your wOOOOOrk dude ... if possible to install with small apps , it's full ok... thnaks bro

Sv: [MOD] Xperia Jelly Bean Style SystemUI [20/2]
ZN6 said:
What app you want to port?
Ask erorcun becoz he have more experience in porting app than me.
Feel free to hit
if this post help you anyway.
Sent from LT22i via Tapatalk.
Click to expand...
Click to collapse
Well we are still looking for phonebook and conversations to be ported... If it is possible
Edit : ported to CM based roms
Sent from my LT26i using xda app-developers app

Related

[MOD][HOW-TO] User Selectable Long Press Menu or Back to Kill

This will allow users to select menu or back to kill apps in real time. No flashing, rebooting, etc.
This will not work with multiwindow.
We're going to be working with the following two files:
SecSettings.apk
android.policy.jar
KEY
REMOVE what's in BLUE
ADD what's in RED
SecSettings.apk
Navigate to /res/values/arrays.xml
Add the following to the end of the file
Code:
<string-array name="long_press_kill_entries">
<item>Back</item>
<item>Menu</item>
</string-array>
<string-array name="long_press_kill_values">
<item>0</item>
<item>1</item>
</string-array>
Navigate to /res/values/strings.xml
Add the following to the end of the file
Code:
<string name="long_press_kill_title">Long Press to Kill Button</string>
<string name="long_press_kill_summary">%s</string>
Navigate to /xml/display_settings.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen android:title="@string/display_settings"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings">
<PreferenceCategory android:title="@string/tts_general_section_title" />
<PreferenceScreen android:title="@string/wallpaper" android:key="wallpaper" android:fragment="com.android.settings.WallpaperSettings" />
<PreferenceScreen android:title="@string/led_indicator_settings" android:key="led_indicator_settings" android:fragment="com.android.settings.LedIndicatorSettings" />
<SwitchPreferenceScreen android:title="@string/page_buddy" android:key="contextualpage_settings" android:summary="@string/page_buddy_summary" android:fragment="com.android.settings.ContextualPageSettings" />
<PreferenceCategory android:title="@string/display_label" android:key="screen_category" />
<PreferenceScreen android:title="@string/screen_mode_setting" android:key="mode" android:summary="@string/screen_mode_summary">
<intent android:targetPackage="com.android.settings" android:action="android.intent.action.MAIN" android:targetClass="com.android.settings.ModePreview" />
</PreferenceScreen>
<com.android.settings.BrightnessPreference android:title="@string/brightness" android:key="brightness" android:widgetLayout="@layout/round_more_icon" android:dialogTitle="@string/brightness" />
<CheckBoxPreference android:title="@string/accelerometer_title_second" android:key="accelerometer_second" />
<CheckBoxPreference android:title="@string/accelerometer_title" android:key="accelerometer" />
<ListPreference android:persistent="false" android:entries="@array/screen_timeout_entries" android:title="@string/screen_timeout" android:key="screen_timeout" android:summary="@string/screen_timeout_summary" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/screen_timeout_values" />
<PreferenceScreen android:title="@string/screensaver_settings_title" android:key="screensaver" android:fragment="com.android.settings.DreamSettings" />
<CheckBoxPreference android:title="@string/brightness_slider_title" android:key="display_brightness_slider" android:summary="@string/brightness_slider_summary" />
<PreferenceCategory android:title="@string/features_category_title" android:key="features_category" />
<CheckBoxPreference android:title="@string/intelligent_rotation_title" android:key="intelligent_rotation" android:summary="@string/intelligent_rotation_summary" />
<CheckBoxPreference android:title="@string/intelligent_sleep_title" android:key="intelligent_sleep" android:summary="@string/intelligent_sleep_summary" />
<PreferenceCategory android:title="@string/font" />
<com.android.settings.flipfont.FontListPreference android:title="@string/monotype_preference_title" android:key="MONOTYPE" android:summary="@string/monotype_preference_summary" android:widgetLayout="@layout/round_more_icon" />
<com.android.settings.FontSizeListPreference android:entries="@array/entries_font_size" android:title="@string/title_font_size" android:key="font_size" android:summary="@string/summary_font_size" android:widgetLayout="@layout/round_more_icon" android:dialogTitle="@string/dialog_title_font_size" android:entryValues="@array/entryvalues_font_size" />
<PreferenceCategory android:title="@string/more_settings" android:key="more_settings" />
<ListPreference android:persistent="false" android:entries="@array/quick_launch_entries" android:title="@string/quick_launch_title" android:key="quick_launch" android:summary="@string/screen_quick_launch_summary" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/quick_launch_values" />
<CheckBoxPreference android:title="@string/sub_lcd_auto_lock" android:key="sub_lcd_auto_lock" android:summary="@string/sub_lcd_auto_lock_summary" />
<CheckBoxPreference android:title="@string/key_night_mode" android:key="key_night_mode" />
<ListPreference android:persistent="false" android:entries="@array/key_backlight_entries" android:title="@string/key_backlight" android:key="key_backlight" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/key_backlight_values" />
<ListPreference android:persistent="false" android:entries="@array/touch_key_light_entries" android:title="@string/touch_key_light" android:key="touch_key_light" android:summary="@string/touch_key_light_summary" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/touch_key_light_values" />
<CheckBoxPreference android:persistent="false" android:title="@string/display_saving" android:key="power_saving_mode" android:summary="@string/display_saving_mode_summary" />
<CheckBoxPreference android:persistent="false" android:title="@string/notification_pulse_title" android:key="notification_pulse" />
<CheckBoxPreference android:title="@string/edgezoom_title" android:key="edgezoom_toggle" android:summary="@string/edgezoom_summary" />
<com.loser.colorpicker.ColorPickerPreference android:persistent="false" android:title="@string/statusbar_color_title" android:key="statusbar_color" android:summary="@string/statusbar_color_summary" android:defaultValue="0xff000000" alphaSlider="true" />
<CheckBoxPreference android:title="@string/enable_ime_icon" android:key="enable_ime_icon" android:summary="@string/enable_ime_icon_text" />
[COLOR="Red"]<ListPreference android:persistent="false" android:entries="@array/long_press_kill_entries" android:title="@string/long_press_kill_title" android:key="long_press_kill" android:summary="@string/long_press_kill_summary" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/long_press_kill_values" />[/COLOR]
<PreferenceCategory android:title="@string/battery_icon_category" android:key="battery_icon_category">
<ListPreference android:entries="@array/battery_icon_entries" android:title="@string/battery_icon" android:key="battery_icon_list" android:entryValues="@array/battery_icon_values" />
<CheckBoxPreference android:persistent="false" android:title="@string/display_battery_percentage" android:key="display_battery_level" android:summary="@string/display_battery_percentage_summary" />
<CheckBoxPreference android:title="@string/battery_notif_title" android:key="battery_notif" android:summary="@string/battery_notif_summary" />
</PreferenceCategory>
</PreferenceScreen>
Navigate to /smali/com/android/settings/DisplaySettings.smali
Code:
.field private final mIntentReceiver:Landroid/content/BroadcastReceiver;
.field private mKeyBacklightmode:Landroid/preference/CheckBoxPreference;
[COLOR="red"].field mLongPressKill:Landroid/preference/ListPreference;[/COLOR]
.field private mNotificationPulse:Landroid/preference/CheckBoxPreference;
.field private mPowerSavingMode:Landroid/preference/CheckBoxPreference;
method private updateState()V
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mTouchKeyLight:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "button_key_light"
const/16 v5, 0x5dc
invoke-static {v3, v4, v5}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
invoke-static {v3}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;
move-result-object v3
invoke-virtual {v0, v3}, Landroid/preference/ListPreference;->setValue(Ljava/lang/String;)V
[COLOR="red"]iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "long_press_kill"
const/16 v5, 0x0
invoke-static {v3, v4, v5}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
invoke-static {v3}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;
move-result-object v3
invoke-virtual {v0, v3}, Landroid/preference/ListPreference;->setValue(Ljava/lang/String;)V
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
invoke-virtual {v3}, Landroid/preference/ListPreference;->getEntry()Ljava/lang/CharSequence;
move-result-object v3
invoke-virtual {v0, v3}, Landroid/preference/ListPreference;->setSummary(Ljava/lang/CharSequence;)V[/COLOR]
.line 809
iget-boolean v0, p0, Lcom/android/settings/DisplaySettings;->mSupportFolderType:Z
if-eqz v0, :cond_0
.line 810
invoke-direct {p0}, Lcom/android/settings/DisplaySettings;->updateAccelerometerRotationSecondCheckbox()V
.line 811
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mAutoLockmode:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v4, "sub_lcd_auto_lock"
method public onCreate(Landroid/os/BundleV
Code:
const-string v11, "font_size"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Landroid/preference/ListPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
.line 394
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
[COLOR="red"]const-string v11, "long_press_kill"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Landroid/preference/ListPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V[/COLOR]
.line 398
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getActivity()Landroid/app/Activity;
move-result-object v11
invoke-static {v11}, Lcom/android/settings/Utils;->isTablet(Landroid/content/Context;)Z
move-result v11
if-eqz v11, :cond_6
.method public onPreferenceChange(Landroid/preference/Preference;Ljava/lang/ObjectZ
Code:
:catch_2
move-exception v0
.line 991
const-string v1, "DisplaySettings"
const-string v2, "could not persist Touch key light setting"
invoke-static {v1, v2, v0}, Landroid/util/Log;->secE(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
goto/16 :goto_4
.line 993
:cond_9
[COLOR="red"]const-string v2, "long_press_kill"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_next
.line 986
check-cast p2, Ljava/lang/String;
invoke-static {p2}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I
move-result v0
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const-string v2, "long_press_kill"
invoke-static {v1, v2, v0}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
.line 989
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
invoke-static {v0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;
move-result-object v0
invoke-virtual {v1, v0}, Landroid/preference/ListPreference;->setValue(Ljava/lang/String;)V
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mLongPressKill:Landroid/preference/ListPreference;
invoke-virtual {v1}, Landroid/preference/ListPreference;->getEntry()Ljava/lang/CharSequence;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/preference/ListPreference;->setSummary(Ljava/lang/CharSequence;)V
goto/16 :goto_4
.line 993
:cond_next[/COLOR]
const-string v2, "quick_launch"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_a
.line 994
check-cast p2, Ljava/lang/String;
invoke-static {p2}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I
move-result v0
Now compile and move on to android.policy.jar.
android.policy.jar
Navigate to /smali/com/android/internal/policy/impl/PhoneWindowManager$SettingsObserver.smali
.method observe()V
Code:
const-string v1, "incall_power_button_behavior"
invoke-static {v1}, Landroid/provider/Settings$Secure;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
[COLOR="Red"]const-string v1, "long_press_kill"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V[/COLOR]
.line 878
const-string v1, "accelerometer_rotation"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
Navigate to /smali/com/android/internal/policy/impl/PhoneWindowManager.smali
Code:
.field mAssistKeyLongPressed:Z
.field mBackLongPress:Ljava/lang/Runnable;
[COLOR="Red"].field mBackLongPressKill:Ljava/lang/Runnable;[/COLOR]
.field mBlockCollapseStatusBar:Z
.field mBootCompleteReceiver:Landroid/content/BroadcastReceiver;
Code:
.field mLongPressOnPowerBehavior:I
.field mLongPressVibePattern:[J
[COLOR="red"].field mLongPressKill:I[/COLOR]
.field mMenuLongPress:Ljava/lang/Runnable;
[COLOR="red"].field mMenuLongPressKill:Ljava/lang/Runnable;[/COLOR]
.field mMirrorLinkDockEnablesAccelerometer:Z
.field mMirrorLinkDockIntent:Landroid/content/Intent;
.method public constructor <init>()V
Code:
new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$8;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$8;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mMenuLongPress:Ljava/lang/Runnable;
[COLOR="red"]new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$LongPressKill;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$LongPressKill;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mMenuLongPressKill:Ljava/lang/Runnable;[/COLOR]
.line 1494
new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$9;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$9;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mBackLongPress:Ljava/lang/Runnable;
[COLOR="red"] new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$LongPressKill;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$LongPressKill;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mBackLongPressKill:Ljava/lang/Runnable;[/COLOR]
.line 1505
new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$10;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$10;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mCameraLongPress:Ljava/lang/Runnable;
Add the following methods after .method static getAudioService()Landroid/media/IAudioService;
Code:
.method private getBackKillRunnable()Ljava/lang/Runnable;
.locals 1
.prologue
.line 69
iget v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLongPressKill:I
if-eqz v0, :cond_0
.line 70
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mBackLongPress:Ljava/lang/Runnable;
.line 72
:goto_0
return-object v0
:cond_0
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mBackLongPressKill:Ljava/lang/Runnable;
goto :goto_0
.end method
.method private getMenuKillRunnable()Ljava/lang/Runnable;
.locals 1
.prologue
.line 69
iget v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLongPressKill:I
if-nez v0, :cond_0
.line 70
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mMenuLongPress:Ljava/lang/Runnable;
.line 72
:goto_0
return-object v0
:cond_0
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mMenuLongPressKill:Ljava/lang/Runnable;
goto :goto_0
.end method
.method public interceptKeyBeforeDispatching(Landroid/view/WindowManagerPolicy$WindowState;Landroid/view/KeyEvent;I)J
Code:
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
move-object/from16 v40, v0
move-object/from16 v0, p0
[COLOR="Blue"]iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mMenuLongPress:Ljava/lang/Runnable;
move-object/from16 v41, v0[/COLOR]
[COLOR="RED"]invoke-direct {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getMenuKillRunnable()Ljava/lang/Runnable;
move-result-object v41[/COLOR]
invoke-static {}, Landroid/view/ViewConfiguration;->getGlobalActionKeyTimeout()J
move-result-wide v42
invoke-virtual/range {v40 .. v43}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z
Code:
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
move-object/from16 v40, v0
move-object/from16 v0, p0
[COLOR="blue"]iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mMenuLongPress:Ljava/lang/Runnable;
move-object/from16 v41, v0[/COLOR]
[COLOR="Red"]invoke-direct {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getMenuKillRunnable()Ljava/lang/Runnable;
move-result-object v41[/COLOR]
invoke-virtual/range {v40 .. v41}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V
Code:
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
move-object/from16 v40, v0
move-object/from16 v0, p0
[COLOR="Blue"]iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mBackLongPress:Ljava/lang/Runnable;
move-object/from16 v41, v0[/COLOR]
[COLOR="red"]invoke-direct {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getBackKillRunnable()Ljava/lang/Runnable;
move-result-object v41[/COLOR]
invoke-static {}, Landroid/view/ViewConfiguration;->getGlobalActionKeyTimeout()J
move-result-wide v42
invoke-virtual/range {v40 .. v43}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z
Code:
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
move-object/from16 v40, v0
move-object/from16 v0, p0
[COLOR="Blue"]iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mBackLongPress:Ljava/lang/Runnable;
move-object/from16 v41, v0[/COLOR]
[COLOR="Red"]invoke-direct {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getBackKillRunnable()Ljava/lang/Runnable;
move-result-object v41[/COLOR]
invoke-virtual/range {v40 .. v41}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V
.method public updateSettings()V
Code:
const-string v19, "incall_power_button_behavior"
const/16 v20, 0x1
move-object/from16 v0, v19
move/from16 v1, v20
invoke-static {v13, v0, v1}, Landroid/provider/Settings$Secure;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v9
[COLOR="red"]const-string v19, "long_press_kill"
const/16 v20, 0x0
move-object/from16 v0, v19
move/from16 v1, v20
invoke-static {v13, v0, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLongPressKill:I[/COLOR]
.line 2006
.local v9, incallPowerBehavior:I
const-string v19, "user_rotation"
const/16 v20, 0x0
move-object/from16 v0, v19
move/from16 v1, v20
invoke-static {v13, v0, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v17
Now download the file attached to this post and extract to your android.policy.jar folder.
That's it. Compile and test!
Thanks! Going to try this one tonight.
I really hate to ask this here but I'm not sure where to ask. So I've implemented 2 of your walkthroughs Loser. Brightness slider and the aosp mms and had good success. I know little and follow the walkthroughs to the t and learn that way. I could find a lot of your mods to just flash but I can't learn that way so... if I have questions I'm not really sure who to ask or if anyone wants to be bothered at all.
Are didact's mods, being from Verizon, exactly the same or is it different enough it requires more knowledge on my part ?
I just don't want to fill up the forums with my inane questions lol.
Thanks !
Sent from my SAMSUNG-SGH-I747 using xda premium
hednik said:
Thanks! Going to try this one tonight.
I really hate to ask this here but I'm not sure where to ask. So I've implemented 2 of your walkthroughs Loser. Brightness slider and the aosp mms and had good success. I know little and follow the walkthroughs to the t and learn that way. I could find a lot of your mods to just flash but I can't learn that way so... if I have questions I'm not really sure who to ask or if anyone wants to be bothered at all.
Are didact's mods, being from Verizon, exactly the same or is it different enough it requires more knowledge on my part ?
I just don't want to fill up the forums with my inane questions lol.
Thanks !
Sent from my SAMSUNG-SGH-I747 using xda premium
Click to expand...
Click to collapse
The current Verizon build, or the one that Didact uses is very similar to the AT&T build I use. You very rarely have to change any variables, just the public ID's. If you were to port to another device/build then it get's a little tricky and you need to have a general idea of smali.
awesome job man!
working on this now, for VZW, SecSettings.apk so far is working great, policy is giving me some trouble, I think I found a few mistakes in the tut
Navigate to /smali/com/android/settings/SoundSettings.smali
I think should be
Navigate to /smali/com/android/settings/DisplaySettings.smali
and I got a lil confused in .method public constructor <init>()V
I wasn't sure if I was suppose to add that in or replace it, I think it's suppose to be replaced, testing that now
thank you so much again!
not sure what I'm doing wrong but here is my policy.jar if u have time
andybones said:
awesome job man!
working on this now, for VZW, SecSettings.apk so far is working great, policy is giving me some trouble, I think I found a few mistakes in the tut
Navigate to /smali/com/android/settings/SoundSettings.smali
I think should be
Navigate to /smali/com/android/settings/DisplaySettings.smali
and I got a lil confused in .method public constructor <init>()V
I wasn't sure if I was suppose to add that in or replace it, I think it's suppose to be replaced, testing that now
thank you so much again!
not sure what I'm doing wrong but here is my policy.jar if u have time
Click to expand...
Click to collapse
Haha, Updated the DisplaySettings.smali. Looking at you android.policy now.
You're supposed to just add those lines. Don't remove the mBackLongPress and mMenuLongPress because we want each button to have two options, the regular option which is there by default and the new LongPressKill option. Hope that makes sense.
loserskater said:
Haha, Updated the DisplaySettings.smali. Looking at you android.policy now.
You're supposed to just add those lines. Don't remove the mBackLongPress and mMenuLongPress because we want each button to have two options, the regular option which is there by default and the new LongPressKill option. Hope that makes sense.
Click to expand...
Click to collapse
makes perfect sense , thank you Sir. not sure what I'm missing :/
andybones said:
makes perfect sense , thank you Sir. not sure what I'm missing :/
Click to expand...
Click to collapse
You forgot to change one of the mMenuLongPress lines. And for yours you need to change v41 to v44
Code:
invoke-direct {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getMenuKillRunnable()Ljava/lang/Runnable;
move-result-object [COLOR="Red"]v44[/COLOR]
So that and then add those other lines back in and you should be good to go.
This... Is... AWESOME!
{
"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"
}
7000 lemons? wtf!?!
got a "missing EOF at 'registers"
1990,4. I know the 1990 is the line # because I had one other error when I forgot to put in end of method. Added that and it went away but the the one above it still there. Any idea what to do ? Save redoing it ?
loserskater said:
You forgot to change one of the mMenuLongPress lines. And for yours you need to change v41 to v44
Code:
invoke-direct {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getMenuKillRunnable()Ljava/lang/Runnable;
move-result-object [COLOR="Red"]v44[/COLOR]
So that and then add those other lines back in and you should be good to go.
Click to expand...
Click to collapse
thank you Sir!
menu worked, but back doesn't :/
can you think of something I may have missed or done wrong, I did find that one line that u said i forgot
andybones said:
thank you Sir!
menu worked, but back doesn't :/
can you think of something I may have missed or done wrong, I did find that one line that u said i forgot
Click to expand...
Click to collapse
Can you build a new android.policy for me to look at?
loserskater said:
Can you build a new android.policy for me to look at?
Click to expand...
Click to collapse
absolutely, thank you soo much man!!
andybones said:
absolutely, thank you soo much man!!
Click to expand...
Click to collapse
Thanks for posting in the thread and not pm'ing me!
I'll take a look tonight after work.
Sent from my SAMSUNG-SGH-I747
loserskater said:
Thanks for posting in the thread and not pm'ing me!
I'll take a look tonight after work.
Sent from my SAMSUNG-SGH-I747
Click to expand...
Click to collapse
Haha def apologize about that, I actually saw that yesterday and was going to say something,
Got this working yesterday, sort of .
When I hit the home button it pulls up recent apps overlay but does go to the home menu as well. I get the menu option to show up and the pop up menu as well yet long press to kill doesn't work. I would since the rom boots and nothing force closes I haven't messed up too bad. I think something is a miss in the android policy jar files because (I assume) that is where I am mapping the buttons actions ?
The last steps where to delete in blue and add in red were a bit confusing but I checked and all looked well. Any ideas on how home could have gotten mapped to recents and the other issue ? Anything I can post to maybe help decipher ?
Thanks !
hednik said:
Got this working yesterday, sort of .
When I hit the home button it pulls up recent apps overlay but does go to the home menu as well. I get the menu option to show up and the pop up menu as well yet long press to kill doesn't work. I would since the rom boots and nothing force closes I haven't messed up too bad. I think something is a miss in the android policy jar files because (I assume) that is where I am mapping the buttons actions ?
The last steps where to delete in blue and add in red were a bit confusing but I checked and all looked well. Any ideas on how home could have gotten mapped to recents and the other issue ? Anything I can post to maybe help decipher ?
Thanks !
Click to expand...
Click to collapse
I could prob take a look at your policy.jar if you want. don't wanna step on loseskaters toes here though.
Well I got it working but then his selectable brightness toggle mod was there but it didn't select anything so.... I ditched that build and started new. I tried 5 times and just kept messing it up somehow. Might post it later. Thanks for then offer bones !
Sent from my SAMSUNG-SGH-I747 using xda premium
For those of us not even close to being able to do this, any chance of a flashable zip so I can add this to my current rom? I'm on intergalactic, with the on the fly battery mod and brightness slider toggle added.
Sent from my SAMSUNG-SGH-I747 using xda app-developers app
mis3 said:
For those of us not even close to being able to do this, any chance of a flashable zip so I can add this to my current rom? I'm on intergalactic, with the on the fly battery mod and brightness slider toggle added.
Sent from my SAMSUNG-SGH-I747 using xda app-developers app
Click to expand...
Click to collapse
I'm sorry but that is not the intention of this tread. But if you want a flashable zip with this feature, follow the fist link in my Sig.
Sent from my SAMSUNG-SGH-I747 using xda premium

[MOD][HOW-TO] Quick Unlock on Pin/Password with toggle

This will allow the PIN and Password unlock screens to be unlock as soon as the correct pin/password is input without having to press the enter key to submit.
**UPDATE** Updated for Lollipop
Thanks to @tdunham for updating this guide for 4.4.2. See here: http://forum.xda-developers.com/showpost.php?p=54905593&postcount=54
We're going to be working with the following two files:
SecSettings.apk
android.policy.jar
KEY
REMOVE what's in BLUE
ADD what's in RED
SecSettings.apk
Navigate to /res/values/strings.xml
Add the following to the end of the file
Code:
<string name="quick_unlock_title">Quick Unlock</string>
<string name="quick_unlock_summary">Unlock as soon as correct pin is entered</string>
Navigate to /xml/security_settings_password.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen
xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceScreen android:persistent="false" android:title="@string/unlock_set_unlock_launch_picker_title" android:key="unlock_set_or_change" android:summary="@string/unlock_set_unlock_mode_password" />
<SwitchPreferenceScreen android:title="@string/dualclock_settings_title" android:key="dualclock_settings" android:summary="@string/dualclock_settings_summary" android:fragment="com.android.settings.dualclock.DualClockSetting" />
<CheckBoxPreference android:title="@string/with_cicle_title" android:key="with_circle" android:summary="@string/with_cicle_summary" android:defaultValue="false" />
<PreferenceScreen android:title="@string/lock_screen_options" android:key="lock_screen_options" android:summary="@string/lock_screen_options_summary" android:fragment="com.android.settings.LockScreenSettings" />
<CheckBoxPreference android:title="@string/quick_note_title" android:key="quick_note" android:summary="@string/quick_note_summary" android:defaultValue="false" />
<ListPreference android:persistent="false" android:entries="@array/lock_after_timeout_entries" android:title="@string/lock_after_timeout" android:key="lock_after_timeout" android:summary="@string/lock_after_timeout_summary" android:entryValues="@array/lock_after_timeout_values" />
<CheckBoxPreference android:title="@string/lockpattern_settings_enable_power_button_instantly_locks" android:key="power_button_instantly_locks" />
[COLOR="Red"]<CheckBoxPreference android:title="@string/quick_unlock_title" android:key="quick_unlock" android:summary="@string/quick_unlock_summary" />[/COLOR]
<PreferenceScreen android:title="@string/owner_info_settings_title" android:key="owner_info_settings" android:summary="@string/owner_info_settings_summary" android:fragment="com.android.settings.OwnerInfoSettings" />
</PreferenceScreen>
Navigate to /xml/security_settings_pin.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen
xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceScreen android:persistent="false" android:title="@string/unlock_set_unlock_launch_picker_title" android:key="unlock_set_or_change" android:summary="@string/unlock_set_unlock_mode_pin" />
<SwitchPreferenceScreen android:title="@string/dualclock_settings_title" android:key="dualclock_settings" android:summary="@string/dualclock_settings_summary" android:fragment="com.android.settings.dualclock.DualClockSetting" />
<CheckBoxPreference android:title="@string/with_cicle_title" android:key="with_circle" android:summary="@string/with_cicle_summary" android:defaultValue="false" />
<PreferenceScreen android:title="@string/lock_screen_options" android:key="lock_screen_options" android:summary="@string/lock_screen_options_summary" android:fragment="com.android.settings.LockScreenSettings" />
<CheckBoxPreference android:title="@string/quick_note_title" android:key="quick_note" android:summary="@string/quick_note_summary" android:defaultValue="false" />
<ListPreference android:persistent="false" android:entries="@array/lock_after_timeout_entries" android:title="@string/lock_after_timeout" android:key="lock_after_timeout" android:summary="@string/lock_after_timeout_summary" android:entryValues="@array/lock_after_timeout_values" />
<CheckBoxPreference android:title="@string/lockpattern_settings_enable_power_button_instantly_locks" android:key="power_button_instantly_locks" />
<CheckBoxPreference android:title="@string/lockpattern_settings_enable_tactile_feedback_title" android:key="unlock_tactile_feedback" />
[COLOR="red"]<CheckBoxPreference android:title="@string/quick_unlock_title" android:key="quick_unlock" android:summary="@string/quick_unlock_summary" />[/COLOR]
<PreferenceScreen android:title="@string/owner_info_settings_title" android:key="owner_info_settings" android:summary="@string/owner_info_settings_summary" android:fragment="com.android.settings.OwnerInfoSettings" />
</PreferenceScreen>
Navigate to /smali/com/android/settings/LockscreenMenuSettings.smali
Code:
.field private mPowerButtonInstantlyLocks:Landroid/preference/CheckBoxPreference;
.field private mQuicknote:Landroid/preference/CheckBoxPreference;
[COLOR="red"].field private mQuickUnlock:Landroid/preference/CheckBoxPreference;[/COLOR]
.field private mSignatureVerificationLevel:Landroid/preference/ListPreference;
.field private mTactileFeedback:Landroid/preference/CheckBoxPreference;
.method private createPreferenceHierarchy()Landroid/preference/PreferenceScreen;
WAIT!
WAIT!
You need to grab some ID's. Luckily they're already available so no need to compile, etc.!
There's only two.
Code:
:cond_5
const-string v4, "quick_note"
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v4
check-cast v4, Landroid/preference/CheckBoxPreference;
iput-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
.line 203
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
if-eqz v4, :cond_6
const v4, 0x7f07004f
if-eq v2, v4, :cond_6
.line 205
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->removePreference(Landroid/preference/Preference;)Z
.line 208
:cond_6
[COLOR="red"] const-string v4, "quick_unlock"
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v4
check-cast v4, Landroid/preference/CheckBoxPreference;
iput-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
.line 203
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
if-eqz v4, :cond_next
const v4, 0x7f070051 # type="xml" name="security_settings_password"
if-eq v2, v4, :cond_next
const v4, 0x7f070054 # type="xml" name="security_settings_pin"
if-eq v2, v4, :cond_next
.line 205
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->removePreference(Landroid/preference/Preference;)Z
:cond_next[/COLOR]
const-string v4, "visiblesignature"
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v4
check-cast v4, Landroid/preference/CheckBoxPreference;
iput-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mVisibleSignature:Landroid/preference/CheckBoxPreference;
WAIT!
WAIT!
Did you replace those two ID's in that last section? Good. Let's continue.
.method public onPreferenceTreeClick(Landroid/preference/PreferenceScreen;Landroid/preference/PreferenceZ
Code:
:cond_8
const-string v5, "quick_note"
invoke-virtual {v5, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v5
if-eqz v5, :cond_a
.line 503
invoke-virtual {p0}, Lcom/android/settings/LockscreenMenuSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v5
const-string v6, "lock_screen_quick_note"
iget-object v7, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
invoke-virtual {v7}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v7
if-eqz v7, :cond_9
move v3, v4
:cond_9
invoke-static {v5, v6, v3}, Landroid/provider/Settings$Secure;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_0
.line 504
:cond_a
[COLOR="red"]const-string v5, "quick_unlock"
invoke-virtual {v5, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v5
if-eqz v5, :cond_next
.line 503
invoke-virtual {p0}, Lcom/android/settings/LockscreenMenuSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v5
const-string v6, "quick_unlock"
iget-object v7, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
invoke-virtual {v7}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v7
if-eqz v7, :cond_quick
move v3, v4
:cond_quick
invoke-static {v5, v6, v3}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_0
.line 504
:cond_next[/COLOR]
const-string v3, "visiblesignature"
invoke-virtual {v3, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-eqz v3, :cond_b
.method public onResume()V
Code:
:cond_2
iget-object v1, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
if-eqz v1, :cond_3
.line 438
iget-object v1, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/LockscreenMenuSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
const-string v5, "lock_screen_quick_note"
invoke-static {v4, v5, v3}, Landroid/provider/Settings$Secure;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v4
if-eqz v4, :cond_8
:goto_1
invoke-virtual {v1, v2}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 440
:cond_3
[COLOR="red"]iget-object v1, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
if-eqz v1, :cond_next
.line 438
iget-object v1, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/LockscreenMenuSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
const-string v5, "quick_unlock"
invoke-static {v4, v5, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v4
if-eqz v4, :cond_quick
:goto_quick
invoke-virtual {v1, v2}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 440
:cond_next[/COLOR]
iget-object v1, p0, Lcom/android/settings/LockscreenMenuSettings;->mVisibleSignature:Landroid/preference/CheckBoxPreference;
if-eqz v1, :cond_4
.line 441
iget-object v1, p0, Lcom/android/settings/LockscreenMenuSettings;->mVisibleSignature:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Lcom/android/internal/widget/LockPatternUtils;->isVisibleSignatureEnabled()Z
move-result v2
invoke-virtual {v1, v2}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
Code:
:cond_7
move v1, v3
.line 434
goto :goto_0
:cond_8
move v2, v3
.line 438
goto :goto_1
[COLOR="red"]:cond_quick
move v2, v3
goto :goto_quick[/COLOR]
.end method
That's it for SecSettings. Compile.
android.policy.jar
4.1.x
Navigate to /smali/com/android/internal/policy/impl/PasswordUnlockScreen.smali
Code:
.field private mPwdPolicy:Landroid/app/enterprise/PasswordPolicy;
.field private mResuming:Z
[COLOR="Red"].field private mQuickUnlock:Z[/COLOR]
.field private final mStatusViewManager:Lcom/android/internal/policy/impl/KeyguardStatusViewManager;
.field private final mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;
.method public constructor <init>(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallbackV
Code:
iget-object v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mPasswordEntry:Landroid/widget/EditText;
const/16 v2, 0x81
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setInputType(I)V
.line 250
:goto_4
iget-object v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mPasswordEntry:Landroid/widget/EditText;
new-instance v2, Lcom/android/internal/policy/impl/PasswordUnlockScreen$4;
invoke-direct {v2, p0}, Lcom/android/internal/policy/impl/PasswordUnlockScreen$4;-><init>(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)V
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 255
[COLOR="red"]iget-object v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const/4 v3, 0x0
const-string v9, "quick_unlock"
invoke-static {v1, v9, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v1
const/4 v2, 0x1
if-ne v1, v2, :cond_quick
move v1, v2
:goto_quick
iput-boolean v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mQuickUnlock:Z[/COLOR]
iget-object v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mPasswordEntry:Landroid/widget/EditText;
new-instance v2, Lcom/android/internal/policy/impl/PasswordUnlockScreen$5;
invoke-direct {v2, p0}, Lcom/android/internal/policy/impl/PasswordUnlockScreen$5;-><init>(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)V
invoke-virtual {v1, v2}, Landroid/widget/EditText;->addTextChangedListener(Landroid/text/TextWatcher;)V
Code:
new-instance v1, Lcom/android/internal/policy/impl/PasswordUnlockScreen$2;
invoke-direct {v1, p0}, Lcom/android/internal/policy/impl/PasswordUnlockScreen$2;-><init>(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)V
invoke-virtual {v10, v1}, Landroid/view/View;->setOnLongClickListener(Landroid/view/View$OnLongClickListener;)V
goto/16 :goto_3
.line 181
.end local v10 #pinDelete:Landroid/view/View;
:cond_f
const/4 v1, 0x0
goto :goto_5
[COLOR="red"]:cond_quick
move v1, v3
goto :goto_quick[/COLOR]
.line 242
:cond_10
iget-object v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mPasswordEntry:Landroid/widget/EditText;
invoke-static {}, Landroid/text/method/DigitsKeyListener;->getInstance()Landroid/text/method/DigitsKeyListener;
move-result-object v2
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setKeyListener(Landroid/text/method/KeyListener;)V
.line 243
iget-object v1, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mPasswordEntry:Landroid/widget/EditText;
const/16 v2, 0x12
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setInputType(I)V
goto/16 :goto_4
.end method
Add the following methods:
Code:
.method static synthetic access$100(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)Landroid/widget/EditText;
.locals 1
.parameter "x0"
.prologue
.line 76
iget-object v0, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mPasswordEntry:Landroid/widget/EditText;
return-object v0
.end method
[COLOR="Red"].method static synthetic access$1000(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)Z
.locals 1
.parameter "x0"
.prologue
.line 76
iget-boolean v0, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mQuickUnlock:Z
return v0
.end method
.method static synthetic access$1100(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)Lcom/android/internal/widget/LockPatternUtils;
.locals 1
.parameter "x0"
.prologue
.line 76
iget-object v0, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;
return-object v0
.end method[/COLOR]
.method static synthetic access$200(Lcom/android/internal/policy/impl/PasswordUnlockScreen;)Lcom/android/internal/policy/impl/KeyguardScreenCallback;
.locals 1
.parameter "x0"
.prologue
.line 76
iget-object v0, p0, Lcom/android/internal/policy/impl/PasswordUnlockScreen;->mCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;
return-object v0
.end method
Now download the zip attached to this post and extract to the root of your project.
Compile and enjoy!
4.3
Navigate to smali/com/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView.smali
Add the following in red:
Code:
.field protected mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;
.field protected mPasswordEntry:Landroid/widget/TextView;
[COLOR="Red"].field private mQuickUnlock:Z[/COLOR]
Add the following method in red:
Code:
.method static synthetic access$300(Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;)Landroid/widget/Button;
.locals 1
.parameter "x0"
.prologue
.line 68
iget-object v0, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;->mEmergencyButton:Landroid/widget/Button;
return-object v0
.end method
[COLOR="red"].method static synthetic access$400(Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;)Z
.locals 1
.parameter "x0"
.prologue
.line 42
iget-boolean v0, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;->mQuickUnlock:Z
return v0
.end method[/COLOR]
.method protected onFinishInflate()V
Make sure this is larger than 3
Code:
.method protected onFinishInflate()V
[COLOR="Red"] .locals 4[/COLOR]
Code:
.line 176
iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;->mPasswordEntry:Landroid/widget/TextView;
new-instance v2, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView$1;
invoke-direct {v2, p0}, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView$1;-><init>(Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;)V
invoke-virtual {v1, v2}, Landroid/widget/TextView;->setOnClickListener(Landroid/view/View$OnClickListener;)V
[COLOR="red"]iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const-string v2, "quick_unlock"
const/4 v3, 0x0
invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v1
if-eqz v1, :cond_quick
const/4 v1, 0x1
:goto_0
iput-boolean v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;->mQuickUnlock:Z[/COLOR]
.line 182
iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;->mPasswordEntry:Landroid/widget/TextView;
new-instance v2, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView$2;
invoke-direct {v2, p0}, Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView$2;-><init>(Lcom/android/internal/policy/impl/keyguard/KeyguardAbsKeyInputView;)V
invoke-virtual {v1, v2}, Landroid/widget/TextView;->addTextChangedListener(Landroid/text/TextWatcher;)V
Code:
:cond_2
return-void
[COLOR="red"]:cond_quick
const/4 v1, 0x0
goto :goto_0[/COLOR]
.end method
Awesome stuff my man!
(P.S. I think you might have a toggle problem. )
Edit:
Works perfect. :good:
upndwn4par said:
Awesome stuff my man!
(P.S. I think you might have a toggle problem. )
Click to expand...
Click to collapse
I love me some toggles!
loserskater said:
I love me some toggles!
Click to expand...
Click to collapse
I love how all of your mods include the toggle in the Settings app! I hate having to have a seperate tweak/mod app.
Much props and huge apprectiation for passing on your modding/deving knowledge!
Sent from my SAMSUNG-SGH-I747 using xda app-developers app
Thanks man for this feature. For me this will be the killer feature on Touchwiz ROM. Do we need decomplie the APK and JAR file mentioned in the OP. I am bad in coding
shane87 said:
I love how all of your mods include the toggle in the Settings app! I hate having to have a seperate tweak/mod app.
Much props and huge apprectiation for passing on your modding/deving knowledge!
Sent from my SAMSUNG-SGH-I747 using xda app-developers app
Click to expand...
Click to collapse
It's good, but awkward on updates!
Many thanks for this! do you know if it will work on a galaxy note 2 tw based 4.1.2 rom? no worries if not, i will try later and let you guys know
Found it in values/public. notepad++ was being finicky when I searched
Thanks for this brother, and for sharing all your knowledge
worked like a dream. Thanks !
I'm trying to follow your guide but I am getting a compile error at the end and I think I'm lost on this part that you explain...
---------------------------------------------------------------------------------------------------------------------
.method private createPreferenceHierarchy()Landroid/preference/PreferenceScreen;
WAIT!
WAIT!
You need to grab some ID's. Luckily they're already available so no need to compile, etc.!
There's only two.
Code:
:cond_5
const-string v4, "quick_note"
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->findPreference(Ljava/lang/CharSequenceLandroid/preference/Preference;
move-result-object v4
check-cast v4, Landroid/preference/CheckBoxPreference;
iput-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
.line 203
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
if-eqz v4, :cond_6
const v4, 0x7f07004f
if-eq v2, v4, :cond_6
.line 205
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuicknote:Landroid/preference/CheckBoxPreference;
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->removePreference(Landroid/preference/PreferenceZ
.line 208
:cond_6
const-string v4, "quick_unlock"
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->findPreference(Ljava/lang/CharSequenceLandroid/preference/Preference;
move-result-object v4
check-cast v4, Landroid/preference/CheckBoxPreference;
iput-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
.line 203
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
if-eqz v4, :cond_next
const v4, 0x7f070051 # type="xml" name="security_settings_password"
if-eq v2, v4, :cond_next
const v4, 0x7f070054 # type="xml" name="security_settings_pin"
if-eq v2, v4, :cond_next
.line 205
iget-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mQuickUnlock:Landroid/preference/CheckBoxPreference;
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->removePreference(Landroid/preference/PreferenceZ
:cond_next
const-string v4, "visiblesignature"
invoke-virtual {v3, v4}, Landroid/preference/PreferenceScreen;->findPreference(Ljava/lang/CharSequenceLandroid/preference/Preference;
move-result-object v4
check-cast v4, Landroid/preference/CheckBoxPreference;
iput-object v4, p0, Lcom/android/settings/LockscreenMenuSettings;->mVisibleSignature:Landroid/preference/CheckBoxPreference;
WAIT!
WAIT!
Did you replace those two ID's in that last section? Good. Let's continue.
-----------------------------------------------------------------------------------------------------------------
I was just adding the red. What do you mean by grabbing ID's and replacing ID's? Specific thing that's not universal that I have to figure out?(sorry for ignorance, i'm not a developer/experienced with coding)
lmike6453 said:
I'm trying to follow your guide but I am getting a compile error at the end and I think I'm lost on this part that you explain...
I was just adding the red. What do you mean by grabbing ID's and replacing ID's? Specific thing that's not universal that I have to figure out?(sorry for ignorance, i'm not a developer/experienced with coding)
Click to expand...
Click to collapse
Look in the code for lines that have the #
Code:
const v4, [COLOR="Red"]0x7f070051[/COLOR] # type="xml" name="security_settings_password"
Now search in /res/values/public.xml for what's after the #
You should see something like
Code:
<public type="xml" name="security_settings_pattern" id="[COLOR="red"]0x7f070051[/COLOR]" />
Now look back at the line in the smali and replace the 0x7fxxxxxx with what is in your public.xml (Match what's in red)
loserskater said:
Look in the code for lines that have the #
Code:
const v4, [COLOR="Red"]0x7f070051[/COLOR] # type="xml" name="security_settings_password"
Now search in /res/values/public.xml for what's after the #
You should see something like
Code:
<public type="xml" name="security_settings_pattern" id="[COLOR="red"]0x7f070051[/COLOR]" />
Now look back at the line in the smali and replace the 0x7fxxxxxx with what is in your public.xml (Match what's in red)
Click to expand...
Click to collapse
Loser,
He has a point as the way you explain about the part in getting the id's is a bit different than I've seen in others. I had to do a double take to make sure I was understanding the wording.
I love this mod though...so simple but negates out the "ok" step to make it seem more fluid
Remember that doing these mods is not for everyone. Loser is very kind to even bother explaining how to match the ids (or anything else for that matter). Most devs post the mod and don't offer any support. Everyone should try not to bother him too much.
upndwn4par said:
Remember that doing these mods is not for everyone. Loser is very kind to even bother explaining how to match the ids (or anything else for that matter). Most devs post the mod and don't offer any support. Everyone should try not to bother him too much.
Click to expand...
Click to collapse
Just trying to see where the guy was coming from. I myself probably didn't even come across how I meant to. I wasn't complaining.
So if I'm not "good enough" I don't need to post ?
loserskater said:
Look in the code for lines that have the #
Code:
const v4, [COLOR="Red"]0x7f070051[/COLOR] # type="xml" name="security_settings_password"
Now search in /res/values/public.xml for what's after the #
You should see something like
Code:
<public type="xml" name="security_settings_pattern" id="[COLOR="red"]0x7f070051[/COLOR]" />
Now look back at the line in the smali and replace the 0x7fxxxxxx with what is in your public.xml (Match what's in red)
Click to expand...
Click to collapse
Many thanks for the reply and guidance! I can understand how annoying dumb questions can get and I hope that mine does not discourage ya in any way.
Always know that ppl in my shoes that are just "getting my feet wet" appreciate it that much more since your guides for such useful MODS are a rarity among developers as upndwn4par explained.
I will give it another go and post back my findings for TW based 4.1.2 ROM for Galaxy Note 2 that I'll be attempting it for :good:
hednik said:
Just trying to see where the guy was coming from. I myself probably didn't even come across how I meant to. I wasn't complaining.
So if I'm not "good enough" I don't need to post ?
Click to expand...
Click to collapse
That was not directed at you buddy, but everyone in general.
Just reminding everyone that these are dev level mods.
I post these guides in hopes that people will attempt to get into learning how they work instead of just copy and pasting the guide. I know smali is a crazy foreign language to most people and it is a very steep learning curve, but anybody that sees these guides and starts seeing patterns, and then attempt to do their own mods is a great success to me.
You're right that the ID section is vague, but I'm hoping that people have done enough mods that they will understand what is meant. It's just one of those things that I don't want to post in every how-to. I have mulitple guides that explain how to get IDs that I don't see the point in posting it over and over. I also don't mind answering people that have issues with getting ID's (as you can see in my previous post) so it's not that big of an issue.
And I don't mind being bothered as long as it's in my thread and not a PM. I'm MUCH more likely to help if you post in the thread. It also allows other users to help out if they've come across the issue you're having which helps me out a lot.
Hi Loserskater,
I'm trying to apply the mod to the Galaxy S2. When i apply the changes to SecSettings.apk, I get an error:
Code:
I: Smaling...
[3177,16] Label "cond_quick" is not defined.
Exception in thread "main" brut.androlib.AndrolibException: Could not smali file
: C:\Users\Do Khac Minh Duc\Desktop\apktool\SecSettings\smali\com\android\settin
gs\LockscreenMenuSettings.smali
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexFileBuilder.java:45)
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexFileBuilder.java:33)
at brut.androlib.src.SmaliBuilder.buildFile(SmaliBuilder.java:66)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:50)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:37)
at brut.androlib.Androlib.buildSourcesSmali(Androlib.java:257)
at brut.androlib.Androlib.buildSources(Androlib.java:214)
at brut.androlib.Androlib.build(Androlib.java:205)
at brut.androlib.Androlib.build(Androlib.java:176)
at brut.apktool.Main.cmdBuild(Main.java:228)
at brut.apktool.Main.main(Main.java:79)
Can you please tell me, what I'm doing wrong? I have already changed line references to match the S2 smali.
I'll attach the publics.xml and LockscreenMenuSettings.smali.
Thanks for your response in advance!

[Porting Guide][CM10/JB] Mod 4.2 Statusbar Quicksettings ( TABS, Slider, Flip Anim )

PORTING GUIDE - MOD 4.2 STATUSBAR
( TABS, Slider, Flip button with Flip Anim, )
FOR CM10 / JB 4.1
This is been requested so many times, so here I made the guide
I will write the guide is basically for CM10, and for other base rom/devices should adapt / compare it.
But don't use it on ICS 4.0/JB 4.2/JB 4.3.
Credit & Thanks to
- Recognized Themer @serajr, coz this mod will be impossible without his amazing work 4.2 style statusbar for Xperia ICS devices,.
and me for porting it to CM9 & CM10
- Senior Member legend @lidroid for his toggle code
- Recognized Developer @wanam for his JB lidroid code & LidroidSettings.apk
- Recognized Developer @arco68 for giving our device GT-I8150 Galaxy Wonder CyanogenMod rom, coz without him, I will never have JB or ICS on my device
- My hometown Tanjung Karang,. Api kabarr ?? LOlss
- PM me if I've missed someone/something
ok lets go to Guide:
first of all need some requirement for this MOD-GUIDE
REQUIREMENT:
- BRAIN
- Patient
- experience
- Know how to decompile/recompiling Apk file
- notepad++
- Tool for decompiling, : apkmanager/apktool/Virtous/apkmultitools/ or else
STEP -1
Decompile Settings.apk, we are going to remove CM PowerWidget settings and add Lidroid settings.
Settings.apk\res\xml\system_settings.xml and remove the red code :
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen android:title="@string/system_interface_title"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:settings="http://schemas.android.com/apk/res/com.android.settings">
<PreferenceScreen android:title="@string/combined_status_bar_title" android:key="status_bar" android:fragment="com.android.settings.cyanogenmod.StatusBar" />
[COLOR="Red"]<PreferenceScreen android:title="@string/notification_drawer_title" android:key="notification_drawer" android:fragment="com.android.settings.cyanogenmod.PowerWidget" />[/COLOR]
<PreferenceScreen android:title="@string/notification_drawer_title" android:key="notification_drawer_tablet" android:fragment="com.android.settings.cyanogenmod.TabletPowerWidget" />
<PreferenceScreen android:title="@string/wallpaper_settings_title" android:key="wallpaper" android:fragment="com.android.settings.WallpaperTypeSettings" />
<ListPreference android:entries="@array/entries_font_size" android:title="@string/title_font_size" android:key="font_size" android:summary="@string/summary_font_size" android:dialogTitle="@string/dialog_title_font_size" android:entryValues="@array/entryvalues_font_size" />
<PreferenceScreen android:title="@string/power_menu_title" android:key="power_menu" android:fragment="com.android.settings.cyanogenmod.PowerMenu" />
<PreferenceScreen android:title="@string/navigation_bar_title" android:key="navigation_bar" android:fragment="com.android.settings.cyanogenmod.NavBar" />
<PreferenceScreen android:title="@string/hardware_keys_title" android:key="hardware_keys" android:fragment="com.android.settings.cyanogenmod.HardwareKeys" />
</PreferenceScreen>
- Settings.apk\res\xml\settings_headers.xml and add the blue code
Code:
<header android:title="@string/header_category_interface" />
<header android:icon="@drawable/ic_settings_cmlauncher" android:id="@id/launcher_settings" android:title="@string/launcher_settings_title" />
<header android:icon="@drawable/ic_settings_lockscreen" android:id="@id/lock_screen_settings" android:title="@string/lock_screen_title" android:fragment="com.android.settings.cyanogenmod.LockscreenInterface" />
<header android:icon="@drawable/ic_settings_themes" android:id="@id/themes_settings" android:title="@string/themes_settings_title">
<intent android:targetPackage="com.tmobile.themechooser" android:action="android.intent.action.MAIN" android:targetClass="com.tmobile.themechooser.ThemeChooser" />
</header>
<header android:icon="@drawable/ic_settings_system" android:id="@id/system_settings" android:title="@string/system_settings_title" android:fragment="com.android.settings.cyanogenmod.SystemSettings" />
[COLOR="Blue"]<header android:icon="@drawable/ic_settings_advanced" android:id="@id/adi_buttons" android:title="@string/adi_buttons_title">
<intent android:targetPackage="com.lidroid.settings" android:action="android.intent.action.MAIN" android:targetClass="com.lidroid.settings.Settings" />
</header>[/COLOR]
<header android:title="@string/header_category_device" />
<header android:icon="@drawable/ic_settings_sound" android:id="@id/sound_settings" android:title="@string/sound_settings" android:fragment="com.android.settings.SoundSettings" />
<header android:icon="@drawable/ic_settings_display" android:id="@id/display_settings" android:title="@string/display_settings" android:fragment="com.android.settings.DisplaySettings" />
<header android:icon="@drawable/ic_settings_storage" android:id="@id/storage_settings" android:title="@string/storage_settings" android:fragment="com.android.settings.deviceinfo.Memory" />
<header android:icon="@drawable/ic_settings_battery" android:id="@id/battery_settings" android:title="@string/power_usage_summary_title" android:fragment="com.android.settings.fuelgauge.PowerUsageSummary" />
Settings.apk\res\values\strings.xml
Code:
<string name="gestures_action_menu">Emulate Menu key</string>
<string name="gestures_action_search">Invoke search</string>
<string name="gestures_action_recent">Recent applications</string>
[COLOR="Blue"]<string name="adi_buttons_title">Power Widget</string>[/COLOR]
</resources>
Settings.apk\res\values\ids.xml
Code:
<item type="id" name="action_delete">false</item>
<item type="id" name="action_select_all">false</item>
<item type="id" name="storage_usb">false</item>
<item type="id" name="wifi_wps">false</item>
[COLOR="Blue"]<item type="id" name="adi_buttons">false</item>[/COLOR]
</resources>
download attached ic_settings_advanced.zip, unzip it and
put it to Settings.apk\res\drawable-hdpi
done and recompile your settings.apk
NEXT
Download attached LidroidSettings.apk and push to System/App with right permission
CONTINUE THE GUIDE IN POST #2
STEP - 2
Decompile SystemUI.apk
make change to
SystemUI.apk\res\layout\status_bar_expanded.xml
BEFORE
Code:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout android:id="@id/notification_panel" android:background="@drawable/notification_panel_bg" android:paddingTop="@dimen/notification_panel_padding_top" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginLeft="@dimen/notification_panel_margin_left"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network" android:gravity="center" android:layout_gravity="bottom" android:id="@id/carrier_label" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="@dimen/carrier_label_height" android:layout_marginBottom="@dimen/close_handle_height" />
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginBottom="@dimen/close_handle_underlap">
<include android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_header_height" layout="@layout/status_bar_expanded_header" />
<com.android.systemui.statusbar.powerwidget.PowerWidget android:id="@id/exp_power_stat" android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_widget_height" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network.EmergencyOnly" android:gravity="center" android:id="@id/emergency_calls_only" android:paddingBottom="4.0dip" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="wrap_content" />
<ScrollView android:id="@id/scroll" android:fadingEdge="none" android:layout_width="fill_parent" android:layout_height="fill_parent" android:overScrollMode="always">
<com.android.systemui.statusbar.policy.NotificationRowLayout android:id="@id/latestItems" android:layout_width="fill_parent" android:layout_height="wrap_content" systemui:rowHeight="@dimen/notification_row_min_height" />
</ScrollView>
</LinearLayout>
<com.android.systemui.statusbar.phone.CloseDragHandle android:layout_gravity="bottom" android:orientation="vertical" android:id="@id/close" android:layout_width="fill_parent" android:layout_height="@dimen/close_handle_height">
<ImageView android:layout_gravity="bottom" android:layout_width="fill_parent" android:layout_height="@dimen/close_handle_height" android:src="@drawable/status_bar_close" android:scaleType="fitXY" />
</com.android.systemui.statusbar.phone.CloseDragHandle>
</FrameLayout>
AFTER
Code:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout android:id="@id/notification_panel" android:background="@drawable/notification_panel_bg" android:paddingTop="@dimen/notification_panel_padding_top" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginLeft="@dimen/notification_panel_margin_left"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network" android:gravity="center" android:layout_gravity="bottom" android:id="@id/carrier_label" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="@dimen/carrier_label_height" android:layout_marginBottom="@dimen/close_handle_height" />
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginBottom="@dimen/close_handle_underlap">
<include android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_header_height" layout="@layout/status_bar_expanded_header" />
<ViewFlipper android:id="@id/contents_flipper" android:layout_width="fill_parent" android:layout_height="wrap_content"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network.EmergencyOnly" android:gravity="center" android:id="@id/emergency_calls_only" android:paddingBottom="4.0dip" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="wrap_content" />
<ScrollView android:id="@id/scroll" android:fadingEdge="none" android:layout_width="fill_parent" android:layout_height="fill_parent" android:overScrollMode="ifContentScrolls">
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content">
<com.android.systemui.statusbar.policy.NotificationRowLayout android:id="@id/latestItems" android:layout_width="fill_parent" android:layout_height="wrap_content" systemui:rowHeight="@dimen/notification_row_min_height" />
</LinearLayout>
</ScrollView>
<ImageView android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent" android:src="@drawable/title_bar_shadow" android:scaleType="fitXY" />
</FrameLayout>
<include android:layout_width="fill_parent" android:layout_height="fill_parent" layout="@layout/status_bar_expanded_quickpanel" />
</ViewFlipper>
</LinearLayout>
<com.android.systemui.statusbar.phone.CloseDragHandle android:layout_gravity="bottom" android:orientation="vertical" android:id="@id/close" android:layout_width="fill_parent" android:layout_height="@dimen/close_handle_height">
<ImageView android:layout_gravity="bottom" android:layout_width="fill_parent" android:layout_height="@dimen/close_handle_height" android:src="@drawable/status_bar_close" android:scaleType="fitXY" />
</com.android.systemui.statusbar.phone.CloseDragHandle>
</FrameLayout>
SystemUI.apk\res\layout\status_bar_expanded_header.xml
BEFORE
Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:background="@drawable/notification_header_bg" android:layout_width="fill_parent" android:layout_height="wrap_content" android:baselineAligned="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Clock" android:id="@id/clock" android:clickable="true" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:singleLine="true" />
<com.android.systemui.statusbar.policy.DateView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Date" android:id="@id/date" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:layout_marginRight="8.0dip" />
<LinearLayout android:id="@id/buttons_bar" android:layout_width="wrap_content" android:layout_height="wrap_content">
<com.android.systemui.statusbar.RotationToggle android:id="@id/rotation_lock_button" android:clickable="true" android:layout_width="32.0dip" android:layout_height="32.0dip" android:layout_margin="8.0dip" android:button="@drawable/ic_notify_rotation" android:contentDescription="@string/accessibility_rotation_lock_off" />
<ImageView android:id="@id/settings_button" android:layout_width="48.0dip" android:layout_height="48.0dip" android:src="@drawable/ic_notify_quicksettings" android:scaleType="center" android:contentDescription="@string/accessibility_settings_button" />
</LinearLayout>
<Space android:layout_width="0.0dip" android:layout_height="0.0dip" android:layout_weight="1.0" />
<ImageView android:id="@id/clear_all_button" android:layout_width="48.0dip" android:layout_height="48.0dip" android:src="@drawable/ic_notify_clear" android:scaleType="center" android:contentDescription="@string/accessibility_clear_all" />
</LinearLayout>
AFTER
Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:background="#ff000000" android:layout_width="fill_parent" android:layout_height="wrap_content" android:baselineAligned="false"
xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout android:id="@id/datetime" android:background="#ff000000" android:paddingTop="3.0dip" android:paddingRight="3.0dip" android:paddingBottom="5.0dip" android:layout_width="fill_parent" android:layout_height="48.0dip">
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Clock" android:id="@id/clock" android:clickable="true" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:singleLine="true" />
<com.android.systemui.statusbar.policy.DateView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Date" android:id="@id/date" android:paddingTop="3.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:layout_marginRight="8.0dip" android:layout_toRightOf="@id/clock" />
<LinearLayout android:id="@id/buttons_bar" android:layout_width="wrap_content" android:layout_height="wrap_content">
<com.android.systemui.statusbar.RotationToggle android:id="@id/rotation_lock_button" android:clickable="true" android:layout_width="32.0dip" android:layout_height="32.0dip" android:layout_margin="8.0dip" android:button="@drawable/ic_notify_rotation" android:contentDescription="@string/accessibility_rotation_lock_off" />
</LinearLayout>
<ViewFlipper android:id="@id/header_flipper" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="2.0dip" android:layout_alignParentRight="true"
xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout android:layout_width="wrap_content" android:layout_height="fill_parent">
<ImageView android:id="@id/flip_to_quickpanel_button" android:layout_width="50.0dip" android:layout_height="50.0dip" android:src="@drawable/ic_notify_quicksettings" android:scaleType="center" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_desc_quick_settings" />
<ImageView android:id="@id/clear_all_button" android:layout_width="50.0dip" android:layout_height="50.0dip" android:src="@drawable/ic_notify_clear" android:scaleType="center" android:layout_toLeftOf="@id/flip_to_quickpanel_button" android:contentDescription="@string/accessibility_clear_all" />
</RelativeLayout>
<RelativeLayout android:layout_width="wrap_content" android:layout_height="fill_parent">
<ImageView android:id="@id/flip_to_notifications_button" android:layout_width="50.0dip" android:layout_height="50.0dip" android:src="@drawable/ic_notifications" android:scaleType="center" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_notifications_button" />
</RelativeLayout>
</ViewFlipper>
</RelativeLayout>
</LinearLayout>
NEW CODE FOR status_bar_expanded_header.xml ( fixed DateView layout )
AFTER
Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:background="#ff000000" android:layout_width="fill_parent" android:layout_height="wrap_content" android:baselineAligned="false"
xmlns:android="http://schemas.android.com/apk/res/android">
[COLOR="Blue"]<RelativeLayout android:id="@id/datetime" android:background="#ff000000" android:layout_width="fill_parent" android:layout_height="48.0dip">[/COLOR]
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Clock" android:id="@id/clock" android:clickable="true" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:singleLine="true" />
[COLOR="Blue"]<com.android.systemui.statusbar.policy.DateView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Date" android:id="@id/date" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8.0dip" android:layout_marginTop="8.0dip" android:layout_marginRight="8.0dip" android:layout_marginBottom="8.0dip" android:layout_toRightOf="@id/clock" />[/COLOR]
<LinearLayout android:id="@id/buttons_bar" android:layout_width="wrap_content" android:layout_height="wrap_content">
<com.android.systemui.statusbar.RotationToggle android:id="@id/rotation_lock_button" android:clickable="true" android:layout_width="32.0dip" android:layout_height="32.0dip" android:layout_margin="8.0dip" android:button="@drawable/ic_notify_rotation" android:contentDescription="@string/accessibility_rotation_lock_off" />
</LinearLayout>
<Space android:layout_width="0.0dip" android:layout_height="0.0dip" android:layout_weight="1.0" />
<ViewFlipper android:id="@id/header_flipper" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="2.0dip" android:layout_alignParentRight="true"
xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout android:layout_width="wrap_content" android:layout_height="fill_parent">
<ImageView android:id="@id/flip_to_quickpanel_button" android:layout_width="50.0dip" android:layout_height="50.0dip" android:src="@drawable/ic_notify_quicksettings" android:scaleType="center" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_desc_quick_settings" />
<ImageView android:id="@id/clear_all_button" android:layout_width="50.0dip" android:layout_height="50.0dip" android:src="@drawable/ic_notify_clear" android:scaleType="center" android:layout_toLeftOf="@id/flip_to_quickpanel_button" android:contentDescription="@string/accessibility_clear_all" />
</RelativeLayout>
<RelativeLayout android:layout_width="wrap_content" android:layout_height="fill_parent">
<ImageView android:id="@id/flip_to_notifications_button" android:layout_width="50.0dip" android:layout_height="50.0dip" android:src="@drawable/ic_notifications" android:scaleType="center" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_notifications_button" />
</RelativeLayout>
</ViewFlipper>
</RelativeLayout>
</LinearLayout>
SystemUI.apk\res\values\dimens.xml, ids.xml, strings.xml, styles.xml,. add the blue code
dimens.xml
Code:
<dimen name="carrier_label_height">24.0dip</dimen>
<dimen name="blinds_pop_threshold">32.0dip</dimen>
<dimen name="pull_span_min">25.0dip</dimen>
[COLOR="Blue"]<dimen name="quickpanel_button_height">107.0dip</dimen>
<dimen name="quickpanel_tabs_height">48.0dip</dimen>[/COLOR]
</resources>
ids.xml
Code:
<item type="id" name="notification_inspect_item">false</item>
<item type="id" name="recent_remove_item">false</item>
<item type="id" name="recent_inspect_item">false</item>
[COLOR="Blue"]<item type="id" name="datetime">false</item>
<item type="id" name="header_flipper">false</item>
<item type="id" name="carrier_label_2">false</item>
<item type="id" name="close_drag">false</item>
<item type="id" name="quickpanel_top_tabs">false</item>
<item type="id" name="quickpanel_bottom_tabs">false</item>
<item type="id" name="quickpanel_button">false</item>
<item type="id" name="quickpanel_button_image">false</item>
<item type="id" name="quickpanel_button_text">false</item>
<item type="id" name="quickpanel_button_indic">false</item>
<item type="id" name="flip_to_quickpanel_button">false</item>
<item type="id" name="flip_to_notifications_button">false</item>
<item type="id" name="contents_flipper">false</item>
<item type="id" name="user_button">false</item>
<item type="id" name="user_button_image">false</item>
<item type="id" name="user_button_text">false</item>
<item type="id" name="quickpanel_contents">false</item>
<item type="id" name="brightness_slider_text">false</item>
<item type="id" name="quickpanel_top_tabs_toggles">false</item>
<item type="id" name="quickpanel_top_tabs_sliders">false</item>
<item type="id" name="quickpanel_flipper">false</item>
<item type="id" name="quickpanel_slider_ringer_volume">false</item>
<item type="id" name="quickpanel_slider_notification_volume">false</item>
<item type="id" name="quickpanel_slider_voice_call_volume">false</item>
<item type="id" name="quickpanel_slider_media_volume">false</item>
<item type="id" name="quickpanel_slider_alarm_volume">false</item>
<item type="id" name="quickpanel_scrollview_toggles">false</item>
<item type="id" name="quickpanel_scrollview_sliders">false</item>
<item type="id" name="quickpanel">false</item>
<item type="id" name="quickpanel_bottom_tabs_toggles">false</item>
<item type="id" name="quickpanel_bottom_tabs_sliders">false</item>
<item type="id" name="divider_tile">false</item>[/COLOR]
</resources>
strings.xml
Code:
<string name="navbar_back_button">Back button</string>
<string name="navbar_empty_button">Empty button</string>
<string name="navbar_menu_conditional_button">Menu (autoHide) button</string>
<string name="navbar_menu_always_button">Menu (alwaysShow) button</string>
<string name="navbar_menu_big_button">Menu button</string>
[COLOR="Blue"]<string name="accessibility_desc_quick_settings">Quick settings.</string>
<string name="user_button_label">Me</string>
<string name="quickpanel_wifi_text">Wi-Fi</string>
<string name="quickpanel_dc_text">Data</string>
<string name="quickpanel_network_mode_text">Network Mode</string>
<string name="quickpanel_sound_text">Sound</string>
<string name="quickpanel_sound_vibration_text">Sound Vibration</string>
<string name="quickpanel_silent_text">Silent</string>
<string name="quickpanel_vibration_text">Vibration</string>
<string name="quickpanel_rotation_text">Auto Rotation</string>
<string name="quickpanel_bluetooth_text">Bluetooth</string>
<string name="quickpanel_gps_text">GPS</string>
<string name="quickpanel_autosync_text">Auto Sync</string>
<string name="quickpanel_brightness_text">Brightness</string>
<string name="quickpanel_screen_timeout_text">Screen Timeout</string>
<string name="quickpanel_lockscreen_text">Lockscreen</string>
<string name="quickpanel_airplane_text">Airplane Mode</string>
<string name="quickpanel_flashlight_text">Flashlight</string>
<string name="quickpanel_reboot_text">Reboot</string>
<string name="quickpanel_shutdown_text">Shutdown</string>
<string name="airplane_mode">In Flight mode</string>
<string name="shutdown_confirm">Your phone will shut down.</string>
<string name="screen_timeout_seconds">Screen timeout set to: %d second(s)</string>
<string name="screen_timeout_minutes">Screen timeout set to: %d minute(s)</string>
<string name="screen_timeout_hours">Screen timeout set to: %d hour(s)</string>
<string name="hamster">Phone Options</string>
<string name="yes">OK</string>
<string name="no">Cancel</string>
<string name="reboot">Reboot</string>
<string name="reboot_recovery">Recovery</string>
<string name="reboot_download">Download</string>
<string name="quickpanel_usb_debugging_text">USB Debugging</string>
<string name="quickpanel_usb_connection_mode_text">USB Conn. Mode</string>
<string name="quickpanel_usb_current_mtp_title">Current mode: MPT</string>
<string name="quickpanel_usb_current_msc_title">Current mode: MSC</string>
<string name="usb_mpt_mode">MPT - Media Transfer</string>
<string name="usb_msc_mode">MSC - Mass Storage</string>
<string name="quickpanel_wifi_ap_text">Wi-Fi Hotspot</string>
<string name="quickpanel_stay_awake_plugged_text">Stay Awake</string>
<string name="quickpanel_battery_info_text">Battery Info</string>
<string name="battery_info_info">Battery Information</string>
<string name="battery_info_usage">Battery Power Usage</string>
<string name="quickpanel_tab_toggles_text">Toggle Buttons</string>
<string name="quickpanel_tab_sliders_text">Slider Controls</string>
<string name="quickpanel_slider_ringer_volume_text">Ringtone & notifications</string>
<string name="quickpanel_slider_notification_volume_text">Notifications</string>
<string name="quickpanel_slider_voice_call_volume_text">Voice calls</string>
<string name="quickpanel_slider_media_volume_text">Music, video, games, & other media</string>
<string name="quickpanel_slider_alarm_volume_text">Alarms</string>
<string name="quickpanel_lock_now_text">Lock Now</string>[/COLOR]
</resources>
styles.xml
Code:
<style name="StatusBarPanelSettingsContents">
<item name="android:textSize">18.0sp</item>
<item name="android:textColor">?android:textColorPrimary</item>
<item name="android:layout_gravity">left|center</item>
<item name="android:layout_width">0.0dip</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_weight">1.0</item>
</style>
[COLOR="Blue"]<style name="TextAppearance" />
<style name="TextAppearance.QuickPanel" parent="@style/TextAppearance" />
<style name="TextAppearance.QuickPanel.TextStyle" parent="@style/TextAppearance.QuickPanel">
<item name="android:textSize">12.0dip</item>
<item name="android:textStyle">normal</item>
<item name="android:textColor">#ffcccccc</item>
<item name="android:ellipsize">marquee</item>
<item name="android:paddingLeft">6.0dip</item>
<item name="android:paddingRight">6.0dip</item>
<item name="android:fadingEdge">horizontal</item>
<item name="android:maxLines">2</item>
<item name="android:singleLine">false</item>
<item name="android:drawablePadding">12.0dip</item>
<item name="android:textAllCaps">true</item>
</style>[/COLOR]
</resources>
CONTINUE THE GUIDE IN POST #3
STEP - 3
Download attached JB_Smalis_and_Xml_4.2_SystemUI.apk exstract it and merge to your decompiled SystemUI.apk,. but before doing this, you must read :
NOTE !!!
1. IF YOUR DEVICE HAS arrays.xml, please do check again/adapt it with arrays.xml in the JB_Smalis_Xml_4.2_SystemUI.apk
2. GO TO JB_Smalis_Xml_4.2_SystemUI.apk/smali\com\android\systemui\statusbar\phone
there are PhoneStatusBar$31.smali,and so on,. pay attention on the red number, it is a continue/next digit number after PhoneStatusBar$30.smali in CM10 smalis, so if your device/JB rom has different than 30 you must rename all smalis number to be the next digit/number after your last PhoneStatusBar$number.smali
CONTINUE THE GUIDE IN POST #4
NOTE FOR CM10 !!
go to SystemUI.apk\smali\com\android\systemui\statusbar
remove powerwidget folder
rename all lines in SystemUI.apk\smali\com\android\systemui\statusbar\phone\PhoneStatusBar.smali
from all
Code:
mPowerWidget:Lcom/android/systemui/statusbar/powerwidget/PowerWidget;
to
Code:
mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
and
from all
Code:
Lcom/android/systemui/statusbar/powerwidget/PowerWidget;
to
Code:
Lcom/lidroid/systemui/quickpanel/PowerWidget;
Click to expand...
Click to collapse
NEXT STEP
SystemUI.apk\smali\com\android\systemui\statusbar\phone\PhoneStatusBar.smali
add the blue code
Code:
# instance fields
.field mAbsPos:[I
.field mAnimAccel:F
.field mAnimLastTimeNanos:J
.field mAnimVel:F
.field mAnimY:F
.field mAnimating:Z
.field mAnimatingReveal:Z
.field final mAnimationCallback:Ljava/lang/Runnable;
[COLOR="Blue"].field private mAudioManager:Landroid/media/AudioManager;[/COLOR]
.field mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
[COLOR="Blue"].field mBrightness:Lcom/android/systemui/statusbar/policy/BrightnessController;[/COLOR]
.field private mBrightnessControl:Z
.field private mBroadcastReceiver:Landroid/content/BroadcastReceiver;
.field mButtonsBar:Landroid/view/View;
.field private mCarrierLabel:Landroid/widget/TextView;
.field private mCarrierLabelHeight:I
.field private mCarrierLabelVisible:Z
.field mChoreographer:Landroid/view/Choreographer;
.field mClearButton:Landroid/view/View;
.field private mClearButtonListener:Landroid/view/View$OnClickListener;
.field mClockView:Lcom/android/systemui/statusbar/policy/Clock;
.field mCloseView:Lcom/android/systemui/statusbar/phone/CloseDragHandle;
.field private mCloseViewHeight:I
.field mClosing:Z
.field private mCollapseAccelPx:F
.field private mCollapseMinDisplayFraction:F
[COLOR="Blue"].field mContentsFlipper:Landroid/widget/ViewFlipper;[/COLOR]
.field mCurrentTheme:Landroid/content/res/CustomTheme;
.field mDateView:Lcom/android/systemui/statusbar/policy/DateView;
.field mDisabled:I
.field mDisplay:Landroid/view/Display;
.field mDisplayMetrics:Landroid/util/DisplayMetrics;
.field mEdgeBorder:I
.field private mEmergencyCallLabel:Landroid/widget/TextView;
.field private mExpandAccelPx:F
.field private mExpandMinDisplayFraction:F
.field mExpanded:Z
.field mExpandedContents:Landroid/view/View;
.field mExpandedVisible:Z
.field private mFlingCollapseMinVelocityPx:F
.field private mFlingExpandMinVelocityPx:F
.field private mFlingGestureMaxOutputVelocityPx:F
.field private mFlingGestureMaxXVelocityPx:F
.field mFlingVelocity:F
.field mFlingY:I
[COLOR="Blue"].field mFlipToNotificationsButton:Landroid/view/View;
.field private mFlipToNotificationsButtonListener:Landroid/view/View$OnClickListener;
.field mFlipToQuickPanelButton:Landroid/view/View;
.field private mFlipToQuickPanelButtonListener:Landroid/view/View$OnClickListener;[/COLOR]
.field mFocusChangeListener:Landroid/view/View$OnFocusChangeListener;
[COLOR="Blue"].field mHeaderFlipper:Landroid/widget/ViewFlipper;[/COLOR]
.field mHomeSearchActionListener:Landroid/view/View$OnTouchListener;
.field mIconHPadding:I
.field mIconPolicy:Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;
.field mIconSize:I
.field mIcons:Landroid/widget/LinearLayout;
.field mInitialTouchX:I
.field mInitialTouchY:I
.field private mLightsOnAnimation:Landroid/animation/AnimatorSet;
.field private mLightsOutAnimation:Landroid/animation/AnimatorSet;
.field mLinger:I
.field mLocationController:Lcom/android/systemui/statusbar/policy/LocationController;
.field mLongPressBrightnessChange:Ljava/lang/Runnable;
.field private final mMakeIconsInvisible:Landroid/animation/Animator$AnimatorListener;
[COLOR="Blue"].field mMeProfileContentObserver:Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MeProfileContentObserver;[/COLOR]
.field private mMinBrightness:I
.field mMoreIcon:Landroid/view/View;
.field mNaturalBarHeight:I
.field private mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
.field private mNavigationIconHints:I
.field mNetworkController:Lcom/android/systemui/statusbar/policy/NetworkController;
.field mNotificationIcons:Lcom/android/systemui/statusbar/phone/IconMerger;
.field mNotificationPanel:Landroid/view/View;
.field final mNotificationPanelBackgroundPadding:Landroid/graphics/Rect;
.field mNotificationPanelGravity:I
.field mNotificationPanelIsFullScreenWidth:Z
.field mNotificationPanelMarginBottomPx:I
.field mNotificationPanelMarginLeftPx:I
.field mNotificationPanelMinHeight:I
.field private final mPerformFling:Ljava/lang/Runnable;
.field private final mPerformSelfExpandFling:Ljava/lang/Runnable;
.field mPixelFormat:I
.field mPositionTmp:[I
.field mPostCollapseCleanup:Ljava/lang/Runnable;
[COLOR="Blue"].field mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;[/COLOR]
.field mQueueLock:Ljava/lang/Object;
[COLOR="Blue"].field mQuickPanelBottomTabsSliders:Landroid/view/View;
.field private mQuickPanelBottomTabsSlidersListener:Landroid/view/View$OnClickListener;
.field mQuickPanelBottomTabsToggles:Landroid/view/View;
.field private mQuickPanelBottomTabsTogglesListener:Landroid/view/View$OnClickListener;
.field mQuickPanelContents:Landroid/view/View;
.field mQuickPanelFlipper:Landroid/widget/ViewFlipper;
.field mQuickPanelTopTabsSliders:Landroid/view/View;
.field private mQuickPanelTopTabsSlidersListener:Landroid/view/View$OnClickListener;
.field mQuickPanelTopTabsToggles:Landroid/view/View;
.field private mQuickPanelTopTabsTogglesListener:Landroid/view/View$OnClickListener;
.field mRecentsButton:Landroid/view/View;[/COLOR]
.field private mRecentsClickListener:Landroid/view/View$OnClickListener;
.field private mRecreating:Z
.field final mRevealAnimationCallback:Ljava/lang/Runnable;
.field mRotationButton:Lcom/android/systemui/statusbar/RotationToggle;
.field private mScreenWidth:F
.field mScrollView:Landroid/widget/ScrollView;
.field private mSelfCollapseVelocityPx:F
.field private mSelfExpandVelocityPx:F
.field mSettingsButton:Landroid/view/View;
.field private mSettingsButtonListener:Landroid/view/View$OnClickListener;
.field private mShowClock:Z
.field private mShowSearchHoldoff:I
.field private mShowSearchPanel:Ljava/lang/Runnable;
.field private final mStartRevealAnimation:Ljava/lang/Runnable;
.field mStartTracing:Ljava/lang/Runnable;
.field mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
.field mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.field mStatusIcons:Landroid/widget/LinearLayout;
.field mStopTracing:Ljava/lang/Runnable;
.field mSystemUiVisibility:I
.field private mTicker:Lcom/android/systemui/statusbar/phone/Ticker;
.field private mTickerView:Landroid/view/View;
.field private mTicking:Z
.field mTickingDoneListener:Landroid/view/animation/Animation$AnimationListener;
.field mTracking:Z
.field mTrackingPosition:I
.field mVelocityTracker:Landroid/view/VelocityTracker;
.field mViewDelta:I
.field mWindowManager:Landroid/view/IWindowManager;
Code:
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$30;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$30;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStopTracing:Ljava/lang/Runnable;
[COLOR="Blue"]new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]31[/COLOR];
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]31[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButtonListener:Landroid/view/View$OnClickListener;
.line 1901
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]32[/COLOR];
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]32[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButtonListener:Landroid/view/View$OnClickListener;
.line 1902
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]33[/COLOR];
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]33[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsTogglesListener:Landroid/view/View$OnClickListener;
.line 1903
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]34[/COLOR];
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]34[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSlidersListener:Landroid/view/View$OnClickListener;
.line 1904
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MeProfileContentObserver;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MeProfileContentObserver;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mMeProfileContentObserver:Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MeProfileContentObserver;
.line 1905
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]40[/COLOR];
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]40[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsTogglesListener:Landroid/view/View$OnClickListener;
.line 1906
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]41[/COLOR];
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]41[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSlidersListener:Landroid/view/View$OnClickListener;[/COLOR]
.line 2847
return-void
.end method
and after .end method
Code:
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$41;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$41;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSlidersListener:Landroid/view/View$OnClickListener;
.line 2847
return-void
.end method
[COLOR="Blue"].method static synthetic access$1100(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/media/AudioManager;
.locals 1
.parameter
.prologue
.line 23
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
return-object v0
.end method
.method static synthetic access$1200(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Z
.locals 1
.parameter "x0"
.prologue
.line 97
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
return v0
.end method
.method static synthetic access$900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/content/Context;
.locals 1
.parameter "x0"
.prologue
.line 97
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
return-object v0
.end method[/COLOR]
next find this method
Code:
.method private getCloseViewHeight()I
and add the blue code above it
Code:
[COLOR="Blue"].method private fastFlipToNotifications()V
.locals 2
.prologue
.line 2257
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedContents:Landroid/view/View;
.line 2259
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContentsFlipper:Landroid/widget/ViewFlipper;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setDisplayedChild(I)V
.line 2261
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHeaderFlipper:Landroid/widget/ViewFlipper;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setDisplayedChild(I)V
.line 2263
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->showCarrierLabel()V
.line 2269
return-void
.end method
.method private fastFlipToQuickPanelToggles()V
.locals 2
.prologue
.line 2255
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c00c6
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
.line 2257
.local v0, svToggles:Landroid/widget/ScrollView;
const/16 v1, 0x21
invoke-virtual {v0, v1}, Landroid/widget/ScrollView;->fullScroll(I)Z
.line 2259
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelFlipper:Landroid/widget/ViewFlipper;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setDisplayedChild(I)V
.line 2269
return-void
.end method[/COLOR]
.method private getCloseViewHeight()I
.locals 1
.prologue
.line 767
iget v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCloseViewHeight:I
return v0
.end method
next find this method
Code:
.method private loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
add the blue code above it
Code:
[COLOR="Blue"].method private hideCarrierLabel()V
.locals 2
.prologue
.line 125
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c003f
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
.line 126
.local v0, carrierLabel:Landroid/view/View;
const/16 v1, 0x8
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
.line 129
return-void
.end method
.method private static inFromLeftAnimation()Landroid/view/animation/Animation;
.locals 9
.prologue
const/4 v4, 0x0
const/4 v1, 0x2
.line 84
new-instance v0, Landroid/view/animation/TranslateAnimation;
.line 85
const/high16 v2, -0x4080
move v3, v1
move v5, v1
move v6, v4
move v7, v1
move v8, v4
.line 84
invoke-direct/range {v0 .. v8}, Landroid/view/animation/TranslateAnimation;-><init>(IFIFIFIF)V
.line 89
.local v0, inFromLeft:Landroid/view/animation/Animation;
const-wide/16 v1, 0x64
invoke-virtual {v0, v1, v2}, Landroid/view/animation/Animation;->setDuration(J)V
.line 90
new-instance v1, Landroid/view/animation/AccelerateInterpolator;
invoke-direct {v1}, Landroid/view/animation/AccelerateInterpolator;-><init>()V
invoke-virtual {v0, v1}, Landroid/view/animation/Animation;->setInterpolator(Landroid/view/animation/Interpolator;)V
.line 91
return-object v0
.end method
.method private static inFromRightAnimation()Landroid/view/animation/Animation;
.locals 9
.prologue
const/4 v4, 0x0
const/4 v1, 0x2
.line 58
new-instance v0, Landroid/view/animation/TranslateAnimation;
.line 59
const/high16 v2, 0x3f80
move v3, v1
move v5, v1
move v6, v4
move v7, v1
move v8, v4
.line 58
invoke-direct/range {v0 .. v8}, Landroid/view/animation/TranslateAnimation;-><init>(IFIFIFIF)V
.line 63
.local v0, inFromRight:Landroid/view/animation/Animation;
const-wide/16 v1, 0x64
invoke-virtual {v0, v1, v2}, Landroid/view/animation/Animation;->setDuration(J)V
.line 64
new-instance v1, Landroid/view/animation/AccelerateInterpolator;
invoke-direct {v1}, Landroid/view/animation/AccelerateInterpolator;-><init>()V
invoke-virtual {v0, v1}, Landroid/view/animation/Animation;->setInterpolator(Landroid/view/animation/Interpolator;)V
.line 65
return-object v0
.end method[/COLOR]
.method private loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
.locals 2
.parameter "id"
.parameter "listener"
next find this method
Code:
.method private prepareNavigationBarView()V
add the blue code above it
Code:
[COLOR="Blue"].method private static outToLeftAnimation()Landroid/view/animation/Animation;
.locals 9
.prologue
const/4 v2, 0x0
const/4 v1, 0x2
.line 71
new-instance v0, Landroid/view/animation/TranslateAnimation;
.line 73
const/high16 v4, -0x4080
move v3, v1
move v5, v1
move v6, v2
move v7, v1
move v8, v2
.line 71
invoke-direct/range {v0 .. v8}, Landroid/view/animation/TranslateAnimation;-><init>(IFIFIFIF)V
.line 76
.local v0, outtoLeft:Landroid/view/animation/Animation;
const-wide/16 v1, 0x64
invoke-virtual {v0, v1, v2}, Landroid/view/animation/Animation;->setDuration(J)V
.line 77
new-instance v1, Landroid/view/animation/AccelerateInterpolator;
invoke-direct {v1}, Landroid/view/animation/AccelerateInterpolator;-><init>()V
invoke-virtual {v0, v1}, Landroid/view/animation/Animation;->setInterpolator(Landroid/view/animation/Interpolator;)V
.line 78
return-object v0
.end method
.method private static outToRightAnimation()Landroid/view/animation/Animation;
.locals 9
.prologue
const/4 v2, 0x0
const/4 v1, 0x2
.line 97
new-instance v0, Landroid/view/animation/TranslateAnimation;
.line 99
const/high16 v4, 0x3f80
move v3, v1
move v5, v1
move v6, v2
move v7, v1
move v8, v2
.line 97
invoke-direct/range {v0 .. v8}, Landroid/view/animation/TranslateAnimation;-><init>(IFIFIFIF)V
.line 102
.local v0, outtoRight:Landroid/view/animation/Animation;
const-wide/16 v1, 0x64
invoke-virtual {v0, v1, v2}, Landroid/view/animation/Animation;->setDuration(J)V
.line 103
new-instance v1, Landroid/view/animation/AccelerateInterpolator;
invoke-direct {v1}, Landroid/view/animation/AccelerateInterpolator;-><init>()V
invoke-virtual {v0, v1}, Landroid/view/animation/Animation;->setInterpolator(Landroid/view/animation/Interpolator;)V
.line 104
return-object v0
.end method[/COLOR]
.method private prepareNavigationBarView()V
.locals 4
.prologue
.line 803
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
invoke-virtual {v0}, Lcom/android/systemui/statusbar/phone/NavigationBarView;->reorient()V
next find this method
Code:
.method private setIntruderAlertVisibility(Z)V
add the code above it
Code:
[COLOR="Blue"].method private selectQuickPanelInitialTab()V
.locals 2
.prologue
.line 69
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsToggles:Landroid/view/View;
const/4 v1, 0x1
invoke-virtual {v0, v1}, Landroid/view/View;->setSelected(Z)V
.line 70
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsToggles:Landroid/view/View;
const/4 v1, 0x1
invoke-virtual {v0, v1}, Landroid/view/View;->setSelected(Z)V
.line 72
return-void
.end method[/COLOR]
.method private setIntruderAlertVisibility(Z)V
.locals 0
.parameter "vis"
.prologue
.line 2569
return-void
.end method
next find this method
Code:
.method private setStatusBarLowProfile(Z)V
add the blue code above it
PAY ATTENTION TO THE RED PhoneStatusBar$XX
Code:
[COLOR="Blue"].method private setQuickPanelUserButtonInfo()V
.locals 4
.prologue
.line 52
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v3, 0x7f0c00bb
invoke-virtual {v2, v3}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v2
check-cast v2, Landroid/widget/TextView;
.line 55
.local v2, userButtonText:Landroid/widget/TextView;
:try_start_0
invoke-direct {p0, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setUserButtonText(Landroid/widget/TextView;)V
:try_end_0
.catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_0
.line 63
:goto_0
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v3, 0x7f0c00ba
invoke-virtual {v1, v3}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v1
check-cast v1, Landroid/widget/ImageView;
.line 66
.local v1, userButtonImage:Landroid/widget/ImageView;
:try_start_1
invoke-direct {p0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setUserButtonImage(Landroid/widget/ImageView;)V
:try_end_1
.catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_1
.line 74
:goto_1
return-void
.line 57
.end local v1 #userButtonImage:Landroid/widget/ImageView;
:catch_0
move-exception v0
.line 59
.local v0, e:Ljava/io/IOException;
invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
goto :goto_0
.line 68
.end local v0 #e:Ljava/io/IOException;
.restart local v1 #userButtonImage:Landroid/widget/ImageView;
:catch_1
move-exception v0
.line 70
.restart local v0 #e:Ljava/io/IOException;
invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
goto :goto_1
.end method
.method private setQuickPanelVolumeSliders()V
.locals 12
.prologue
const/4 v11, 0x3
const/4 v10, 0x2
const/4 v9, 0x0
const/4 v7, 0x1
.line 54
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
const-string v6, "audio"
invoke-virtual {v5, v6}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v5
check-cast v5, Landroid/media/AudioManager;
iput-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
.line 57
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v8, 0x7f0c00c1
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v3
check-cast v3, Landroid/widget/SeekBar;
.line 58
.local v3, ringSlider:Landroid/widget/SeekBar;
invoke-virtual {v3, v7}, Landroid/widget/SeekBar;->setKeyProgressIncrement(I)V
.line 59
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v5, v10}, Landroid/media/AudioManager;->getStreamMaxVolume(I)I
move-result v5
invoke-virtual {v3, v5}, Landroid/widget/SeekBar;->setMax(I)V
.line 60
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v5, v10}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v3, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 61
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]35[/COLOR];
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]35[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v3, v5}, Landroid/widget/SeekBar;->setOnSeekBarChangeListener(Landroid/widget/SeekBar$OnSeekBarChangeListener;)V
.line 80
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v8, 0x7f0c00c2
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v2
check-cast v2, Landroid/widget/SeekBar;
.line 81
.local v2, notificationSlider:Landroid/widget/SeekBar;
invoke-virtual {v2, v7}, Landroid/widget/SeekBar;->setKeyProgressIncrement(I)V
.line 82
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x5
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamMaxVolume(I)I
move-result v5
invoke-virtual {v2, v5}, Landroid/widget/SeekBar;->setMax(I)V
.line 83
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x5
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v2, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 84
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]36[/COLOR];
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]36[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v2, v5}, Landroid/widget/SeekBar;->setOnSeekBarChangeListener(Landroid/widget/SeekBar$OnSeekBarChangeListener;)V
.line 103
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v8, 0x7f0c00c3
invoke-virtual {v5, v8}, Landroid/view/View;->findViewById(I)Landroid/view/View;
move-result-object v4
check-cast v4, Landroid/widget/SeekBar;
.line 104
.local v4, voiceCallSlider:Landroid/widget/SeekBar;
invoke-virtual {v4, v7}, Landroid/widget/SeekBar;->setKeyProgressIncrement(I)V
.line 105
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v5, v9}, Landroid/media/AudioManager;->getStreamMaxVolume(I)I
move-result v5
invoke-virtual {v4, v5}, Landroid/widget/SeekBar;->setMax(I)V
.line 106
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v5, v9}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v4, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 107
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]37[/COLOR];
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]37[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v4, v5}, Landroid/widget/SeekBar;->setOnSeekBarChangeListener(Landroid/widget/SeekBar$OnSeekBarChangeListener;)V
.line 126
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v8, 0x7f0c00c4
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v1
check-cast v1, Landroid/widget/SeekBar;
.line 127
.local v1, mediaSlider:Landroid/widget/SeekBar;
invoke-virtual {v1, v7}, Landroid/widget/SeekBar;->setKeyProgressIncrement(I)V
.line 128
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v5, v11}, Landroid/media/AudioManager;->getStreamMaxVolume(I)I
move-result v5
invoke-virtual {v1, v5}, Landroid/widget/SeekBar;->setMax(I)V
.line 129
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v5, v11}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v1, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 130
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]38[/COLOR];
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]38[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v1, v5}, Landroid/widget/SeekBar;->setOnSeekBarChangeListener(Landroid/widget/SeekBar$OnSeekBarChangeListener;)V
.line 149
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v8, 0x7f0c00c5
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/SeekBar;
.line 150
.local v0, alarmSlider:Landroid/widget/SeekBar;
invoke-virtual {v0, v7}, Landroid/widget/SeekBar;->setKeyProgressIncrement(I)V
.line 151
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x4
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamMaxVolume(I)I
move-result v5
invoke-virtual {v0, v5}, Landroid/widget/SeekBar;->setMax(I)V
.line 152
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x4
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v0, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 153
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]39[/COLOR];
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$[COLOR="Red"]39[/COLOR];-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v0, v5}, Landroid/widget/SeekBar;->setOnSeekBarChangeListener(Landroid/widget/SeekBar$OnSeekBarChangeListener;)V
.line 170
return-void
.end method[/COLOR]
.method private setStatusBarLowProfile(Z)V
.locals 14
.parameter
.prologue
.line 1984
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mLightsOutAnimation:Landroid/animation/AnimatorSet;
next find this method
Code:
.method private trackMovement(Landroid/view/MotionEvent;)V
add the blue code above it
Code:
[COLOR="Blue"].method private setUserButtonImage(Landroid/widget/ImageView;)V
.locals 12
.parameter "userButtonImage"
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
.prologue
.line 118
const/4 v11, 0x0
.line 122
.local v11, userImage:Landroid/graphics/Bitmap;
:try_start_0
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
sget-object v1, Landroid/provider/ContactsContract$Profile;->CONTENT_URI:Landroid/net/Uri;
const/4 v2, 0x1
new-array v2, v2, [Ljava/lang/String;
const/4 v3, 0x0
const-string v4, "_id"
aput-object v4, v2, v3
const/4 v3, 0x0
const/4 v4, 0x0
const/4 v5, 0x0
invoke-virtual/range {v0 .. v5}, Landroid/content/ContentResolver;->query(Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;
:try_end_0
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0
move-result-object v7
.line 123
.local v7, cursor:Landroid/database/Cursor;
if-eqz v7, :cond_1
.line 127
:try_start_1
invoke-interface {v7}, Landroid/database/Cursor;->moveToFirst()Z
move-result v0
if-eqz v0, :cond_0
.line 129
sget-object v0, Landroid/provider/ContactsContract$Contacts;->CONTENT_URI:Landroid/net/Uri;
const-string v1, "_id"
invoke-interface {v7, v1}, Landroid/database/Cursor;->getColumnIndex(Ljava/lang/String;)I
move-result v1
invoke-interface {v7, v1}, Landroid/database/Cursor;->getString(I)Ljava/lang/String;
move-result-object v1
invoke-static {v0, v1}, Landroid/net/Uri;->withAppendedPath(Landroid/net/Uri;Ljava/lang/String;)Landroid/net/Uri;
move-result-object v10
.line 130
.local v10, uriMe:Landroid/net/Uri;
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const/4 v1, 0x0
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mMeProfileContentObserver:Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MeProfileContentObserver;
invoke-virtual {v0, v10, v1, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 134
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
invoke-static {v0, v10}, Landroid/provider/ContactsContract$Contacts;->openContactPhotoInputStream(Landroid/content/ContentResolver;Landroid/net/Uri;)Ljava/io/InputStream;
move-result-object v9
.line 131
.local v9, stream:Ljava/io/InputStream;
new-instance v6, Ljava/io/BufferedInputStream;
invoke-direct {v6, v9}, Ljava/io/BufferedInputStream;-><init>(Ljava/io/InputStream;)V
.line 132
.local v6, buffer:Ljava/io/BufferedInputStream;
invoke-static {v6}, Landroid/graphics/BitmapFactory;->decodeStream(Ljava/io/InputStream;)Landroid/graphics/Bitmap;
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
move-result-object v11
.line 138
.end local v6 #buffer:Ljava/io/BufferedInputStream;
.end local v9 #stream:Ljava/io/InputStream;
.end local v10 #uriMe:Landroid/net/Uri;
:cond_0
:try_start_2
invoke-interface {v7}, Landroid/database/Cursor;->close()V
:try_end_2
.catch Ljava/lang/Exception; {:try_start_2 .. :try_end_2} :catch_0
.line 149
:cond_1
if-eqz v11, :cond_2
.line 151
invoke-virtual {p1, v11}, Landroid/widget/ImageView;->setImageBitmap(Landroid/graphics/Bitmap;)V
.line 158
:goto_0
return-void
.line 136
:catchall_0
move-exception v0
.line 138
:try_start_3
invoke-interface {v7}, Landroid/database/Cursor;->close()V
.line 140
throw v0
:try_end_3
.catch Ljava/lang/Exception; {:try_start_3 .. :try_end_3} :catch_0
.line 143
.end local v7 #cursor:Landroid/database/Cursor;
:catch_0
move-exception v8
.line 145
.local v8, e:Ljava/lang/Exception;
new-instance v0, Ljava/io/IOException;
invoke-virtual {v8}, Ljava/lang/Exception;->toString()Ljava/lang/String;
move-result-object v1
invoke-direct {v0, v1}, Ljava/io/IOException;-><init>(Ljava/lang/String;)V
throw v0
.line 155
.end local v8 #e:Ljava/lang/Exception;
.restart local v7 #cursor:Landroid/database/Cursor;
:cond_2
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v0
const v1, 0x7f02013a
invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;
move-result-object v0
invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setImageDrawable(Landroid/graphics/drawable/Drawable;)V
goto :goto_0
.end method
.method private setUserButtonText(Landroid/widget/TextView;)V
.locals 9
.parameter "userButtonText"
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
.prologue
.line 78
const/4 v8, 0x0
.line 82
.local v8, userName:Ljava/lang/String;
:try_start_0
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
sget-object v1, Landroid/provider/ContactsContract$Profile;->CONTENT_URI:Landroid/net/Uri;
const/4 v2, 0x2
new-array v2, v2, [Ljava/lang/String;
const/4 v3, 0x0
const-string v4, "_id"
aput-object v4, v2, v3
const/4 v3, 0x1
const-string v4, "display_name"
aput-object v4, v2, v3
const/4 v3, 0x0
const/4 v4, 0x0
const/4 v5, 0x0
invoke-virtual/range {v0 .. v5}, Landroid/content/ContentResolver;->query(Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;
:try_end_0
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0
move-result-object v6
.line 83
.local v6, cursor:Landroid/database/Cursor;
if-eqz v6, :cond_1
.line 87
:try_start_1
invoke-interface {v6}, Landroid/database/Cursor;->moveToFirst()Z
move-result v0
if-eqz v0, :cond_0
.line 89
const-string v0, "display_name"
invoke-interface {v6, v0}, Landroid/database/Cursor;->getColumnIndex(Ljava/lang/String;)I
move-result v0
invoke-interface {v6, v0}, Landroid/database/Cursor;->getString(I)Ljava/lang/String;
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
move-result-object v8
.line 95
:cond_0
:try_start_2
invoke-interface {v6}, Landroid/database/Cursor;->close()V
:try_end_2
.catch Ljava/lang/Exception; {:try_start_2 .. :try_end_2} :catch_0
.line 106
:cond_1
if-nez v8, :cond_2
.line 108
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v0
const v1, 0x7f090093
invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getString(I)Ljava/lang/String;
move-result-object v8
.line 112
:cond_2
invoke-virtual {p1, v8}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 114
return-void
.line 93
:catchall_0
move-exception v0
.line 95
:try_start_3
invoke-interface {v6}, Landroid/database/Cursor;->close()V
.line 97
throw v0
:try_end_3
.catch Ljava/lang/Exception; {:try_start_3 .. :try_end_3} :catch_0
.line 100
.end local v6 #cursor:Landroid/database/Cursor;
:catch_0
move-exception v7
.line 102
.local v7, e:Ljava/lang/Exception;
new-instance v0, Ljava/io/IOException;
invoke-virtual {v7}, Ljava/lang/Exception;->toString()Ljava/lang/String;
move-result-object v1
invoke-direct {v0, v1}, Ljava/io/IOException;-><init>(Ljava/lang/String;)V
throw v0
.end method
.method private showCarrierLabel()V
.locals 2
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c003f
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
return-void
.end method[/COLOR]
.method private trackMovement(Landroid/view/MotionEvent;)V
.locals 4
.parameter "event"
next find this method
Code:
.method public static viewInfo(Landroid/view/View;)Ljava/lang/String;
add the blue code above it
Code:
[COLOR="Blue"].method private updateUserButtonImage(Landroid/widget/ImageView;)V
.locals 11
.parameter "userButtonImage"
.prologue
const/4 v3, 0x0
.line 208
const/4 v10, 0x0
.line 210
.local v10, userImage:Landroid/graphics/Bitmap;
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
sget-object v1, Landroid/provider/ContactsContract$Profile;->CONTENT_URI:Landroid/net/Uri;
const/4 v2, 0x1
new-array v2, v2, [Ljava/lang/String;
const/4 v4, 0x0
const-string v5, "_id"
aput-object v5, v2, v4
move-object v4, v3
move-object v5, v3
invoke-virtual/range {v0 .. v5}, Landroid/content/ContentResolver;->query(Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;
move-result-object v7
.line 211
.local v7, cursor:Landroid/database/Cursor;
if-eqz v7, :cond_1
.line 215
:try_start_0
invoke-interface {v7}, Landroid/database/Cursor;->moveToFirst()Z
move-result v0
if-eqz v0, :cond_0
.line 217
sget-object v0, Landroid/provider/ContactsContract$Contacts;->CONTENT_URI:Landroid/net/Uri;
const-string v1, "_id"
invoke-interface {v7, v1}, Landroid/database/Cursor;->getColumnIndex(Ljava/lang/String;)I
move-result v1
invoke-interface {v7, v1}, Landroid/database/Cursor;->getString(I)Ljava/lang/String;
move-result-object v1
invoke-static {v0, v1}, Landroid/net/Uri;->withAppendedPath(Landroid/net/Uri;Ljava/lang/String;)Landroid/net/Uri;
move-result-object v9
.line 218
.local v9, uriMe:Landroid/net/Uri;
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
invoke-static {v0, v9}, Landroid/provider/ContactsContract$Contacts;->openContactPhotoInputStream(Landroid/content/ContentResolver;Landroid/net/Uri;)Ljava/io/InputStream;
move-result-object v8
.line 219
.local v8, stream:Ljava/io/InputStream;
new-instance v6, Ljava/io/BufferedInputStream;
invoke-direct {v6, v8}, Ljava/io/BufferedInputStream;-><init>(Ljava/io/InputStream;)V
.line 220
.local v6, buffer:Ljava/io/BufferedInputStream;
invoke-static {v6}, Landroid/graphics/BitmapFactory;->decodeStream(Ljava/io/InputStream;)Landroid/graphics/Bitmap;
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
move-result-object v10
.line 226
.end local v6 #buffer:Ljava/io/BufferedInputStream;
.end local v8 #stream:Ljava/io/InputStream;
.end local v9 #uriMe:Landroid/net/Uri;
:cond_0
invoke-interface {v7}, Landroid/database/Cursor;->close()V
.line 231
:cond_1
if-eqz v10, :cond_2
.line 233
invoke-virtual {p1, v10}, Landroid/widget/ImageView;->setImageBitmap(Landroid/graphics/Bitmap;)V
.line 240
:goto_0
return-void
.line 224
:catchall_0
move-exception v0
.line 226
invoke-interface {v7}, Landroid/database/Cursor;->close()V
.line 228
throw v0
.line 237
:cond_2
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v0
const v1, 0x7f02013a
invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;
move-result-object v0
invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setImageDrawable(Landroid/graphics/drawable/Drawable;)V
goto :goto_0
.end method
.method private updateUserButtonText(Landroid/widget/TextView;)V
.locals 8
.parameter "userButtonText"
.prologue
const/4 v3, 0x0
.line 176
const/4 v7, 0x0
.line 178
.local v7, userName:Ljava/lang/String;
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
sget-object v1, Landroid/provider/ContactsContract$Profile;->CONTENT_URI:Landroid/net/Uri;
const/4 v2, 0x2
new-array v2, v2, [Ljava/lang/String;
const/4 v4, 0x0
const-string v5, "_id"
aput-object v5, v2, v4
const/4 v4, 0x1
const-string v5, "display_name"
aput-object v5, v2, v4
move-object v4, v3
move-object v5, v3
invoke-virtual/range {v0 .. v5}, Landroid/content/ContentResolver;->query(Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;
move-result-object v6
.line 179
.local v6, cursor:Landroid/database/Cursor;
if-eqz v6, :cond_1
.line 183
:try_start_0
invoke-interface {v6}, Landroid/database/Cursor;->moveToFirst()Z
move-result v0
if-eqz v0, :cond_0
.line 185
const-string v0, "display_name"
invoke-interface {v6, v0}, Landroid/database/Cursor;->getColumnIndex(Ljava/lang/String;)I
move-result v0
invoke-interface {v6, v0}, Landroid/database/Cursor;->getString(I)Ljava/lang/String;
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
move-result-object v7
.line 191
:cond_0
invoke-interface {v6}, Landroid/database/Cursor;->close()V
.line 196
:cond_1
if-nez v7, :cond_2
.line 198
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v0
const v1, 0x7f090093
invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getString(I)Ljava/lang/String;
move-result-object v7
.line 202
:cond_2
invoke-virtual {p1, v7}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
.line 204
return-void
.line 189
:catchall_0
move-exception v0
.line 191
invoke-interface {v6}, Landroid/database/Cursor;->close()V
.line 193
throw v0
.end method[/COLOR]
.method public static viewInfo(Landroid/view/View;)Ljava/lang/String;
.locals 2
.parameter
.prologue
next find this method
Code:
# virtual methods
.method public addIcon(Ljava/lang/String;IILcom/android/internal/statusbar/StatusBarIcon;)V
and add the blue code above its return-void
and for CM10, you have already the line, but you must change it to like bellow too
Code:
invoke-virtual {v1, v0, p3, v2}, Landroid/widget/LinearLayout;->addView(Landroid/view/View;ILandroid/view/ViewGroup$LayoutParams;)V
.line 883
[COLOR="Blue"]iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
invoke-virtual {v1}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->updateWidget()V[/COLOR]
.line 884
[B]return-void[/B]
.end method
next find this method
Code:
.method public disable(I)V
add the blue code above it
Code:
[COLOR="Blue"].method public deselectAllQuickPanelTabs()V
.locals 2
.prologue
const/4 v1, 0x0
.line 55
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsToggles:Landroid/view/View;
invoke-virtual {v0, v1}, Landroid/view/View;->setSelected(Z)V
.line 58
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSliders:Landroid/view/View;
invoke-virtual {v0, v1}, Landroid/view/View;->setSelected(Z)V
.line 61
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsToggles:Landroid/view/View;
invoke-virtual {v0, v1}, Landroid/view/View;->setSelected(Z)V
.line 65
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSliders:Landroid/view/View;
invoke-virtual {v0, v1}, Landroid/view/View;->setSelected(Z)V
.line 68
return-void
.end method[/COLOR]
.method public disable(I)V
.locals 8
.parameter
.prologue
next find this method
Code:
.method protected getExpandedViewMaxHeight()I
add the blue code above it
Code:
[COLOR="Blue"].method flipToNotifications()V
.locals 3
.prologue
.line 2257
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedContents:Landroid/view/View;
.line 2259
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContentsFlipper:Landroid/widget/ViewFlipper;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
const v2, 0x7f040012
invoke-virtual {v0, v1, v2}, Landroid/widget/ViewFlipper;->setInAnimation(Landroid/content/Context;I)V
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
const v2, 0x7f040013
invoke-virtual {v0, v1, v2}, Landroid/widget/ViewFlipper;->setOutAnimation(Landroid/content/Context;I)V
invoke-virtual {v0}, Landroid/widget/ViewFlipper;->showPrevious()V
.line 2261
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHeaderFlipper:Landroid/widget/ViewFlipper;
invoke-virtual {v0}, Landroid/widget/ViewFlipper;->showPrevious()V
.line 2263
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->showCarrierLabel()V
.line 2269
return-void
.end method
.method flipToQuickPanel()V
.locals 3
.prologue
.line 2255
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->hideCarrierLabel()V
.line 2257
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelContents:Landroid/view/View;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedContents:Landroid/view/View;
.line 2259
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c00c6
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
.line 2261
.local v0, svToggles:Landroid/widget/ScrollView;
const/16 v1, 0x21
invoke-virtual {v0, v1}, Landroid/widget/ScrollView;->fullScroll(I)Z
.line 2263
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c00c7
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
.line 2265
.local v0, svSliders:Landroid/widget/ScrollView;
const/16 v1, 0x21
invoke-virtual {v0, v1}, Landroid/widget/ScrollView;->fullScroll(I)Z
.line 2267
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContentsFlipper:Landroid/widget/ViewFlipper;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
const v2, 0x7f040012
invoke-virtual {v0, v1, v2}, Landroid/widget/ViewFlipper;->setInAnimation(Landroid/content/Context;I)V
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
const v2, 0x7f040013
invoke-virtual {v0, v1, v2}, Landroid/widget/ViewFlipper;->setOutAnimation(Landroid/content/Context;I)V
invoke-virtual {v0}, Landroid/widget/ViewFlipper;->showNext()V
.line 2269
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHeaderFlipper:Landroid/widget/ViewFlipper;
invoke-virtual {v0}, Landroid/widget/ViewFlipper;->showNext()V
.line 2271
return-void
.end method
.method flipToQuickPanelSliders()V
.locals 2
.prologue
.line 2255
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c00c7
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
.line 2257
.local v0, svSliders:Landroid/widget/ScrollView;
const/16 v1, 0x21
invoke-virtual {v0, v1}, Landroid/widget/ScrollView;->fullScroll(I)Z
.line 2259
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelFlipper:Landroid/widget/ViewFlipper;
invoke-static {}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->inFromRightAnimation()Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setInAnimation(Landroid/view/animation/Animation;)V
invoke-static {}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->outToLeftAnimation()Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setOutAnimation(Landroid/view/animation/Animation;)V
invoke-virtual {v0}, Landroid/widget/ViewFlipper;->showNext()V
.line 2269
return-void
.end method
.method flipToQuickPanelToggles()V
.locals 2
.prologue
.line 2255
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, 0x7f0c00c6
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
.line 2257
.local v0, svToggles:Landroid/widget/ScrollView;
const/16 v1, 0x21
invoke-virtual {v0, v1}, Landroid/widget/ScrollView;->fullScroll(I)Z
.line 2259
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelFlipper:Landroid/widget/ViewFlipper;
invoke-static {}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->inFromLeftAnimation()Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setInAnimation(Landroid/view/animation/Animation;)V
invoke-static {}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->outToRightAnimation()Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/ViewFlipper;->setOutAnimation(Landroid/view/animation/Animation;)V
invoke-virtual {v0}, Landroid/widget/ViewFlipper;->showPrevious()V
.line 2269
return-void
.end method[/COLOR]
.method protected getExpandedViewMaxHeight()I
.locals 2
.prologue
next find this method
Code:
.method protected makeStatusBarView()Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
scroll down still in that method , add the blue code
but you must adapt the register number v0 and v5 with yours
Code:
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/policy/NotificationRowLayout;->setLongPressListener(Landroid/view/View$OnLongClickListener;)V
.line 511
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedContents:Landroid/view/View;
[COLOR="Blue"]iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c00bc
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelContents:Landroid/view/View;[/COLOR]
.line 513
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c0049
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
.line 514
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 515
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/4 v5, 0x0
invoke-virtual {v0, v5}, Landroid/view/View;->setAlpha(F)V
.line 516
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/16 v5, 0x8
invoke-virtual {v0, v5}, Landroid/view/View;->setVisibility(I)V
.line 517
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
invoke-virtual {v0, v1}, Landroid/view/View;->setEnabled(Z)V
.line 518
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c0045
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Lcom/android/systemui/statusbar/policy/DateView;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
.line 519
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
invoke-virtual {v0}, Lcom/android/systemui/statusbar/policy/DateView;->getDate()Landroid/widget/TextView;
move-result-object v0
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$8;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$8;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v0, v5}, Landroid/widget/TextView;->addTextChangedListener(Landroid/text/TextWatcher;)V
.line 533
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c003a
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Lcom/android/systemui/statusbar/policy/Clock;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockView:Lcom/android/systemui/statusbar/policy/Clock;
.line 534
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockView:Lcom/android/systemui/statusbar/policy/Clock;
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$9;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$9;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/policy/Clock;->addTextChangedListener(Landroid/text/TextWatcher;)V
.line 548
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c0048
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/view/View;
.line 549
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 550
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c0047
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Lcom/android/systemui/statusbar/RotationToggle;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRotationButton:Lcom/android/systemui/statusbar/RotationToggle;
.line 551
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c0046
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mButtonsBar:Landroid/view/View;
.line 554
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
new-instance v5, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$10;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$10;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/policy/DateView;->post(Ljava/lang/Runnable;)Z
.line 561
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
invoke-virtual {v0, v9}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/TextView;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCarrierLabel:Landroid/widget/TextView;
.line 562
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCarrierLabel:Landroid/widget/TextView;
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCarrierLabelVisible:Z
if-eqz v0, :cond_6
move v0, v1
:goto_3
invoke-virtual {v5, v0}, Landroid/widget/TextView;->setVisibility(I)V
[COLOR="Blue"]iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c00b6
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButton:Landroid/view/View;
.line 101
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButton:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 110
const v5, 0x7f0c00b7
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButton:Landroid/view/View;
.line 111
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButton:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 120
const v5, 0x7f0c00ad
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ViewFlipper;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHeaderFlipper:Landroid/widget/ViewFlipper;
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 121
const v5, 0x7f0c00b8
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ViewFlipper;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContentsFlipper:Landroid/widget/ViewFlipper;
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 130
const v5, 0x7f0c006a
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentsButton:Landroid/view/View;
.line 131
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentsButton:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentsClickListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 140
const v5, 0x7f0c00be
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsToggles:Landroid/view/View;
.line 141
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsToggles:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsTogglesListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 150
const v5, 0x7f0c00bf
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSliders:Landroid/view/View;
.line 151
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSliders:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSlidersListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 152
const v5, 0x7f0c00c9
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsToggles:Landroid/view/View;
.line 153
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsToggles:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsTogglesListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 154
const v5, 0x7f0c00ca
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSliders:Landroid/view/View;
.line 155
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSliders:Landroid/view/View;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSlidersListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v5}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 156
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->selectQuickPanelInitialTab()V
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
.line 160
const v5, 0x7f0c00c0
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ViewFlipper;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelFlipper:Landroid/widget/ViewFlipper;
.line 170
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setQuickPanelVolumeSliders()V
.line 180
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setQuickPanelUserButtonInfo()V[/COLOR]
.line 564
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c0042
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mScrollView:Landroid/widget/ScrollView;
.line 565
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mScrollView:Landroid/widget/ScrollView;
invoke-virtual {v0, v1}, Landroid/widget/ScrollView;->setVerticalScrollBarEnabled(Z)V
[COLOR="Blue"]iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v5, 0x7f0c00c8
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Lcom/lidroid/systemui/quickpanel/PowerWidget;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
.line 568
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
[/COLOR]
next, scroll down still in the same method , add the blue code, and adapt the register number in red highlight only
Code:
const-string [COLOR="Red"]v1[/COLOR], "android.intent.action.SCREEN_OFF"
invoke-virtual {[COLOR="Red"]v0, v1[/COLOR]}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
[COLOR="Blue"]const-string [COLOR="Red"]v1[/COLOR], "android.media.VOLUME_CHANGED_ACTION"
invoke-virtual {[COLOR="Red"]v0, v1[/COLOR]}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V[/COLOR]
.line 656
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBroadcastReceiver:Landroid/content/BroadcastReceiver;
invoke-virtual {v3, v1, v0}, Landroid/content/Context;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
[COLOR="Blue"]iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
invoke-virtual {v1}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setupWidget()V
.line 700
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v6, 0x7f0c009f
invoke-virtual {v5, v6}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v5
check-cast v5, Lcom/android/systemui/statusbar/policy/ToggleSlider;
new-instance v9, Lcom/android/systemui/statusbar/policy/BrightnessController;
iget-object v6, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-direct {v9, v6, v5}, Lcom/android/systemui/statusbar/policy/BrightnessController;-><init>(Landroid/content/Context;Lcom/android/systemui/statusbar/policy/ToggleSlider;)V
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBrightness:Lcom/android/systemui/statusbar/policy/BrightnessController;[/COLOR]
.line 658
.line 660
invoke-static {}, Landroid/view/VelocityTracker;->obtain()Landroid/view/VelocityTracker;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mVelocityTracker:Landroid/view/VelocityTracker;
.line 662
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
return-object v0
Adi Aisiteru Reborn said:
Don't follow the guide yet, till I say DONE
Click to expand...
Click to collapse
cann't wait
next find this method
Code:
.method protected updateRecentsPanel()V
add the blue code above it
Code:
[COLOR="Blue"].method public updateQuickPanelUserButtonInfo()V
.locals 3
.prologue
.line 80
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v2, 0x7f0c00bb
invoke-virtual {v1, v2}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v1
check-cast v1, Landroid/widget/TextView;
.line 81
.local v1, userButtonText:Landroid/widget/TextView;
invoke-direct {p0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateUserButtonText(Landroid/widget/TextView;)V
.line 83
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v2, 0x7f0c00ba
invoke-virtual {v0, v2}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ImageView;
.line 84
.local v0, userButtonImage:Landroid/widget/ImageView;
invoke-direct {p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateUserButtonImage(Landroid/widget/ImageView;)V
.line 86
return-void
.end method
.method public updateQuickPanelVolumeSliders()V
.locals 8
.prologue
.line 176
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v7, 0x7f0c00c1
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v3
check-cast v3, Landroid/widget/SeekBar;
.line 177
.local v3, ringSlider:Landroid/widget/SeekBar;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x2
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v3, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 180
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v7, 0x7f0c00c2
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v2
check-cast v2, Landroid/widget/SeekBar;
.line 181
.local v2, notificationSlider:Landroid/widget/SeekBar;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x5
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v2, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 184
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v7, 0x7f0c00c3
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v4
check-cast v4, Landroid/widget/SeekBar;
.line 185
.local v4, voiceCallSlider:Landroid/widget/SeekBar;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x0
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v4, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 188
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v7, 0x7f0c00c4
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v1
check-cast v1, Landroid/widget/SeekBar;
.line 189
.local v1, mediaSlider:Landroid/widget/SeekBar;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x3
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v1, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 192
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v7, 0x7f0c00c5
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/SeekBar;
.line 193
.local v0, alarmSlider:Landroid/widget/SeekBar;
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAudioManager:Landroid/media/AudioManager;
const/4 v6, 0x4
invoke-virtual {v5, v6}, Landroid/media/AudioManager;->getStreamVolume(I)I
move-result v5
invoke-virtual {v0, v5}, Landroid/widget/SeekBar;->setProgress(I)V
.line 195
return-void
.end method[/COLOR]
.method protected updateRecentsPanel()V
.locals 4
.prologue
.line 714
const v0, 0x7f030012
DONE AND RECOMPILE YOUR SYSTEMUI.APK
CONTINUE THE GUIDE IN NEXT POST #11
Decompile the newly Recompiled APK again
Next go to
res/values/public.xml
open it with Notepad++
leave it, but keep it open
Download attached 4.2_source_public, open it with Notepad++
so now you have two xml which is opened in the Notepad++
1. second decompiled SystemUI.apk public.xml and
2. 4.2_source_public
next
- Second decompiled SystemUI.apk / smali/com/android/systemui/statusbar/phone/PhoneStatusBar.smali
find all ids which is started with
Code:
0x7f[COLOR="Red"]xxxxxx[/COLOR]
in all blue code you have added
find those ids in the 4.2_source_public
EXAMPLE :
Code:
.method private fastFlipToQuickPanelToggles()V
.locals 2
.prologue
.line 2255
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1,[B][COLOR="Red"] 0x7f0c00c6[/COLOR][/B] <--- [COLOR="Blue"]replace this with your new ids[/COLOR]
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/ScrollView;
.line 2257
.local v0, svToggles:Landroid/widget/ScrollView;
const/16 v1, 0x21
FIND 0x7f0c00c6 in 4.2_source_public
we find that is for
Code:
<public type="[COLOR="Green"]id[/COLOR]" name="[COLOR="Green"]quickpanel_scrollview_toggles[/COLOR]" id="[COLOR="Red"]0x7f0c00c6[/COLOR]" />
next find quickpanel_scrollview_toggles in your second decompiled SystemUI.apk public.xml
Code:
<public type="[COLOR="Green"]id[/COLOR]" name="[COLOR="Green"]quickpanel_scrollview_toggles[/COLOR]" id="[COLOR="Red"]0x7f??????[/COLOR]" />
do it too to all
Code:
0x7f[COLOR="Red"]xxxxxx[/COLOR]
in all blue code you have added
and in all smalis in SystemUI.apk\smali\com\lidroid\systemui\quickpanel\here ..
NEXT / the last
make change to AndroidManifest.xml
BEFORE
Code:
[COLOR="Red"]<manifest android:versionCode="16"[/COLOR] android:versionName="4.1.2-eng.arco.20130605.050149" package="com.android.systemui" coreApp="true"
CHANGE TO :
Code:
[COLOR="Red"]<manifest android:sharedUserId="android.uid.system" android:process="system" android:versionCode="16"[/COLOR] android:versionName="4.1.2-eng.arco.20130605.050149" package="com.android.systemui" coreApp="true"
Next, add the red code
Code:
<uses-permission android:name="android.permission.DISABLE_KEYGUARD" />
<uses-permission android:name="android.permission.WRITE_SECURE_SETTINGS" />
<uses-permission android:name="android.permission.READ_SYNC_SETTINGS" />
<uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS" />
[COLOR="Red"]<uses-permission android:name="android.permission.CAMERA" />[/COLOR]
<application android:label="@string/app_label" android:icon="@*android:drawable/platlogo" android:allowClearUserData="false" android:persistent="true" android:allowBackup="false" android:hardwareAccelerated="true">
<service android:name="SystemUIService" android:exported="true" />
NEXT , add the red code to the end
Code:
<activity android:theme="@*android:style/Theme.Wallpaper.NoTitleBar.Fullscreen" android:label="BeanBag" android:icon="@drawable/redbeandroid" android:name=".BeanBag" android:exported="true" android:excludeFromRecents="true" android:launchMode="singleInstance" android:hardwareAccelerated="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="com.android.internal.category.PLATLOGO" />
</intent-filter>
</activity>
[COLOR="Red"]<receiver android:name="com.lidroid.systemui.quickpanel.NetworkModeReceiver" android:process="com.android.phone">
<intent-filter>
<action android:name="com.serajr.powertoggles.POWERTOGGLES_CHANGE_NETWORK_MODE" />
<action android:name="com.serajr.powertoggles.POWERTOGGLES_NEW_NETWORK_MODE" />
</intent-filter>
</receiver>[/COLOR]
</application>
</manifest>
Done & Compile, don't forget to sign it coz we've make change to the android.manifest.xml
I ussually use ApkMultitools to decompile/recompile/sign APK
so if you use ApkMultitools, you can use my signer keys
download attached file, exstract it and merge to your ApkMultitools / other / here
NOTE !! you can skip step editing android.manifest.xml, but Reboot, flashlight, 2G , 3G, 2G/3G toggle will not work
ADDITIONAL FIX CODE FOR
Code:
[B][COLOR="Black"].method performCollapse()V[/COLOR][/B]
This code will fix the pulldown behaviour which will always viewing/revert to Notification panel instead of other panel when we pull down tray.
add the blue code
Code:
[B].method performCollapse()V[/B]
.locals 4
.prologue
const/4 v3, 0x0
.line 1482
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
if-nez v0, :cond_1
.line 1519
:cond_0
:goto_0
return-void
.line 1487
:cond_1
invoke-virtual {p0, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateExpandedViewPos(I)V
.line 1489
iput-boolean v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
.line 1490
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
invoke-virtual {v0, v3}, Lcom/android/systemui/statusbar/policy/NotificationRowLayout;->setLayoutTransitionsEnabled(Z)V
.line 1491
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
if-eqz v0, :cond_2
.line 1492
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
invoke-virtual {v0, v3}, Lcom/android/systemui/statusbar/phone/NavigationBarView;->setSlippery(Z)V
.line 1493
:cond_2
invoke-virtual {p0, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->visibilityChanged(Z)V
.line 1496
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContainer:Landroid/widget/FrameLayout;
invoke-virtual {v0}, Landroid/widget/FrameLayout;->getLayoutParams()Landroid/view/ViewGroup$LayoutParams;
move-result-object v0
check-cast v0, Landroid/view/WindowManager$LayoutParams;
.line 1497
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->getStatusBarHeight()I
move-result v1
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->height:I
.line 1498
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
or-int/lit8 v1, v1, 0x8
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 1499
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
const v2, -0x20001
and-int/2addr v1, v2
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 1500
invoke-static {}, Landroid/view/WindowManagerImpl;->getDefault()Landroid/view/WindowManagerImpl;
move-result-object v1
.line 1501
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContainer:Landroid/widget/FrameLayout;
invoke-interface {v1, v2, v0}, Landroid/view/WindowManager;->updateViewLayout(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
[COLOR="Blue"]
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->fastFlipToNotifications()V
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->fastFlipToQuickPanelToggles()V
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->deselectAllQuickPanelTabs()V
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->selectQuickPanelInitialTab()V[/COLOR]
.line 1503
iget v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisabled:I
const/high16 v1, 0x2
and-int/2addr v0, v1
if-nez v0, :cond_3
.line 1504
const/4 v0, 0x1
const/high16 v1, 0x10a
ADDITIONAL INSTRUCTION FOR TWO SIM CARDS DEVICES
SEE THE DIFFERENT BELOW
IN SINGLE SIM DEVICES
Code:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout android:id="@id/notification_panel" android:background="@drawable/notification_panel_bg" android:paddingTop="@dimen/notification_panel_padding_top" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginLeft="@dimen/notification_panel_margin_left"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
[COLOR="Blue"]<TextView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network" android:gravity="center" android:layout_gravity="bottom" [COLOR="Red"]android:id="@id/carrier_label"[/COLOR] android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="@dimen/carrier_label_height" android:layout_marginBottom="@dimen/close_handle_height" />[/COLOR]
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginBottom="@dimen/close_handle_underlap">
<include android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_header_height" layout="@layout/status_bar_expanded_header" />
IN TWO SIM CARDS DEVICES
Code:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout android:id="@id/notification_panel" android:background="@drawable/notification_panel_bg" android:paddingTop="@dimen/notification_panel_padding_top" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginLeft="@dimen/notification_panel_margin_left"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
[COLOR="Blue"][COLOR="Green"]<LinearLayout[/COLOR] android:gravity="center" android:layout_gravity="bottom" android:orientation="horizontal" [COLOR="Red"]android:id="@id/carrier_label_gemini"[/COLOR] android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="@dimen/carrier_label_height" android:layout_marginBottom="@dimen/close_handle_height">
<com.android.systemui.statusbar.phone.CarrierLabelGemini android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network" android:gravity="center" android:layout_gravity="center" android:id="@id/carrier1" android:paddingLeft="12.0dip" android:paddingRight="12.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:singleLine="true" android:layout_weight="1.0" />
<ImageView android:layout_gravity="center" android:id="@id/carrier_divider" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/gemini_carrier_divider" />
<com.android.systemui.statusbar.phone.CarrierLabelGemini android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Network" android:gravity="center" android:layout_gravity="center" android:id="@id/carrier2" android:paddingLeft="12.0dip" android:paddingRight="12.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:singleLine="true" android:layout_weight="1.0" />
[COLOR="Green"]</LinearLayout>[/COLOR][/COLOR]
IF YOU CAN SEE THE RED HIGHLIGHT IN THE PART OF BLUE PART
FOR SINGLE SIM CARD
Code:
[COLOR="Red"]android:id="@id/carrier_label"[/COLOR]
FOR TWO SIM CARD
Code:
[COLOR="Red"]android:id="@id/carrier_label_gemini"[/COLOR]
WILL BE THE IDS OF
Code:
.method private hideCarrierLabel()V
.locals 2
.prologue
.line 125
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, [COLOR="Red"]0x7f0c003f[/COLOR]
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
.line 126
.local v0, carrierLabel:Landroid/view/View;
const/16 v1, 0x8
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
.line 129
return-void
.end method
AND
Code:
.method private showCarrierLabel()V
.locals 2
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v1, [COLOR="Red"]0x7f0c003f[/COLOR]
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v0
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
return-void
.end method
Hi buddy... great job!!! :good:
I´m about to finish my new Power Toggles that I´ve made from scratch, and a lot of news are comming, like:
- Real android GridLayout based toggles, so you are able to span a specific toggle to fit two/three rows and/or cols
- Don´t mind about enabled and disable icons resources anymore, so now just one icon resource for each toggle is needed (a white one)
- If your firmaware has theme color, icons will get its color at runtime, but you can override theme color and set your own color
- Don´t mind about hex id values anymore (public.xml), Power Toggles will find proper resource (strings, drawables) by itself at runtime (porting it to your SystemUI has never been so easy)
- Choose color of icon and/or titles
- A new way to enable and reorder toggles (all on the same screen)
- And more...
Soon I´ll be back with some screenshots!!!
serajr said:
Hi buddy... great job!!! :good:
I´m about to finish my new Power Toggles that I´ve made from scratch, and a lot of news are comming, like:
- Real android GridLayout based toggles, so you are able to span a specific toggle to fit two/three rows and/or cols
- Don´t mind about enabled and disable icons resources anymore, so now just one icon resource for each toggle is needed (a white one)
- If your firmaware has theme color, icons will get its color at runtime, but you can override theme color and set your own color
- Don´t mind about hex id values anymore (public.xml), Power Toggles will find proper resource (strings, drawables) by itself at runtime (porting it to your SystemUI has never been so easy)
- Choose color of icon and/or titles
- A new way to enable and reorder toggles (all on the same screen)
- And more...
Soon I´ll be back with some screenshots!!!
Click to expand...
Click to collapse
your work is always nice and creates sir
glad you give me permission for porting it to different FIRMWARE/OS/DEVICES
especially this JB 4.2 style status bar mods
Oke guys , Guide is Done now
Have a nice modding your device
EDIT :
for you who have followed the guide, please do check agin in all new lines PhoneStatusBar$xx,. I ve just fixed it
Good guide bro.. good job
Awesome :good:
Again Coming with HeadAche - Please Pardon me for this
Sir @Adi Aisiteru Reborn
First of all, I don't know how to thank you. Cause whatever I asked you, you made a guide. You are a real teacher Sir. All of your guide is useful for me and so I never hesitated trying it may it work or not. Fortunately every guide of yours work for me but not in first attempt.
And So Once again your new disciple is here to bring some headache again. I tried it and got the below things in my logcat.
Please have look at it.
Code:
I/dalvikvm( 907): Could not find method com.android.systemui.statusbar.phone.PhoneStatusBar.hideCarrierLabel, referenced from method com.android.systemui.statusbar.phone.PhoneStatusBar.flipToQuickPanel
W/dalvikvm( 907): VFY: unable to resolve direct method 3303: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.hideCarrierLabel ()V
D/dalvikvm( 907): VFY: replacing opcode 0x70 at 0x0000
I/dalvikvm( 907): Could not find method com.android.systemui.statusbar.phone.PhoneStatusBar.inFromRightAnimation, referenced from method com.android.systemui.statusbar.phone.PhoneStatusBar.flipToQuickPanelSliders
W/dalvikvm( 907): VFY: unable to resolve static method 3309: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.inFromRightAnimation ()Landroid/view/animation/Animation;
D/dalvikvm( 907): VFY: replacing opcode 0x71 at 0x0012
I/dalvikvm( 907): Could not find method com.android.systemui.statusbar.phone.PhoneStatusBar.inFromLeftAnimation, referenced from method com.android.systemui.statusbar.phone.PhoneStatusBar.flipToQuickPanelToggles
W/dalvikvm( 907): VFY: unable to resolve static method 3308: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.inFromLeftAnimation ()Landroid/view/animation/Animation;
D/dalvikvm( 907): VFY: replacing opcode 0x71 at 0x0012
W/dalvikvm( 907): VFY: tried to get class from non-ref register v9 (type=11)
W/dalvikvm( 907): VFY: rejecting opcode 0x6e at 0x0184
W/dalvikvm( 907): VFY: rejected Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.makeStatusBarView ()Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
W/dalvikvm( 907): Verifier rejected class Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
W/dalvikvm( 907): Class init failed in newInstance call (Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)
D/AndroidRuntime( 907): Shutting down VM
W/dalvikvm( 907): threadid=1: thread exiting with uncaught exception (group=0x40e12908)
D/ActivityThread( 1234): BDC-Calling onReceive: intent=Intent { act=android.intent.action.PACKAGE_CHANGED dat=package:com.android.stk2 flg=0x8000010 cmp=com.android.vending/com.google.android.finsky.receivers.PackageMonitorReceiver$RegisteredReceiver (has extras) }, ordered=true, receiver=com.google.and[email protected]41708870
E/AndroidRuntime( 907): FATAL EXCEPTION: main
E/AndroidRuntime( 907): java.lang.VerifyError: com/android/systemui/statusbar/phone/PhoneStatusBar
E/AndroidRuntime( 907): at java.lang.Class.newInstanceImpl(Native Method)
E/AndroidRuntime( 907): at java.lang.Class.newInstance(Class.java:1319)
E/AndroidRuntime( 907): at com.android.systemui.SystemUIService.onCreate(SystemUIService.java:664)
E/AndroidRuntime( 907): at android.app.ActivityThread.handleCreateService(ActivityThread.java:2504)
E/AndroidRuntime( 907): at android.app.ActivityThread.access$1600(ActivityThread.java:149)
E/AndroidRuntime( 907): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1382)
E/AndroidRuntime( 907): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 907): at android.os.Looper.loop(Looper.java:153)
E/AndroidRuntime( 907): at android.app.ActivityThread.main(ActivityThread.java:5086)
E/AndroidRuntime( 907): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 907): at java.lang.reflect.Method.invoke(Method.java:511)
E/AndroidRuntime( 907): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:821)
E/AndroidRuntime( 907): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:584)
E/AndroidRuntime( 907): at dalvik.system.NativeStart.main(Native Method)
When I asked my friend "Google" for this, he just redirected me to this post that answers this things but out of my understanding.
Answers For Problem |||| And thread is here --- Click Me
The line of the logcat of mine and in the thread is just same to same. I am attaching my modded "phonestatusbar.smali" so please have look on this.
Or guide me for the changes.
BOND1987 said:
Sir @Adi Aisiteru Reborn
First of all, I don't know how to thank you. Cause whatever I asked you, you made a guide. You are a real teacher Sir. All of your guide is useful for me and so I never hesitated trying it may it work or not. Fortunately every guide of yours work for me but not in first attempt.
And So Once again your new disciple is here to bring some headache again. I tried it and got the below things in my logcat.
Please have look at it.
Code:
I/dalvikvm( 907): Could not find method com.android.systemui.statusbar.phone.PhoneStatusBar.hideCarrierLabel, referenced from method com.android.systemui.statusbar.phone.PhoneStatusBar.flipToQuickPanel
W/dalvikvm( 907): VFY: unable to resolve direct method 3303: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.hideCarrierLabel ()V
D/dalvikvm( 907): VFY: replacing opcode 0x70 at 0x0000
I/dalvikvm( 907): Could not find method com.android.systemui.statusbar.phone.PhoneStatusBar.inFromRightAnimation, referenced from method com.android.systemui.statusbar.phone.PhoneStatusBar.flipToQuickPanelSliders
W/dalvikvm( 907): VFY: unable to resolve static method 3309: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.inFromRightAnimation ()Landroid/view/animation/Animation;
D/dalvikvm( 907): VFY: replacing opcode 0x71 at 0x0012
I/dalvikvm( 907): Could not find method com.android.systemui.statusbar.phone.PhoneStatusBar.inFromLeftAnimation, referenced from method com.android.systemui.statusbar.phone.PhoneStatusBar.flipToQuickPanelToggles
W/dalvikvm( 907): VFY: unable to resolve static method 3308: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.inFromLeftAnimation ()Landroid/view/animation/Animation;
D/dalvikvm( 907): VFY: replacing opcode 0x71 at 0x0012
W/dalvikvm( 907): VFY: tried to get class from non-ref register v9 (type=11)
W/dalvikvm( 907): VFY: rejecting opcode 0x6e at 0x0184
W/dalvikvm( 907): VFY: rejected Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.makeStatusBarView ()Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
W/dalvikvm( 907): Verifier rejected class Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
W/dalvikvm( 907): Class init failed in newInstance call (Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)
D/AndroidRuntime( 907): Shutting down VM
W/dalvikvm( 907): threadid=1: thread exiting with uncaught exception (group=0x40e12908)
D/ActivityThread( 1234): BDC-Calling onReceive: intent=Intent { act=android.intent.action.PACKAGE_CHANGED dat=package:com.android.stk2 flg=0x8000010 cmp=com.android.vending/com.google.android.finsky.receivers.PackageMonitorReceiver$RegisteredReceiver (has extras) }, ordered=true, receiver=com.google.and[email protected]41708870
E/AndroidRuntime( 907): FATAL EXCEPTION: main
E/AndroidRuntime( 907): java.lang.VerifyError: com/android/systemui/statusbar/phone/PhoneStatusBar
E/AndroidRuntime( 907): at java.lang.Class.newInstanceImpl(Native Method)
E/AndroidRuntime( 907): at java.lang.Class.newInstance(Class.java:1319)
E/AndroidRuntime( 907): at com.android.systemui.SystemUIService.onCreate(SystemUIService.java:664)
E/AndroidRuntime( 907): at android.app.ActivityThread.handleCreateService(ActivityThread.java:2504)
E/AndroidRuntime( 907): at android.app.ActivityThread.access$1600(ActivityThread.java:149)
E/AndroidRuntime( 907): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1382)
E/AndroidRuntime( 907): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 907): at android.os.Looper.loop(Looper.java:153)
E/AndroidRuntime( 907): at android.app.ActivityThread.main(ActivityThread.java:5086)
E/AndroidRuntime( 907): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 907): at java.lang.reflect.Method.invoke(Method.java:511)
E/AndroidRuntime( 907): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:821)
E/AndroidRuntime( 907): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:584)
E/AndroidRuntime( 907): at dalvik.system.NativeStart.main(Native Method)
When I asked my friend "Google" for this, he just redirected me to this post that answers this things but out of my understanding.
Answers For Problem |||| And thread is here --- Click Me
The line of the logcat of mine and in the thread is just same to same. I am attaching my modded "phonestatusbar.smali" so please have look on this.
Or guide me for the changes.
Click to expand...
Click to collapse
Please use un-modded SystemUI.apk ,. ehh sir Bond
Many thanks to this guide!
THANK YOU ADI FOR POSTING THE GUIDE! I'LL BE POSTING SCREENSHOTS AFTER I MOD MY SYSTEMUI! THANKS A LOT!! :good: :good: :good:

[CM9/ICS] Guide How to full screen Expanded Pulldown JB style

Guide CM9 / ICS How to full screen Expanded Pulldown JB style
ok lets go to Guide:
first of all need some requirement for this MOD-GUIDE
REQUIREMENT:
- BRAIN
- Patient
- experience
- Know how to decompile/recompiling Apk file
- notepad++
- Tool for decompiling, : apkmanager/apktool/Virtous/apkmultitools/ or else
STEP -1
Decompile SytemUI.apk, go to SystemUI.apk\res\layout\ status_bar.xml
Make change to this line
Code:
<com.android.systemui.statusbar.phone.PhoneStatusBarView [COLOR="Blue"]android:background="@drawable/status_bar_custom_background"[/COLOR] android:focusable="true" android:descendantFocusability="afterDescendants" android:layout_width="fill_parent" android:layout_height="fill_parent"
STEP -2
Download attached file status_bar_custom_background.zip exstract it and put it to SystemUI.apk\res\drawable-hdpi
STEP -3
SystemUI.apk\res\layout\ status_bar_expanded.xml
add the blue code,. and 20.0dip you can set it to others value you like
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.ExpandedView android:orientation="vertical" android:focusable="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<LinearLayout [COLOR="Blue"]android:layout_marginTop="20.0dip"[/COLOR] android:orientation="vertical" android:background="@drawable/notification_header_bg" android:layout_width="fill_parent" android:layout_height="wrap_content">
<com.android.systemui.statusbar.powerwidget.PowerWidget android:id="@id/exp_power_stat" android:layout_width="fill_parent" android:layout_height="wrap_content" />
<RelativeLayout android:paddingTop="3.0dip" android:paddingRight="3.0dip" android:paddingBottom="5.0dip" android:layout_width="fill_parent" android:layout_height="52.0dip">
<com.android.systemui.statusbar.policy.DateView android:textAppearance="@style/TextAppearance.StatusBar.Date" android:gravity="left|center" android:id="@id/date" android:paddingLeft="16.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:layout_alignParentLeft="true" />
<ImageView android:id="@id/settings_button" android:paddingLeft="8.0dip" android:paddingRight="8.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/ic_notify_quicksettings" android:layout_toRightOf="@id/date" android:contentDescription="@string/accessibility_settings_button" />
<ImageView android:id="@id/clear_all_button" android:paddingLeft="8.0dip" android:paddingRight="8.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/ic_notify_clear" android:layout_alignParentRight="true" android:contentDescription="@string/accessibility_clear_all" />
</RelativeLayout>
</LinearLayout>
<View android:background="@drawable/status_bar_hr" android:layout_width="fill_parent" android:layout_height="2.0dip" />
<FrameLayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@*android:style/TextAppearance.Large" android:gravity="left" android:layout_gravity="top" android:id="@id/noNotificationsTitle" android:padding="8.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="@string/status_bar_no_notifications_title" />
<ScrollView android:id="@id/scroll" android:fadingEdge="none" android:layout_width="fill_parent" android:layout_height="fill_parent" android:overScrollMode="ifContentScrolls">
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content">
<com.android.systemui.statusbar.policy.NotificationRowLayout android:id="@id/latestItems" android:layout_width="fill_parent" android:layout_height="wrap_content" systemui:rowHeight="@dimen/notification_height" />
</LinearLayout>
</ScrollView>
<ImageView android:layout_width="fill_parent" android:layout_height="fill_parent" android:src="@drawable/title_bar_shadow" android:scaleType="fitXY" />
</FrameLayout>
</com.android.systemui.statusbar.phone.ExpandedView>
STEP -4
SystemUI.apk\smali\com\android\systemui\statusbar\ StatusBar.smali
search this line
Code:
invoke-direct/range {v11 .. v16}, Landroid/view/WindowManager$LayoutParams;-><init>(IIIII)V
and add this const/16 v16, -0x3 above it
Code:
const/4 v12, -0x1
const/16 v14, 0x7d0
const v15, 0x800048
const/16 v16, 0x4
[COLOR="Blue"]const/16 v16, -0x3[/COLOR]
invoke-direct/range {v11 .. v16}, Landroid/view/WindowManager$LayoutParams;-><init>(IIIII)V
.line 135
.local v11, lp:Landroid/view/WindowManager$LayoutParams;
move-object/from16 v0, p0
Next continue in Post # 2
STEP -5
SystemUI.apk\smali\com\android\systemui\statusbar\phone\ PhoneStatusBar.smali
Add the blue code
Code:
.field private mFlingGestureMaxXVelocityPx:F
.field mFocusChangeListener:Landroid/view/View$OnFocusChangeListener;
[COLOR="Blue"].field mGetStatusBarHeight:I[/COLOR]
.field mHandler:Lcom/android/systemui/statusbar/phone/PhoneStatusBar$H;
.field mIconHPadding:I
Code:
[B]# direct methods
.method public constructor <init>()V[/B]
.locals 4
.prologue
const/4 v3, 0x2
const/4 v2, 0x0
const/4 v0, -0x1
const/4 v1, 0x0
.line 99
invoke-direct {p0}, Lcom/android/systemui/statusbar/StatusBar;-><init>()V
.line 155
iput v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNaturalBarHeight:I
.line 156
iput v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIconSize:I
.line 157
iput v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIconHPadding:I
.line 164
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$H;
invoke-direct {v0, p0, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$H;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Lcom/android/systemui/statusbar/phone/PhoneStatusBar$1;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHandler:Lcom/android/systemui/statusbar/phone/PhoneStatusBar$H;
.line 165
new-instance v0, Ljava/lang/Object;
invoke-direct {v0}, Ljava/lang/Object;-><init>()V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQueueLock:Ljava/lang/Object;
.line 188
new-instance v0, Lcom/android/systemui/statusbar/NotificationData;
invoke-direct {v0}, Lcom/android/systemui/statusbar/NotificationData;-><init>()V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationData:Lcom/android/systemui/statusbar/NotificationData;
.line 192
new-array v0, v3, [I
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPositionTmp:[I
.line 203
iput-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
.line 236
iput-boolean v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimatingReveal:Z
.line 238
new-array v0, v3, [I
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAbsPos:[I
.line 239
iput v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mLinger:I
.line 240
iput-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPostCollapseCleanup:Ljava/lang/Runnable;
.line 245
iput-boolean v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecreating:Z
.line 248
iput v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisabled:I
.line 251
iput [COLOR="Red"]v1[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSystemUiVisibility:I
[COLOR="Blue"]iput [COLOR="Red"]v1[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mGetStatusBarHeight:I[/COLOR]
.line 253
new-instance v0, Landroid/util/DisplayMetrics;
invoke-direct {v0}, Landroid/util/DisplayMetrics;-><init>()V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisplayMetrics:Landroid/util/DisplayMetrics;
Code:
[B].method private makeExpandedVisible()V[/B]
.locals 3
.prologue
const/4 v1, 0x1
.line 1267
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
if-eqz v0, :cond_0
.line 1282
:goto_0
return-void
.line 1270
:cond_0
iput-boolean v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
.line 1271
invoke-virtual {p0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->visibilityChanged(Z)V
.line 1273
const/16 v0, -0x2710
invoke-virtual {p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateExpandedViewPos(I)V
.line 1274
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedParams:Landroid/view/WindowManager$LayoutParams;
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
and-int/lit8 v1, v1, -0x9
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 1275
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedParams:Landroid/view/WindowManager$LayoutParams;
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
const/high16 v2, 0x2
or-int/2addr v1, v2
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 1279
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 1280
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 1281
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="Blue"]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
Code:
[B].method performCollapse()V[/B]
.locals 4
.prologue
const/4 v3, 0x0
.line 1357
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
if-nez v0, :cond_1
.line 1379
:cond_0
:goto_0
return-void
.line 1360
:cond_1
iput-boolean v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedVisible:Z
.line 1361
invoke-virtual {p0, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->visibilityChanged(Z)V
.line 1362
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedParams:Landroid/view/WindowManager$LayoutParams;
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
or-int/lit8 v1, v1, 0x8
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 1363
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedParams:Landroid/view/WindowManager$LayoutParams;
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
const v2, -0x20001
and-int/2addr v1, v2
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 1364
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 1365
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="Blue"]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 1367
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
Code:
[B].method protected makeStatusBarView()Landroid/view/View;[/B]
.locals 12
.prologue
const/16 v11, 0x8
const/4 v10, 0x0
.line 333
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
.line 335
.local v0, context:Landroid/content/Context;
invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v3
.line 337
.local v3, res:Landroid/content/res/Resources;
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateDisplaySize()V
.line 338
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadDimens()V
[COLOR="Blue"]iget v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNaturalBarHeight:I[/COLOR]
const v8, 0x105000e
invoke-virtual {v3, v8}, Landroid/content/res/Resources;->getDimensionPixelSize(I)I
move-result v8
iput v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIconSize:I
STEP -6
Add the blue code
and pay attention to the red v1 iget v1, p0,..... you must write same like what move-result v1
Code:
[B].method doAnimation()V[/B]
.locals 4
.prologue
const/4 v2, 0x0
.line 1382
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimating:Z
if-eqz v0, :cond_0
.line 1385
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->incrementAnim()V
.line 1387
iget v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimY:F
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisplayMetrics:Landroid/util/DisplayMetrics;
iget v1, v1, Landroid/util/DisplayMetrics;->heightPixels:I
add-int/lit8 v1, v1, -0x1
int-to-float v1, v1
cmpl-float v0, v0, v1
if-ltz v0, :cond_1
.line 1389
iput-boolean v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimating:Z
.line 1390
const/16 v0, -0x2711
invoke-virtual {p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateExpandedViewPos(I)V
.line 1391
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->performExpand()V
.line 1405
:cond_0
:goto_0
return-void
.line 1393
:cond_1
iget v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimY:F
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
invoke-virtual {v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result [COLOR="Red"]v1[/COLOR]
[COLOR="Blue"]iget [COLOR="Red"]v1[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mGetStatusBarHeight:I[/COLOR]
int-to-float v1, v1
cmpg-float v0, v0, v1
if-gez v0, :cond_2
.line 1395
iput-boolean v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimating:Z
Code:
[B].method doRevealAnimation()V[/B]
.locals 5
.prologue
.line 1427
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCloseView:Lcom/android/systemui/statusbar/phone/CloseDragHandle;
invoke-virtual {v1}, Lcom/android/systemui/statusbar/phone/CloseDragHandle;->getHeight()I
move-result v1
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result [COLOR="Red"]v2[/COLOR]
[COLOR="Blue"]iget [COLOR="Red"]v2[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mGetStatusBarHeight:I[/COLOR]
add-int v0, v1, v2
.line 1428
.local v0, h:I
iget-boolean v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimatingReveal:Z
Code:
[B].method getExpandedHeight(I)I[/B]
.locals 2
.parameter "disph"
.prologue
.line 2166
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
invoke-virtual {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result [COLOR="Red"]v0[/COLOR]
[COLOR="Blue"]iget [COLOR="Red"]v0[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mGetStatusBarHeight:I[/COLOR]
sub-int v0, p1, v0
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCloseView:Lcom/android/systemui/statusbar/phone/CloseDragHandle;
invoke-virtual {v1}, Lcom/android/systemui/statusbar/phone/CloseDragHandle;->getHeight()I
Code:
[B].method prepareTracking(IZ)V[/B]
.locals 6
.parameter "y"
.parameter "opening"
.prologue
const/16 v5, 0x65
const/16 v3, 0x64
const/4 v4, 0x1
.line 1449
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateExpandedSize()V
.line 1451
iput-boolean v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTracking:Z
.line 1452
invoke-static {}, Landroid/view/VelocityTracker;->obtain()Landroid/view/VelocityTracker;
move-result-object v2
iput-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mVelocityTracker:Landroid/view/VelocityTracker;
.line 1453
if-eqz p2, :cond_0
.line 1454
iget v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandAccelPx:F
iput v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimAccel:F
.line 1455
iget v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlingExpandMinVelocityPx:F
iput v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimVel:F
.line 1456
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result [COLOR="Red"]v2[/COLOR]
[COLOR="Blue"]iget [COLOR="Red"]v2[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mGetStatusBarHeight:I[/COLOR]
int-to-float v2, v2
iput v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimY:F
.line 1457
iget v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mAnimY:F
Code:
[B].method updateExpandedViewPos(I)V[/B]
.locals 12
.parameter "expandedPosition"
.prologue
const/16 v11, -0x2710
const/4 v7, 0x1
.line 2070
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
invoke-virtual {v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->getHeight()I
move-result [COLOR="Red"]v3[/COLOR]
[COLOR="Blue"]iget [COLOR="Red"]v3[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mGetStatusBarHeight:I[/COLOR]
.line 2071
.local v3, h:I
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisplayMetrics:Landroid/util/DisplayMetrics;
iget v2, v8, Landroid/util/DisplayMetrics;->heightPixels:I
Done, and recompile your systemUI.apk
Credit & Thanks to :
Recognized Themer @serajr
Senior Member @ZN6
Recognized Developer @arco68
Senior member @mastershefis
reserved 5
Awesome guide bro... congrats!!! :good:
You ported exactly what I implemented on my initial ICS SystemUI mod, it is not for everyone... I think we have a new RD coming up... I have no doubt!!!
serajr said:
Awesome guide bro... congrats!!! :good:
You ported exactly what I implemented on my initial ICS SystemUI mod, it is not for everyone... I think we have a new RD coming up... I have no doubt!!!
Click to expand...
Click to collapse
Thanks,
I learned so many codes from your mods
This guide dont work for mdpi screens. SystemUI fc. Can you made it also for mdpi?
Adi Aisiteru Reborn said:
Done, and recompile your systemUI.apk
Credit & Thanks to :
Recognized Themer @serajr
Senior Member @ZN6
Recognized Developer @arco68
Senior member @mastershefis
Click to expand...
Click to collapse
I could not compile it. I get this error.
Code:
[7231,4] The register number must be less than v16
Exception in thread "main" brut.androlib.AndrolibException: Could not smali file: /home/grv/Projects/android/theme/try/SystemUI/smali/com/android/systemui/statusbar/phone/PhoneStatusBar.smali
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexFileBuilder.java:45)
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexFileBuilder.java:33)
at brut.androlib.src.SmaliBuilder.buildFile(SmaliBuilder.java:66)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:50)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:37)
at brut.androlib.Androlib.buildSourcesSmali(Androlib.java:257)
at brut.androlib.Androlib.buildSources(Androlib.java:214)
at brut.androlib.Androlib.build(Androlib.java:205)
at brut.androlib.Androlib.build(Androlib.java:176)
at brut.apktool.Main.cmdBuild(Main.java:228)
at brut.apktool.Main.main(Main.java:79)
Here's my Phonestatusbar.smali, after adding everything http://ubuntuone.com/2JjDXRYSNQvnq05zk7dmII
Also, how's this mod different from this here http://forum.xda-developers.com/showpost.php?p=38232297&postcount=2
Hey hi ! I'm getting the same compile error as the guy above me . Why ?? Bro why,??
Sent from my A500 using xda premium
Sorry for the inconvenion.. the guide is work on my CM9 and it should work too on other Aosp base. Havn't test it on Mtk , leak , Tw.
Sent from my GT-I8150 using xda app-developers app
Can you help me out if I give you my phonestatusbar.smali ???
Sent from my A500 using xda premium
Dude ! Got it working !! Yay !!!! But it looks so weird that when I touch the status bar the whole screen goes up and realignes itself and when it comes down again
Sent from my A500 using xda premium
professor_proton said:
Dude ! Got it working !! Yay !!!! But it looks so weird that when I touch the status bar the whole screen goes up and realignes itself and when it comes down again
Sent from my A500 using xda premium
Click to expand...
Click to collapse
Anyone???
sent from my XOLO A500 running ionised rom you haven't heard of it ???
Please post the link of Xolo a500 ionised rom ..... please ...thanks in advance
Sent from my A500 using XDA Premium 4 mobile app
hp02 said:
Please post the link of Xolo a500 ionised rom ..... please ...thanks in advance
Sent from my A500 using XDA Premium 4 mobile app
Click to expand...
Click to collapse
D Dude I'm currently working on it but my exams going on so give me a month
sent from my XOLO A500 running ionised rom you haven't heard of it ???
Thank u for ur reply
Sent from my A500 using XDA Premium 4 mobile app
professor_proton said:
Dude ! Got it working !! Yay !!!! But it looks so weird that when I touch the status bar the whole screen goes up and realignes itself and when it comes down again
Sent from my A500 using xda premium
Click to expand...
Click to collapse
thats because it uses full screen code and not used as overlay
SpaceCaker said:
thats because it uses full screen code and not used as overlay
Click to expand...
Click to collapse
Hi ! There's a guide by ZN6 about full screen systemui I followed that once but i missed some smali edit which caused the statusbar to use fullscreen but it didnt hide the statusbar so the statusbar overlapped the date bar (the area where the date and time comes ) if you could somehow make it overlap that would be awesome !
In not good enough at smali editing and usually end up with fc's
sent from my XOLO A500 running ionised rom you haven't heard of it ???

[help with a mod]DigitalClock statusbar

This problem is solved see post #5
gerryS2 said:
I have found the file of DigitalClock with second for statusbar (<DigitalClock android...)in framework2.jar in smali/android/widget/DigitalClock.
I have ported this file in smali folder of SystemUI and I have insert this line in tw_status_bar:
<com.android.systemui.statusbar.policy.DigitalClock android:textSize="@dimen/status_bar_clock_text_size"...
I would like to enter a checkbox in the SecSettings to show or hide the clock, the problem is in SystemUI because I can not put a code to hide, I have use a id for hide and insert the android:visibility="gone", but doesn't work. It is possible help me with this mod in SystemUI?
P.S.I am able with SecSettings but I haven't able with SystemUI
Click to expand...
Click to collapse
I have wanted seconds on my statusbar clock. Have you a link to a tutorial? Or, where did you put the smali file into the systemui?
Wish I could help with your request but maybe I can find out on the S Advance forum... if I do I'll be back LOL...
bobfrantic said:
I have wanted seconds on my statusbar clock. Have you a link to a tutorial? Or, where did you put the smali file into the systemui?
Wish I could help with your request but maybe I can find out on the S Advance forum... if I do I'll be back LOL...
Click to expand...
Click to collapse
I have extract the file of framework2.jar in systemUI. I have create for you a zip that contains this file smali, this file must be inserted in:
smali/com/android/systemui/statubar/policy/
You have replace this line of clock in tw_status_bar.xml:
<com.android.systemui.statusbar.policy.Clock
with this:
<com.android.systemui.statusbar.policy.DigitalClock
gerryS2 said:
I have extract the file of framework2.jar in systemUI. I have create for you a zip that contains this file smali, this file must be inserted in:
smali/com/android/systemui/statubar/policy/
You have replace this line of clock in tw_status_bar.xml:
<com.android.systemui.statusbar.policy.Clock
with this:
<com.android.systemui.statusbar.policy.DigitalClock
Click to expand...
Click to collapse
Thank you for this, it worked. Will see what I can find out about a switch for turning on and off the clock in settings. Appreciated much!
bobfrantic said:
Thank you for this, it worked. Will see what I can find out about a switch for turning on and off the clock in settings. Appreciated much!
Click to expand...
Click to collapse
I solved it with the guide of @Goldie, I have created a method in PhoneStatusbar and I have insert a custom id in the line of Digital Clock like this:
Code:
<com.android.systemui.statusbar.policy.DigitalClock android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ff959595" android:ellipsize="none" android:gravity="left|center" android:id="@id/digitalclock_view" android:visibility="gone" android:paddingLeft="3.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:includeFontPadding="false" />
Insert this line in ids.xml:
Code:
<item type="id" name="digitalclock_view">false</item>
In PhoneStatusbar insert this method at the end of the file:
Code:
.method digitalclock_view()V
.locals 6
iget-object v1, p0, Lcom/android/systemui/SystemUI;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const-string v2, "enable_digitalclock"
const/4 v3, 0x1
invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-nez v3, :cond_0
const v3, 0x8
:cond_0
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const p0, 0x7f0d01e0
invoke-virtual {v5, p0}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v4
invoke-virtual {v4, v3}, Lcom/android/systemui/statusbar/policy/DigitalClock;->setVisibility(I)V
return-void
.end method
0x7f0d01e0 is the public id of "digitalclock_view"
"enable_digitalclock" is the key for checkbox (android:key="enable_digitalclock")
After I have insert this line in a part of method makestatusbarview:
Code:
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->digitalclock_view()V
Code:
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/4 v10, 0x0
invoke-virtual {v9, v10}, Landroid/view/View;->setAlpha(F)V
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/4 v10, 0x4
invoke-virtual {v9, v10}, Landroid/view/View;->setVisibility(I)V
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->digitalclock_view()V
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/4 v10, 0x0
invoke-virtual {v9, v10}, Landroid/view/View;->setEnabled(Z)V
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v10, 0x7f0d004f
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/StatusBarWindowView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Lcom/android/systemui/statusbar/policy/DateView;
If you have this on-fly you must have PhoneStatusBar$SettingsObserver.smali and add this line in two method:
Code:
.method observe()V
.locals 3
const/4 v2, 0x0
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v1, v1, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "enable_digitalclock"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
Code:
.method public onChange(Z)V
.locals 1
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;->digitalclock_view()V
Thanks @Goldie for his guide of smali code
Nice to see it helping
Sent from my GT-I9305 using Tapatalk
Glad you found out how. Maybe when I have time I'll give a try. If you can, show me with a screen shot what you accomplished please. May help me when I attempt this.
Sent from my Advanced SII lite

Categories

Resources