[mod][guide] miui style setting for jb 4.1.2 touchwiz - Galaxy S III Mini Themes and Apps

Hello xda'ers,
This guide is not original made by me, I just compare from @dikulbahrian MOD, and bring from original guide :
here : http://forum.xda-developers.com/showthread.php?t=2273807
and here : http://forum.xda-developers.com/showthread.php?t=2103158
so thanks to sir Adi Aisiteru Reborn and BigSplit, and my Buddy Joni Eka Saputra for tested :highfive:
just little different on smali code, so this guide should work on Stock JB 4.1.2 GT-I8190 and maybe can be adapt to any samsung JB firmware
OK Let's go to gide
FIRST
You need to Decompile your SecSettings.apk
go to res/values/ids.xml and add the following to the end (ignore some if already present)
Code:
<item type="id" name="personalized_tab">false</item>
<item type="id" name="device_tab">false</item>
<item type="id" name="app_tab">false</item>
<item type="id" name="cursor">false</item>
<item type="id" name="vPager">false</item>
<item type="id" name="linearLayout1">false</item>
<item type="id" name="international_roaming_setting">false</item>
<item type="id" name="torchlight_settings">false</item>
<item type="id" name="dmr_settings">false</item>
go to res/values/bools.xml and add the following to the end (ignore some if already present)
Code:
<bool name="config_customized_keys">false</bool>
go to res/values/strings.xml and add the following to the end (ignore some if already present)
Code:
<string name="personalized_setting">Personal</string>
<string name="device_setting">System</string>
<string name="app_setting">Applications</string>
download some resources from HERE and merged to your settings.
Recompile your Settings and decompile again
NEXT
go to smali/com/android/Settings.smali
find this method :
Code:
.method private updateHeaderList(Ljava/util/List;)V
delete all line until .end method and replace with this :
Code:
.method private updateHeaderList(Ljava/util/List;)V
.locals 8
.parameter
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Ljava/util/List",
"<",
"Landroid/preference/PreferenceActivity$Header;",
">;)V"
}
.end annotation
.prologue
const/4 v4, 0x1
const/4 v2, 0x0
.line 560
move v1, v2
.line 561
:goto_0
invoke-interface {p1}, Ljava/util/List;->size()I
move-result v0
if-ge v1, v0, :cond_2e
.line 562
invoke-interface {p1, v1}, Ljava/util/List;->get(I)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/preference/PreferenceActivity$Header;
.line 564
iget-wide v5, v0, Landroid/preference/PreferenceActivity$Header;->id:J
long-to-int v5, v5
.line 565
const v3, 0x7f0b0429
if-ne v5, v3, :cond_3
.line 566
invoke-direct {p0}, Lcom/android/settings/Settings;->needsDockSettings()Z
move-result v3
if-nez v3, :cond_0
.line 567
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
.line 825
:cond_0
:goto_1
invoke-static {}, Landroid/os/UserId;->myUserId()I
move-result v3
if-eqz v3, :cond_2c
iget-object v3, p0, Lcom/android/settings/Settings;->SETTINGS_FOR_RESTRICTED:[I
invoke-static {v3, v5}, Lcom/android/internal/util/ArrayUtils;->contains([II)Z
move-result v3
if-nez v3, :cond_2c
.line 827
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
.line 838
:cond_1
:goto_2
invoke-interface {p1, v1}, Ljava/util/List;->get(I)Ljava/lang/Object;
move-result-object v3
if-ne v3, v0, :cond_2f
.line 840
iget-object v3, p0, Lcom/android/settings/Settings;->mFirstHeader:Landroid/preference/PreferenceActivity$Header;
if-nez v3, :cond_2
invoke-static {v0}, Lcom/android/settings/Settings$HeaderAdapter;->getHeaderType(Landroid/preference/PreferenceActivity$Header;)I
move-result v3
if-eqz v3, :cond_2
.line 842
iput-object v0, p0, Lcom/android/settings/Settings;->mFirstHeader:Landroid/preference/PreferenceActivity$Header;
.line 844
:cond_2
iget-object v0, p0, Lcom/android/settings/Settings;->mHeaderIndexMap:Ljava/util/HashMap;
invoke-static {v5}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v3
invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v5
invoke-virtual {v0, v3, v5}, Ljava/util/HashMap;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
.line 845
add-int/lit8 v0, v1, 0x1
:goto_3
move v1, v0
.line 847
goto :goto_0
.line 568
:cond_3
const v3, 0x7f0b0404
if-eq v5, v3, :cond_4
const v3, 0x7f0b0414
if-ne v5, v3, :cond_5
.line 569
:cond_4
invoke-static {p0, p1, v0}, Lcom/android/settings/Utils;->updateHeaderToSpecificActivityFromMetaDataOrRemove(Landroid/content/Context;Ljava/util/List;Landroid/preference/PreferenceActivity$Header;)Z
goto :goto_1
.line 570
:cond_5
const v3, 0x7f0b03fd
if-ne v5, v3, :cond_6
.line 572
invoke-virtual {p0}, Lcom/android/settings/Settings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v3
const-string v6, "android.hardware.wifi"
invoke-virtual {v3, v6}, Landroid/content/pm/PackageManager;->hasSystemFeature(Ljava/lang/String;)Z
move-result v3
if-nez v3, :cond_0
.line 573
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto :goto_1
.line 583
:cond_6
const v3, 0x7f0b03fe
if-ne v5, v3, :cond_7
.line 586
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto :goto_1
.line 588
:cond_7
const v3, 0x7f0b03ff
if-ne v5, v3, :cond_8
.line 602
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto :goto_1
.line 604
:cond_8
const v3, 0x7f0b0402
if-ne v5, v3, :cond_a
.line 606
const-string v3, "LGT"
const-string v6, "ro.csc.sales_code"
invoke-static {v6}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v6
invoke-virtual {v3, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-eqz v3, :cond_9
invoke-static {p0}, Lcom/android/settings/Utils;->isWifiOnly(Landroid/content/Context;)Z
move-result v3
if-eqz v3, :cond_0
.line 608
:cond_9
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 610
:cond_a
const v3, 0x7f0b0403
if-ne v5, v3, :cond_b
.line 611
iput-object v0, p0, Lcom/android/settings/Settings;->mInternationalRoaming:Landroid/preference/PreferenceActivity$Header;
.line 613
const-string v3, "CTC"
const-string v6, "ro.csc.sales_code"
invoke-static {v6}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v6
invoke-virtual {v3, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-nez v3, :cond_0
.line 614
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 616
:cond_b
const v3, 0x7f0b0400
if-ne v5, v3, :cond_c
.line 618
invoke-virtual {p0}, Lcom/android/settings/Settings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v3
const-string v6, "android.hardware.bluetooth"
invoke-virtual {v3, v6}, Landroid/content/pm/PackageManager;->hasSystemFeature(Ljava/lang/String;)Z
move-result v3
if-nez v3, :cond_0
.line 619
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 621
:cond_c
const v3, 0x7f0b040d
if-ne v5, v3, :cond_d
.line 622
invoke-static {}, Lcom/sec/android/app/CscFeature;->getInstance()Lcom/sec/android/app/CscFeature;
move-result-object v3
const-string v6, "CscFeature_Setting_EnableMenuBlockCallMsg"
invoke-virtual {v3, v6}, Lcom/sec/android/app/CscFeature;->getEnableStatus(Ljava/lang/String;)Z
move-result v3
if-nez v3, :cond_0
.line 624
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 626
:cond_d
const v3, 0x7f0b0401
if-ne v5, v3, :cond_e
.line 628
const-string v3, "network_management"
invoke-static {v3}, Landroid/os/ServiceManager;->getService(Ljava/lang/String;)Landroid/os/IBinder;
move-result-object v3
invoke-static {v3}, Landroid/os/INetworkManagementService$Stub;->asInterface(Landroid/os/IBinder;)Landroid/os/INetworkManagementService;
move-result-object v3
.line 631
:try_start_0
invoke-interface {v3}, Landroid/os/INetworkManagementService;->isBandwidthControlEnabled()Z
move-result v3
if-nez v3, :cond_0
.line 632
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
:try_end_0
.catch Landroid/os/RemoteException; {:try_start_0 .. :try_end_0} :catch_0
goto/16 :goto_1
.line 634
:catch_0
move-exception v3
goto/16 :goto_1
.line 637
:cond_e
const v3, 0x7f0b0422
if-eq v5, v3, :cond_0
.line 641
const v3, 0x7f0b0423
if-ne v5, v3, :cond_f
.line 643
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 645
:cond_f
const v3, 0x7f0b0424
if-ne v5, v3, :cond_10
.line 647
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 649
:cond_10
const v3, 0x7f0b0408
if-eq v5, v3, :cond_0
.line 653
const v3, 0x7f0b0410
if-ne v5, v3, :cond_11
.line 655
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 657
:cond_11
const v3, 0x7f0b0420
if-ne v5, v3, :cond_12
.line 664
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 684
:cond_12
const v3, 0x7f0b0411
if-ne v5, v3, :cond_13
.line 686
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 688
:cond_13
const v3, 0x7f0b041f
if-ne v5, v3, :cond_14
.line 690
add-int/lit8 v1, v1, 0x1
.line 691
invoke-direct {p0, p1, v1}, Lcom/android/settings/Settings;->insertAccountsHeaders(Ljava/util/List;I)I
move-result v1
goto/16 :goto_1
.line 693
:cond_14
const v3, 0x7f0b0427
if-ne v5, v3, :cond_15
.line 695
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 697
:cond_15
const v3, 0x7f0b041b
if-ne v5, v3, :cond_16
.line 699
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 701
:cond_16
const v3, 0x7f0b0425
if-ne v5, v3, :cond_17
.line 705
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 707
:cond_17
const v3, 0x7f0b0426
if-ne v5, v3, :cond_18
.line 710
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 712
:cond_18
const v3, 0x7f0b0416
if-ne v5, v3, :cond_1a
.line 713
iget-boolean v3, p0, Lcom/android/settings/Settings;->mEnableUserManagement:Z
if-eqz v3, :cond_19
invoke-static {}, Landroid/os/UserId;->myUserId()I
move-result v3
if-nez v3, :cond_19
invoke-virtual {p0}, Lcom/android/settings/Settings;->getResources()Landroid/content/res/Resources;
move-result-object v3
const v6, 0x7f0c0007
invoke-virtual {v3, v6}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v3
if-eqz v3, :cond_19
invoke-static {}, Lcom/android/settings/Utils;->isMonkeyRunning()Z
move-result v3
if-eqz v3, :cond_0
.line 717
:cond_19
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 719
:cond_1a
const v3, 0x7f0b041d
if-ne v5, v3, :cond_1b
.line 724
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 726
:cond_1b
const v3, 0x7f0b0431
if-ne v5, v3, :cond_1c
.line 727
const-string v3, "ro.csc.sales_code"
invoke-static {v3}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v3
.line 728
const-string v6, "ro.product.model"
invoke-static {v6}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v6
.line 730
const-string v7, "SPR"
invoke-virtual {v7, v3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v7
if-nez v7, :cond_0
const-string v7, "BST"
invoke-virtual {v7, v3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-nez v3, :cond_0
const-string v3, "SCH-S960L"
invoke-virtual {v3, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-nez v3, :cond_0
.line 732
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 734
:cond_1c
const v3, 0x7f0b0430
if-ne v5, v3, :cond_1d
.line 737
:try_start_1
invoke-virtual {p0}, Lcom/android/settings/Settings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v3
const-string v6, "com.sprint.dsa"
const/4 v7, 0x0
invoke-virtual {v3, v6, v7}, Landroid/content/pm/PackageManager;->getApplicationInfo(Ljava/lang/String;I)Landroid/content/pm/ApplicationInfo;
:try_end_1
.catch Landroid/content/pm/PackageManager$NameNotFoundException; {:try_start_1 .. :try_end_1} :catch_1
move v3, v4
.line 743
:goto_4
if-nez v3, :cond_0
.line 744
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 738
:catch_1
move-exception v3
move v3, v2
.line 739
goto :goto_4
.line 746
:cond_1d
const v3, 0x7f0b040e
if-ne v5, v3, :cond_1e
.line 748
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 750
:cond_1e
const v3, 0x7f0b0415
if-ne v5, v3, :cond_20
.line 751
const-string v3, "DCM"
const-string v6, "ro.csc.sales_code"
invoke-static {v6}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v6
invoke-virtual {v3, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-nez v3, :cond_1f
.line 752
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 756
:cond_1f
:try_start_2
invoke-virtual {p0}, Lcom/android/settings/Settings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v3
const-string v6, "com.nttdocomo.android.docomoset"
const/4 v7, 0x1
invoke-virtual {v3, v6, v7}, Landroid/content/pm/PackageManager;->getPackageInfo(Ljava/lang/String;I)Landroid/content/pm/PackageInfo;
:try_end_2
.catch Landroid/content/pm/PackageManager$NameNotFoundException; {:try_start_2 .. :try_end_2} :catch_2
goto/16 :goto_1
.line 757
:catch_2
move-exception v3
.line 758
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 761
:cond_20
const v3, 0x7f0b042e
if-ne v5, v3, :cond_21
.line 763
invoke-direct {p0}, Lcom/android/settings/Settings;->isOrangeCustomer()Z
move-result v3
if-eqz v3, :cond_0
.line 764
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 766
:cond_21
const v3, 0x7f0b042f
if-ne v5, v3, :cond_22
.line 768
invoke-direct {p0}, Lcom/android/settings/Settings;->isOrangeCustomer()Z
move-result v3
if-nez v3, :cond_0
.line 769
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 771
:cond_22
const v3, 0x7f0b040a
if-ne v5, v3, :cond_23
.line 774
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 778
:cond_23
const v3, 0x7f0b041a
if-ne v5, v3, :cond_25
.line 779
invoke-virtual {p0}, Lcom/android/settings/Settings;->getResources()Landroid/content/res/Resources;
move-result-object v3
invoke-virtual {v3}, Landroid/content/res/Resources;->getConfiguration()Landroid/content/res/Configuration;
move-result-object v3
iget v3, v3, Landroid/content/res/Configuration;->keyboard:I
if-eq v3, v4, :cond_24
invoke-virtual {p0}, Lcom/android/settings/Settings;->getResources()Landroid/content/res/Resources;
move-result-object v3
const v6, 0x7f0c001e
invoke-virtual {v3, v6}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v3
if-nez v3, :cond_0
.line 780
:cond_24
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 784
:cond_25
const v3, 0x7f0b03fc
if-ne v5, v3, :cond_26
.line 785
const-string v3, "VZW"
sget-object v6, Lcom/android/settings/Settings;->sSalesCode:Ljava/lang/String;
invoke-virtual {v3, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-nez v3, :cond_0
.line 786
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 789
:cond_26
const v3, 0x7f0b03fb
if-ne v5, v3, :cond_27
.line 792
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 794
:cond_27
const v3, 0x7f0b03fa
if-ne v5, v3, :cond_28
.line 797
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 799
:cond_28
const v3, 0x7f0b0412
if-eq v5, v3, :cond_0
.line 803
const v3, 0x7f0b0406
if-ne v5, v3, :cond_29
.line 805
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 807
:cond_29
const v3, 0x7f0b0405
if-eq v5, v3, :cond_0
.line 811
const v3, 0x7f0b042a
if-ne v5, v3, :cond_2a
.line 813
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 815
:cond_2a
const v3, 0x7f0b0428
if-ne v5, v3, :cond_2b
.line 817
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 819
:cond_2b
const v3, 0x7f0b0407
if-ne v5, v3, :cond_0
.line 821
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_1
.line 828
:cond_2c
const v3, 0x7f0b042b
if-ne v5, v3, :cond_2d
.line 829
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_2
.line 830
:cond_2d
const v3, 0x7f0b0409
if-ne v5, v3, :cond_1
.line 831
const-string v3, "VZW"
sget-object v6, Lcom/android/settings/Settings;->sSalesCode:Ljava/lang/String;
invoke-virtual {v3, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-eqz v3, :cond_1
.line 833
invoke-interface {p1, v0}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
goto/16 :goto_2
.line 848
:cond_2e
return-void
:cond_2f
move v0, v1
goto/16 :goto_3
.end method
find this method :
Code:
.method protected onCreate(Landroid/os/Bundle;)V
scrool down and delete RED LINE
Code:
iget-object v0, p0, Lcom/android/settings/Settings;->mParentHeader:Landroid/preference/PreferenceActivity$Header;
iget-object v0, v0, Landroid/preference/PreferenceActivity$Header;->title:Ljava/lang/CharSequence;
new-instance v1, Lcom/android/settings/Settings$1;
invoke-direct {v1, p0}, Lcom/android/settings/Settings$1;-><init>(Lcom/android/settings/Settings;)V
invoke-virtual {p0, v0, v4, v1}, Lcom/android/settings/Settings;->setParentTitle(Ljava/lang/CharSequence;Ljava/lang/CharSequence;Landroid/view/View$OnClickListener;)V
.line 233
:cond_5
[COLOR="Red"] invoke-virtual {p0}, Lcom/android/settings/Settings;->getActionBar()Landroid/app/ActionBar;[/COLOR]
[COLOR="Red"] move-result-object v0[/COLOR]
[COLOR="Red"] const/high16 v1, 0x7f03[/COLOR]
[COLOR="Red"] invoke-virtual {v0, v1}, Landroid/app/ActionBar;->setIcon(I)V[/COLOR]
.line 237
invoke-virtual {p0}, Lcom/android/settings/Settings;->onIsMultiPane()Z
move-result v0
if-eqz v0, :cond_6
.line 238
invoke-virtual {p0}, Lcom/android/settings/Settings;->getActionBar()Landroid/app/ActionBar;
move-result-object v0
invoke-virtual {v0, v3}, Landroid/app/ActionBar;->setDisplayHomeAsUpEnabled(Z)V
.line 239
invoke-virtual {p0}, Lcom/android/settings/Settings;->getActionBar()Landroid/app/ActionBar;
move-result-object v0
invoke-virtual {v0, v3}, Landroid/app/ActionBar;->setHomeButtonEnabled(Z)V
.line 241
:cond_6
return-void
.end method
save and don't close
NEXT
for for the method that you just added (.method private updateHeaderList(Ljava/util/ListV) you will find 46 id 0x7fxxxxxx.
Compare with my public :
Code:
<public type="id" name="dock_settings" id="0x7f0b0429" />
<public type="id" name="operator_settings" id="0x7f0b0404" />
<public type="id" name="manufacturer_settings" id="0x7f0b0414" />
<public type="id" name="wifi_settings" id="0x7f0b03fd" />
<public type="id" name="wifi_ap_settings" id="0x7f0b03fe" />
<public type="id" name="wifi_sprinthotspot_settings" id="0x7f0b03ff" />
<public type="id" name="global_roaming_settings" id="0x7f0b0402" />
<public type="id" name="international_roaming_setting" id="0x7f0b0403" />
<public type="id" name="bluetooth_settings" id="0x7f0b0400" />
<public type="id" name="block_settings" id="0x7f0b040d" />
<public type="id" name="data_usage_settings" id="0x7f0b0401" />
<public type="id" name="motion_settings" id="0x7f0b0422" />
<public type="id" name="s_motion_settings" id="0x7f0b0423" />
<public type="id" name="finger_air_view_settings" id="0x7f0b0424" />
<public type="id" name="easy_mode_settings" id="0x7f0b0408" />
<public type="id" name="power_saving_mode" id="0x7f0b0410" />
<public type="id" name="bua_plus" id="0x7f0b0420" />
<public type="id" name="power_settings" id="0x7f0b0411" />
<public type="id" name="account_settings" id="0x7f0b041f" />
<public type="id" name="pen_settings_menu" id="0x7f0b0427" />
<public type="id" name="onehand_settings" id="0x7f0b041b" />
<public type="id" name="dualmode_settings" id="0x7f0b0425" />
<public type="id" name="dualSlot_settings" id="0x7f0b0426" />
<public type="id" name="user_settings" id="0x7f0b0416" />
<public type="bool" name="enable_user_management" id="0x7f0c0007" />
<public type="id" name="scloud_settings" id="0x7f0b041d" />
<public type="id" name="system_update" id="0x7f0b0431" />
<public type="id" name="activate_this_device" id="0x7f0b0430" />
<public type="id" name="customizable_key" id="0x7f0b040e" />
<public type="id" name="docomoservice_settings" id="0x7f0b0415" />
<public type="id" name="development_settings" id="0x7f0b042e" />
<public type="id" name="development_settings_orange" id="0x7f0b042f" />
<public type="id" name="simcard_management" id="0x7f0b040a" />
<public type="id" name="customizedkey_settings" id="0x7f0b041a" />
<public type="bool" name="config_customized_keys" id="0x7f0c001e" />
<public type="id" name="airplane_mode" id="0x7f0b03fc" />
<public type="id" name="home_settings" id="0x7f0b03fb" />
<public type="id" name="home_settings_category" id="0x7f0b03fa" />
<public type="id" name="battery_settings" id="0x7f0b0412" />
<public type="id" name="header_nearby_settings" id="0x7f0b0406" />
<public type="id" name="wireless_settings" id="0x7f0b0405" />
<public type="id" name="hdmi_settings" id="0x7f0b042a" />
<public type="id" name="torchlight_settings" id="0x7f0b0428" />
<public type="id" name="dmr_settings" id="0x7f0b0407" />
<public type="id" name="usb_settings" id="0x7f0b042b" />
<public type="id" name="dormant_mode" id="0x7f0b0409" />
go to smali/com/android/settings/MainSetting.smali
open your public.xml and replace id on MainSettings.smali with your id public
Code:
Line 98: const v3, 0x7f0b0445 <public type="id" name=""
Line 182: const v0, 0x7f0b0442 <public type="id" name="personalized_tab"
Line 193: const v0, 0x7f0b0443 <public type="id" name="device_tab"
Line 204: const v0, 0x7f0b0444 <public type="id" name="app_tab"
Line 263: const v0, 0x7f0b0446 <public type="id" name="vPager"
Line 466: const v0, 0x7f040143 <public type="layout" name="mainsetting"
eg : replace 0x7f0b0445 with <public type="id" name="cursor" id="0x7fxxxxxx" />

NEXT
go to smali/com/android/settings/
Copy in any place :
Settings.smali
Settings$1.smali
Settings$2.smali
Settings$HeaderAdapter$HeaderViewHolder.smali
Settings$HeaderAdapter.smali
rename to :
AppSettings.smali
AppSettings$1.smali
AppSettings$2.smali
AppSettings$HeaderAdapter$HeaderViewHolder.smali
AppSettings$HeaderAdapter.smali
again Copy :
Settings.smali
Settings$1.smali
Settings$2.smali
Settings$HeaderAdapter$HeaderViewHolder.smali
Settings$HeaderAdapter.smali
rename to :
DeviceSettings.smali
DeviceSettings$1.smali
DeviceSettings$2.smali
DeviceSettings$HeaderAdapter$HeaderViewHolder.smal i
DeviceSettings$HeaderAdapter.smali
again Copy :
Settings.smali
Settings$1.smali
Settings$2.smali
Settings$HeaderAdapter$HeaderViewHolder.smali
Settings$HeaderAdapter.smali
rename to :
PersonalSettings.smali
PersonalSettings$1.smali
PersonalSettings$2.smali
PersonalSettings$HeaderAdapter$HeaderViewHolder.sm ali
PersonalSettings$HeaderAdapter.smali
NOTE : if your settings have Settings$3.smali, you need too copy these and rename to AppSettings$3.smali, DeviceSettings$3.smali, and PersonalSettings$3.smali
Open :
AppSettings.smali
AppSettings$1.smali
AppSettings$2.smali
AppSettings$HeaderAdapter$HeaderViewHolder.smali
AppSettings$HeaderAdapter.smali
edit all lines in that all smali from :
if the line is, Lcom/android/settings/Settings edit it to become Lcom/android/settings/AppSettings
if the line is, Lcom/android/settings/Settings$1 edit it to become Lcom/android/settings/AppSettings$1
if the line is, Lcom/android/settings/Settings$2 edit it to become Lcom/android/settings/AppSettings$2
if the line is, Lcom/android/settings/Settings$HeaderAdapter$HeaderViewHolder edit it to become Lcom/android/settings/AppSettings$HeaderAdapter$HeaderViewHolder
if the line is, Lcom/android/settings/Settings$HeaderAdapter edit it to become Lcom/android/settings/AppSettings$HeaderAdapter
and so is edit all lines in
DeviceSettings.smali
DeviceSettings$1.smali
DeviceSettings$2.smali
DeviceSettings$HeaderAdapter$HeaderViewHolder.smal i
DeviceSettings$HeaderAdapter.smali
if the line is, Lcom/android/settings/Settings edit it to become Lcom/android/settings/DeviceSettings
if the line is, Lcom/android/settings/Settings$1 edit it to become Lcom/android/settings/DeviceSettings$1
if the line is, Lcom/android/settings/Settings$2 edit it to become Lcom/android/settings/DeviceSettings$2
if the line is, Lcom/android/settings/Settings$HeaderAdapter$HeaderViewHolder edit it to become Lcom/android/settings/DeviceSettings$HeaderAdapter$HeaderViewHolder
if the line is, Lcom/android/settings/Settings$HeaderAdapter edit it to become Lcom/android/settings/DeviceSettings$HeaderAdapter
and so is edit all lines in
PersonalSettings.smali
PersonalSettings$1.smali
PersonalSettings$2.smali
PersonalSettings$HeaderAdapter$HeaderViewHolder.sm ali
PersonalSettings$HeaderAdapter.smali
if the line is, Lcom/android/settings/Settings edit it to become Lcom/android/settings/PersonalSettings
if the line is, Lcom/android/settings/Settings$1 edit it to become Lcom/android/settings/PersonalSettings$1
if the line is, Lcom/android/settings/Settings$2 edit it to become Lcom/android/settings/PersonalSettings$2
if the line is, Lcom/android/settings/Settings$HeaderAdapter$HeaderViewHolder edit it to become Lcom/android/settings/PersonalSettings$HeaderAdapter$HeaderViewHolder
if the line is, Lcom/android/settings/Settings$HeaderAdapter edit it to become Lcom/android/settings/PersonalSettings$HeaderAdapter
NOTE : there is an exception of editing all line, that you must not edit or not allowed to edit All lines on annotation section
Code:
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
.............
..............
}
.end annotation
NEXT
Search : <public type="xml" name="settings_headers" id="0x????????" />
and search this id on AppSettings.smali, DeviceSettings.smali, PersonalSettings.smali
Code:
in PersonalSettings.smali -> replace with <public type="xml" name="personal_settings_headers" id="0x????????" />
in DeviceSettings.smali -> replace with <public type="xml" name="device_settings_headers" id="0x????????" />
in AppSettings.smali -> replace with <public type="xml" name="app_settings_headers" id="0x????????" />
open AndroidManifest.xml
find similiar line like this :
Code:
<activity android:label="@string/settings_label_launcher" android:name="Settings" android:taskAffinity="com.android.settings" android:launchMode="singleTask" android:configChanges="keyboardHidden|orientation|screenSize">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<action android:name="android.settings.SETTINGS" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
and replace with this :
Code:
<activity android:theme="@*android:style/Theme.NoTitleBar" android:name="MainSetting" android:taskAffinity="com.android.settings" android:launchMode="singleTask">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<action android:name="android.settings.SETTINGS" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:label="@string/settings_label_launcher" android:name="PersonalSettings" android:taskAffinity="com.android.settings" android:launchMode="singleTask">
<intent-filter>
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity android:label="@string/settings_label_launcher" android:name="DeviceSettings" android:taskAffinity="com.android.settings" android:launchMode="singleTask">
<intent-filter>
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity android:label="@string/settings_label_launcher" android:name="AppSettings" android:taskAffinity="com.android.settings" android:launchMode="singleTask">
<intent-filter>
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity android:label="@string/settings_label_launcher" android:name="Settings" android:taskAffinity="com.android.settings" android:launchMode="singleTask">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
Recompile, Sign, Push to Your Device, It should work with blank tab

NEXT
go to res/xml and open app_settings_headers.xml, device_settings_headers.xml, personal_settings_headers.xml
copy this code and replace to your 3 xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<preference-headers
xmlns:android="http://schemas.android.com/apk/res/android">
</preference-headers>
open your settings_header.xml from res/xml folder, place code to 3 xml wherever you want
for reference you can see this post
http://forum.xda-developers.com/showpost.php?p=55932748&postcount=3

Screenshoot for example

It doesn't work. I didn't even add anything to App, Device and PersonalSettings.xml yet
Code:
10-23 17:02:46.244 2855 2855 E MenuItemImpl: android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.settings.SETTINGS }
10-23 17:02:50.949 2910 22303 E Drive.UninstallOperation: Package still installed com.android.settings
10-23 17:04:17.453 23088 23384 E copresGcore: Couldn't load settings: /data/data/com.google.android.gms/files/copresence_settings: open failed: ENOENT (No such file or directory)
10-23 17:04:36.912 22804 22804 E AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.MainSetting}: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:36.912 22804 22804 E AndroidRuntime: Caused by: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:36.912 22804 22804 E AndroidRuntime: at com.android.settings.MainSetting.InitViewPager(MainSetting.java:114)
10-23 17:04:36.912 22804 22804 E AndroidRuntime: at com.android.settings.MainSetting.onCreate(MainSetting.java:52)
10-23 17:04:36.912 22804 22804 E AndroidRuntime: at com.android.settings.PersonalSettings.onCreate(Settings.java:239)
10-23 17:04:47.542 22589 22623 E ActivityManager: App already has crash dialog: ProcessRecord{41ff1f50 22804:com.android.settings/1000}
10-23 17:04:59.343 24214 24214 E AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.MainSetting}: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:59.343 24214 24214 E AndroidRuntime: Caused by: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:59.343 24214 24214 E AndroidRuntime: at com.android.settings.MainSetting.InitViewPager(MainSetting.java:114)
10-23 17:04:59.343 24214 24214 E AndroidRuntime: at com.android.settings.MainSetting.onCreate(MainSetting.java:52)
10-23 17:04:59.343 24214 24214 E AndroidRuntime: at com.android.settings.PersonalSettings.onCreate(Settings.java:239)
10-23 17:05:06.785 22589 22623 E ActivityManager: App already has crash dialog: ProcessRecord{42328018 24214:com.android.settings/1000}

Sami Kabir said:
It doesn't work. I didn't even add anything to App, Device and PersonalSettings.xml yet
Code:
10-23 17:02:46.244 2855 2855 E MenuItemImpl: android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.settings.SETTINGS }
10-23 17:02:50.949 2910 22303 E Drive.UninstallOperation: Package still installed com.android.settings
10-23 17:04:17.453 23088 23384 E copresGcore: Couldn't load settings: /data/data/com.google.android.gms/files/copresence_settings: open failed: ENOENT (No such file or directory)
10-23 17:04:36.912 22804 22804 E AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.MainSetting}: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:36.912 22804 22804 E AndroidRuntime: Caused by: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:36.912 22804 22804 E AndroidRuntime: at com.android.settings.MainSetting.InitViewPager(MainSetting.java:114)
10-23 17:04:36.912 22804 22804 E AndroidRuntime: at com.android.settings.MainSetting.onCreate(MainSetting.java:52)
10-23 17:04:36.912 22804 22804 E AndroidRuntime: at com.android.settings.PersonalSettings.onCreate(Settings.java:239)
10-23 17:04:47.542 22589 22623 E ActivityManager: App already has crash dialog: ProcessRecord{41ff1f50 22804:com.android.settings/1000}
10-23 17:04:59.343 24214 24214 E AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.MainSetting}: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:59.343 24214 24214 E AndroidRuntime: Caused by: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.settings/com.android.settings.PersonalSettings}: java.lang.NullPointerException
10-23 17:04:59.343 24214 24214 E AndroidRuntime: at com.android.settings.MainSetting.InitViewPager(MainSetting.java:114)
10-23 17:04:59.343 24214 24214 E AndroidRuntime: at com.android.settings.MainSetting.onCreate(MainSetting.java:52)
10-23 17:04:59.343 24214 24214 E AndroidRuntime: at com.android.settings.PersonalSettings.onCreate(Settings.java:239)
10-23 17:05:06.785 22589 22623 E ActivityManager: App already has crash dialog: ProcessRecord{42328018 24214:com.android.settings/1000}
Click to expand...
Click to collapse
What tools do you use?
I recomended use apk multitool sir

syaeful said:
What tools do you use?
I recomended use apk multitool sir
Click to expand...
Click to collapse
I use APKTOOL for all my works and I use this tool for signing my edited apps. I don't think this is causing the problem, it has something to do with my smali files. If only I was good in smali editing and logcat reading, I too could successfully use MIUI style or S4 style Settings app on my phone
Anyways, thanks for the guide and for your reply.

Sami Kabir said:
I use APKTOOL for all my works and I use this tool for signing my edited apps. I don't think this is causing the problem, it has something to do with my smali files. If only I was good in smali editing and logcat reading, I too could successfully use MIUI style or S4 style Settings app on my phone
Anyways, thanks for the guide and for your reply.
Click to expand...
Click to collapse
maybe you can use mainsettings.smali from sir Adi Aisiteru from here sir : http://forum.xda-developers.com/showthread.php?t=2273807

Help me when I push new SecSettings.apk in the system and reboot my phone settings is gone.

Help me i am with VirginityV14

Related

[MOD][HOW-TO]Real Time Clock and Statusbar Colors (Clock Statusbar Mod 3.0){06-01-13}

This is an expansion on Didact's mods, so if you haven't already, you MUST implement his clock mod found here:
[MOD][GUIDE] Clock Statusbar Mod v2.0
It would help, but is not necessary to implement Didact's statusbar transparency mod found here:
[MOD][GUIDE] Real Time Statusbar Transparency Settings
I used the open source ColorPickerPreference found HERE
Note:
While you're going through SecSettings, you can remove everything involving statusbar transparency as the new mod has a color picker with an alpha (transparency) bar.
I've added the necessary code if you haven't implemented the transparency setting. It's only code in SystemUI.apk, so you don't need to change anything in SecSettings.apk.
What do these mods cover?
Added Left Clock
Fixed overlapping notifications on Center Clock
Change the color of the clock no matter the location
Change the color of the statusbar (transparency still works!)
We're going to be working with the following two files:
SecSettings.apk
SystemUI.apk
KEY
REMOVE what's in BLUE
ADD what's in RED
MODIFY what's in GREEN
Updates:
6-01-13
Updated ColorPicker so it keeps your color instead of reverting it when you leave and come back to the menu.
Moved all clock stuff to Display Settings to make it easier to change clock and statusbar color together.
You can revert your date_time_prefs.xml and DateTimeSettings.smali
Fixed issues with center/left clock causing the device/SystemUI to freeze when screen is turned off.
4-15-13
I've now added a ColorPicker so you can set any color/transparency you want!
Added code if you haven't implemented Didact's transparency mod.
First up, SecSettings.apk
Navigate to /res/values/arrays.xml
Code:
<string-array name="clock_style_entries">
<item>Right clock</item>
<item>Center clock</item>[COLOR="Red"]
<item>Left clock</item>[/COLOR]
<item>No clock</item>
</string-array>
<string-array name="clock_style_values">
<item>1</item>
<item>2</item>[COLOR="red"]
<item>3</item>[/COLOR]
<item>0</item>
</string-array>
Navigate to /res/values/ids.xml
Code:
[COLOR="Red"]<item type="id" name="color_picker_view">false</item>
<item type="id" name="old_color_panel">false</item>
<item type="id" name="new_color_panel">false</item>[/COLOR]
Next navigate to /res/values/strings.xml
Code:
[COLOR="red"]<string name="clock_cat">Clock options</string>
<string name="clock_color_title">Clock Color</string>
<string name="clock_color_summary">Change the color of the clock</string>
<string name="statusbar_color_title">Statusbar Color</string>
<string name="statusbar_color_summary">Change the color of the statusbar</string>
<string name="dialog_color_picker">Color Picker</string>
<string name="press_color_to_apply">Press on Color to apply</string>[/COLOR]
Navigate to /res/xml/display_settings.xml
Add the following wherever you would like it to show up in the menu
Code:
<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" />
<PreferenceCategory android:title="@string/clock_cat" android:key="clock_category" />
<ListPreference android:entries="@array/clock_style_entries" android:title="@string/clock_title_enable" android:key="clock_style" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/clock_style_values" />
<ListPreference android:entries="@array/clock_ampm_entries" android:title="@string/title_clock_ampm_entries" android:key="clock_am_pm_style" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/clock_ampm_values" />
<ListPreference android:entries="@array/clock_weekday_entries" android:title="@string/enable_clock_weekday" android:key="clock_weekday" android:summary="@string/enable_clock_weekday_summary" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/clock_weekday_values" />
<com.loser.colorpicker.ColorPickerPreference android:persistent="false" android:title="@string/clock_color_title" android:key="clock_color" android:summary="@string/clock_color_summary" android:defaultValue="0xffffffff" alphaSlider="true" />
Navigate to /smali/com/android/settings/DisplaySettings.smali
Code:
.field private mBrightnessPreference:Lcom/android/settings/BrightnessPreference;
.field private mBrightnessSliderPreference:Landroid/preference/CheckBoxPreference;
[COLOR="Red"].field mClockAmPmstyle:Landroid/preference/ListPreference;
.field mClockColor:Lcom/loser/colorpicker/ColorPickerPreference;
.field mClockStyle:Landroid/preference/ListPreference;
.field mClockWeekday:Landroid/preference/ListPreference;[/COLOR]
.field private mContextualPage:Landroid/preference/SwitchPreferenceScreen;
.field protected mContextualPageUncheckerHandler:Landroid/os/Handler;
Code:
.field private mSmartRotationAnimationImage:[I
.field private mSmartStayAnimationImage:[I
[COLOR="red"].field mStatusbarColor:Lcom/loser/colorpicker/ColorPickerPreference;[/COLOR]
.field mSupportFolderType:Z
.field private mTouchKeyLight:Landroid/preference/ListPreference;
.method private updateState()V
There's two sections here, make sure you scroll to the bottom.
Code:
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mDisplayBatteryLevel:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v4, "display_battery_percentage"
invoke-static {v0, v4, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
if-eqz v0, :cond_4
move v0, v1
:goto_1
invoke-virtual {v3, v0}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
[COLOR="red"]iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mStatusbarColor:Lcom/loser/colorpicker/ColorPickerPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "statusbar_color"
const v5, -0xffffff
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/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v3
const/16 v5, 0x0
invoke-virtual {v0, v5, v3}, Lcom/loser/colorpicker/ColorPickerPreference;->onSetInitialValue(ZLjava/lang/Object;)V
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mClockColor:Lcom/loser/colorpicker/ColorPickerPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "clock_color"
const v5, -0x000000
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/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v3
const/16 v5, 0x0
invoke-virtual {v0, v5, v3}, Lcom/loser/colorpicker/ColorPickerPreference;->onSetInitialValue(ZLjava/lang/Object;)V[/COLOR]
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;->mClockStyle:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "clock_style"
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;->mClockAmPmstyle:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "clock_am_pm_style"
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;->mClockWeekday:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "clock_weekday"
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[/COLOR]
.line 809
iget-boolean v0, p0, Lcom/android/settings/DisplaySettings;->mSupportFolderType:Z
if-eqz v0, :cond_0
.line 854
invoke-direct {p0}, Lcom/android/settings/DisplaySettings;->updateAccelerometerRotationSecondCheckbox()V
.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 409
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, "statusbar_color"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Lcom/loser/colorpicker/ColorPickerPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mStatusbarColor:Lcom/loser/colorpicker/ColorPickerPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mStatusbarColor:Lcom/loser/colorpicker/ColorPickerPreference;
const-string v11, "clock_color"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Lcom/loser/colorpicker/ColorPickerPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mClockColor:Lcom/loser/colorpicker/ColorPickerPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mClockColor:Lcom/loser/colorpicker/ColorPickerPreference;
invoke-virtual {v11, p0}, Lcom/loser/colorpicker/ColorPickerPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "clock_style"
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;->mClockStyle:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mClockStyle:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "clock_am_pm_style"
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;->mClockAmPmstyle:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mClockAmPmstyle:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "clock_weekday"
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;->mClockWeekday:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mClockWeekday: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
.method public onPreferenceChange(Landroid/preference/Preference;Ljava/lang/ObjectZ
Code:
:catch_2
move-exception v0
.line 1038
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 1040
:cond_9
[COLOR="red"]const-string v2, "statusbar_color"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_stat
invoke-static {p2}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
move-result-object v2
const-string v1, "^#"
const-string v3, ""
invoke-virtual {v2, v1, v3}, Ljava/lang/String;->replaceFirst(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
move-result-object v3
invoke-static {v3}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I
move-result v1
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v2
const-string v3, "statusbar_color"
invoke-static {v2, v3, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_4
:cond_stat
const-string v2, "clock_am_pm_style"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_ampm
.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, "clock_am_pm_style"
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;->mClockAmPmstyle: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;->mClockAmPmstyle:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mClockAmPmstyle: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_ampm
const-string v2, "clock_style"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_style
.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, "clock_style"
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;->mClockStyle: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;->mClockStyle:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mClockStyle: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_style
const-string v2, "clock_weekday"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_week
.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, "clock_weekday"
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;->mClockWeekday: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;->mClockWeekday:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mClockWeekday: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_week
const-string v2, "clock_color"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_color
invoke-static {p2}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
move-result-object v2
const-string v1, "^#"
const-string v3, ""
invoke-virtual {v2, v1, v3}, Ljava/lang/String;->replaceFirst(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
move-result-object v3
invoke-static {v3}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I
move-result v1
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v2
const-string v3, "clock_color"
invoke-static {v2, v3, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_4
:cond_color[/COLOR]
const-string v2, "quick_launch"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
Now download the zip attached to this post and copy the smali and res folders. It should merge but not overwrite anything.
Now you're going to need to get some ids!!! Compile and then decompile.
Open /smali/com/loser/colorpicker/ColorPickerDialog.smali
There should be a total of 6 id's you need to get. Make sure you're looking at the type as there's a layout and string with the same name.
Look for them in /res/values/public.xml. You should now be good to go.
Now for SystemUI.apk
Navigate to /res/layout/tw_status_bar.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:orientation="vertical" android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
<ImageView android:id="@id/notification_lights_out" android:paddingLeft="6.0dip" android:paddingBottom="2.0dip" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/ic_sysbar_lights_out_dot_small" android:scaleType="center" />
[COLOR="SeaGreen"]<RelativeLayout android:id="@id/icons" android:paddingLeft="0.0dip" android:paddingRight="2.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">[/COLOR]
[COLOR="Red"]<com.android.systemui.statusbar.policy.ClockLeft android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ff9a9a9a" android:ellipsize="none" android:gravity="left|center" android:id="@id/left_clock" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:includeFontPadding="false" android:layout_alignParentLeft="true" />[/COLOR]
[COLOR="SeaGreen"]<LinearLayout android:orientation="horizontal" android:id="@id/left_icons" android:paddingLeft="4.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_toLeftOf="@id/center_clock" android:layout_toRightOf="@id/left_clock" android:layout_alignWithParentIfMissing="true">[/COLOR]
<TextView android:textSize="15.0dip" android:gravity="center_vertical" android:id="@id/carrierLabel" android:visibility="visible" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
<ImageView android:id="@id/operatorLogoIcon" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/tw_stat_notify_operator_logo" />
<ImageView android:id="@id/doNotDisturbIcon" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/tw_dnd" android:alpha="0.7" android:scaleX="0.85" android:scaleY="0.85" />
<com.android.systemui.statusbar.StatusBarIconView android:id="@id/moreIcon" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/stat_notify_more" />
<com.android.systemui.statusbar.phone.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_alignParentLeft="true" />
</LinearLayout>
[COLOR="Red"]<com.android.systemui.statusbar.policy.ClockCenter android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ff9a9a9a" android:ellipsize="none" android:gravity="left|center" android:id="@id/center_clock" android:paddingLeft="3.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:layout_centerInParent="true" />[/COLOR]
<LinearLayout android:orientation="horizontal" android:id="@id/right_icons" android:paddingRight="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_alignParentRight="true">
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/statusIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<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/tw_signal_cluster_view" />
<include android:id="@id/battery_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/battery_cluster_view" />
<TextView android:textSize="18.0dip" android:textColor="#ff9a9a9a" android:layout_gravity="center" android:id="@id/battery_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_network_name_separator" />
<ImageView android:gravity="center" android:id="@id/battery" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
<com.android.systemui.statusbar.policy.Clock android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ff9a9a9a" android:ellipsize="none" android:gravity="left|center" android:id="@id/clock" android:paddingLeft="3.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:includeFontPadding="false" />
</LinearLayout>
[COLOR="SeaGreen"]</RelativeLayout>[/COLOR]
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginRight="4.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
</ImageSwitcher>
<com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_old" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_new" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.phone.TickerView>
</LinearLayout>
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
Navigate to /red/values/ids.xml
Remove the line in blue and add the line in red:
Code:
[COLOR="Blue"]<item type="id" name="center_clock_layout">false</item>[/COLOR]
[COLOR="Red"]<item type="id" name="left_clock">false</item>[/COLOR]
STOP!!!!
STOP!!!!
We need to grab some IDs before we continue.
Try to compile. If it fails, try adding in the blue line from the step above (center_clock_layout).
Now decompile again and navigate to /res/values/public.xml.
Search for the following three ID's:
(Make sure you're getting the ones with type="id")
Code:
clock
center_clock
left_clock
Now copy the id's somewhere.
Ok, let's continue...
Navigate to /smali/com/android/systemui/statusbar/phone/PhoneStatusBar.smali
Code:
.field private mCarrierLabelHeight:I
.field private mCarrierLabelVisible:Z
[COLOR="Blue"]
.field mCenterClockLayout:Landroid/widget/LinearLayout;
[/COLOR]
.field mChoreographer:Landroid/view/Choreographer;
.field mClearButton:Landroid/view/View;
method makeStatusBarView:
Code:
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d0035
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Landroid/widget/LinearLayout;
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIcons:Landroid/widget/LinearLayout;
[COLOR="blue"]iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d0121
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
check-cast v9, Landroid/widget/LinearLayout;
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;[/COLOR]
.line 622
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d003e
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
method showClock
REPLACE THE ENTIRE METHOD WITH THIS:
Code:
.method public showClock(Z)V
.locals 11
.parameter "show"
.prologue
const/16 v8, 0x8
const/4 v7, 0x0
const/4 v6, 0x1
.line 146
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
if-nez v9, :cond_1
.line 165
:cond_0
:goto_0
return-void
.line 147
:cond_1
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d003f # "clock"
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v2
.line 148
.local v2, clock:Landroid/view/View;
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d0124 # "center_clock"
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v0
.line 149
.local v0, cclock:Landroid/view/View;
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d0123 # "left_clock"
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v3
.line 150
.local v3, lclock:Landroid/view/View;
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v9}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v9
const-string v10, "clock_style"
invoke-static {v9, v10, v6}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v9
if-ne v9, v6, :cond_4
move v5, v6
.line 152
.local v5, rightClock:Z
:goto_1
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v9}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v9
const-string v10, "clock_style"
invoke-static {v9, v10, v6}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v9
.line 153
const/4 v10, 0x2
.line 152
if-ne v9, v10, :cond_5
move v1, v6
.line 154
.local v1, centerClock:Z
:goto_2
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v9}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v9
const-string v10, "clock_style"
invoke-static {v9, v10, v6}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v9
.line 155
const/4 v10, 0x3
.line 154
if-ne v9, v10, :cond_6
move v4, v6
.line 156
.local v4, leftClock:Z
:goto_3
if-eqz v5, :cond_2
if-eqz v2, :cond_2
.line 157
if-eqz p1, :cond_7
move v6, v7
:goto_4
invoke-virtual {v2, v6}, Landroid/view/View;->setVisibility(I)V
.line 159
:cond_2
if-eqz v1, :cond_3
if-eqz v0, :cond_3
.line 160
if-eqz p1, :cond_8
move v6, v7
:goto_5
invoke-virtual {v0, v6}, Landroid/view/View;->setVisibility(I)V
.line 162
:cond_3
if-eqz v4, :cond_0
if-eqz v3, :cond_0
.line 163
if-eqz p1, :cond_9
:goto_6
invoke-virtual {v3, v7}, Landroid/view/View;->setVisibility(I)V
goto :goto_0
.end local v1 #centerClock:Z
.end local v4 #leftClock:Z
.end local v5 #rightClock:Z
:cond_4
move v5, v7
.line 150
goto :goto_1
.restart local v5 #rightClock:Z
:cond_5
move v1, v7
.line 152
goto :goto_2
.restart local v1 #centerClock:Z
:cond_6
move v4, v7
.line 154
goto :goto_3
.restart local v4 #leftClock:Z
:cond_7
move v6, v8
.line 157
goto :goto_4
.line 160
:cond_8
const/4 v6, 0x4
goto :goto_5
:cond_9
move v7, v8
.line 163
goto :goto_6
.end method
WAIT!!!
WAIT!!!
Remeber those id's you grabbed earlier? Here's where we put them. Look through the method you just added and replace the id's with the ones you copied!
Now search for
Code:
mIcons:Landroid/widget/LinearLayout;
and replace every instance with
Code:
mIcons:Landroid/widget/RelativeLayout;
method makeStatusBarView
Code:
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationIcons:Lcom/android/systemui/statusbar/phone/IconMerger;
iget-object v10, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mMoreIcon:Landroid/view/View;
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/IconMerger;->setOverflowIndicator(Landroid/view/View;)V
.line 621
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d0035
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
[COLOR="red"]check-cast v9, Landroid/widget/RelativeLayout;[/COLOR]
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIcons:Landroid/widget/RelativeLayout;
.line 622
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v10, 0x7f0d003e
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v9
Navigate to /smali/com/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker.smali
Now search for
Code:
mIcons:Landroid/widget/LinearLayout;
and replace every instance with
Code:
mIcons:Landroid/widget/RelativeLayout;
Navigate to /smali/com/android/systemui/statusbar/phone/PhoneStatusBarView.smali
Search for
Code:
leftIconsControl:Landroid/widget/LinearLayout$LayoutParams;
and replace every instance with
Code:
leftIconsControl:Landroid/widget/RelativeLayout$LayoutParams;
Do the same thing and replace
Code:
rightIconsControl:Landroid/widget/LinearLayout$LayoutParams;
with
Code:
rightIconsControl:Landroid/widget/RelativeLayout$LayoutParams;
One last one. Replace
Code:
check-cast v0, Landroid/widget/LinearLayout$LayoutParams;
with
Code:
check-cast v0, Landroid/widget/RelativeLayout$LayoutParams;
Navigate to /smali/com/android/systemui/statusbar/BaseStatusBar.smali
If you haven't implemented the trancparency mod, place the following method after ".method public setMaxBrightness(I)V"
method setStatusBarParams
REPLACE THE ENTIRE METHOD WITH THIS:
Code:
.method protected setStatusBarParams(Landroid/view/View;)V
.locals 4
iget-object v1, p0, Lcom/android/systemui/statusbar/BaseStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const-string v2, "statusbar_color"
const/high16 v3, -0x100
invoke-static {v1, v2, v3}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
invoke-virtual {p1, v0}, Landroid/view/View;->setBackgroundColor(I)V
return-void
.end method
Now download the zip attached to this post and copy the smali folder, overwriting if it asks.
If you haven't implemented the transparency mod, You only need to add a couple things.
Navigate to /smali/com/android/systemui/statusbar/phone/PhoneStatusbar.smali
Code:
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$BrightnessEnableObserver;,
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$BatteryTextObserver;,
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FastColorDrawable;,
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;,
[COLOR="Red"]Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;,[/COLOR]
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$NotificationClicker;,
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$H;,
Lcom/android/systemui/statusbar/phone/PhoneStatusBar$ExpandedDialog;
Code:
.method static synthetic access$3400(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
.locals 1
invoke-direct {p0, p1, p2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v0
return-object v0
.end method
[COLOR="Red"].method static synthetic access$3401(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/view/View;)V
.locals 0
invoke-virtual {p0, p1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setStatusBarParams(Landroid/view/View;)V
return-void
.end method[/COLOR]
.method static synthetic access$3500(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.locals 0
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->playTraySound()V
return-void
.end method
method updateResources
Code:
invoke-virtual {v0, v3}, Landroid/content/Context;->getText(I)Ljava/lang/CharSequence;
move-result-object v3
invoke-virtual {v2, v3}, Landroid/view/View;->setContentDescription(Ljava/lang/CharSequence;)V
invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadDimens()V
[COLOR="Red"]iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
invoke-virtual {p0, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setStatusBarParams(Landroid/view/View;)V[/COLOR]
return-void
.end method
method makeStatusBarView
Code:
invoke-virtual {v9, v10}, Lcom/android/systemui/statusbar/policy/NotificationRowLayout;->setLongPressListener(Landroid/view/View$OnLongClickListener;)V
iget-object v9, p0, Lcom/android/systemui/statusbar/BaseStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
iput-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedContents:Landroid/view/View;
[COLOR="Red"]new-instance v9, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;
new-instance v10, Landroid/os/Handler;
invoke-direct {v10}, Landroid/os/Handler;-><init>()V
invoke-direct {v9, p0, v10}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/os/Handler;)V
invoke-virtual {v9}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;->observe()V[/COLOR]
goto/16 :goto_5
:cond_f
const/16 v9, 0x8
goto/16 :goto_6
method public start()V
Code:
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mWindowManager:Landroid/view/IWindowManager;
invoke-super {p0}, Lcom/android/systemui/statusbar/BaseStatusBar;->start()V
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->addNavigationBar()V
[COLOR="red"]new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHandler:Lcom/android/systemui/statusbar/BaseStatusBar$H;
invoke-direct {v0, p0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/os/Handler;)V
invoke-virtual {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;->observe()V[/COLOR]
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;
iget-object v1, p0, Lcom/android/systemui/SystemUI;->mContext:Landroid/content/Context;
invoke-direct {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;-><init>(Landroid/content/Context;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIconPolicy:Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;
return-void
.end method
Awesome. Thanks!
I assume this is for 4.1.1?
upndwn4par said:
Awesome. Thanks!
I assume this is for 4.1.1?
Click to expand...
Click to collapse
It's pretty involved, but let me know how it goes for you. I may have missed something. It should work for 4.1.2 but it's built from 4.1.1
loserskater said:
Now download the zip attached to this post and place the files in the following folders:
Code:
ClockLeft.smali /smali/com/android/systemui/statusbar/policy/
PhoneStatusBar$MyTicker.smali /smali/com/android/systemui/statusbar/phone/
[/hide]
Click to expand...
Click to collapse
I hated editing MyTicker.smali lol
Good work on these MODs dude. We should bounce ideas off each other from time to time. Hit me up on Gtalk...sent you a PM.
Didact74 said:
I hated editing MyTicker.smali lol
Good work on these MODs dude. We should bounce ideas off each other from time to time. Hit me up on Gtalk...sent you a PM.
Click to expand...
Click to collapse
That was a good idea though. Getting the center clock centered between the two sets of icons was a pain, so I can see just having it overlap being much easier.
I don't really get how I'm supposed to do this? I have the Intergalactic ROM and I go to download the Clock Statusbar Mod 2.0 and there is a "multimod" which has all the features. So I downloaded that and I go to SecSettings.apk and there is not even a /res/values folder? Can you make a flashable zip or something that works with your ROM?
geoldr said:
I don't really get how I'm supposed to do this? I have the Intergalactic ROM and I go to download the Clock Statusbar Mod 2.0 and there is a "multimod" which has all the features. So I downloaded that and I go to SecSettings.apk and there is not even a /res/values folder? Can you make a flashable zip or something that works with your ROM?
Click to expand...
Click to collapse
I'm working on something similar for the next version of Intergalactic. It's a different method of doing things than this, but you'll be able to change the status bar to any hex value or transparency that you want using a popup color changer apk.
Thanks for yours and Didact's work, loser.
Sent from my SAMSUNG-SGH-I747 using xda premium
Oh by the way, your code is a real jokester and a tease...but then it reassures me with a wink. Lol
Sent from my SAMSUNG-SGH-I747 using xda premium
I think I'm missing something... but where are the attached files?
Code:
ClockLeft.smali /smali/com/android/systemui/statusbar/policy/
PhoneStatusBar$MyTicker.smali /smali/com/android/systemui/statusbar/phone/
stratatak7 said:
I'm working on something similar for the next version of Intergalactic. It's a different method of doing things than this, but you'll be able to change the status bar to any hex value or transparency that you want using a popup color changer apk.
Thanks for yours and Didact's work, loser.
Sent from my SAMSUNG-SGH-I747 using xda premium
Click to expand...
Click to collapse
Sounds good. But can you also implement center clock? I think that and battery icons are essential.
Thanks man
geoldr said:
Sounds good. But can you also implement center clock? I think that and battery icons are essential.
Thanks man
Click to expand...
Click to collapse
Everything will be customizable. Don't worry.
Sent from my SAMSUNG-SGH-I747 using xda premium
Too much work involved
stratatak7 said:
I'm working on something similar for the next version of Intergalactic. It's a different method of doing things than this, but you'll be able to change the status bar to any hex value or transparency that you want using a popup color changer apk.
Thanks for yours and Didact's work, loser.
Sent from my SAMSUNG-SGH-I747 using xda premium
Click to expand...
Click to collapse
I was going to go that route, but wanted to get this done first. Sharing that color changer apk would be awesome!
Kryten2k35 said:
I think I'm missing something... but where are the attached files?
Code:
ClockLeft.smali /smali/com/android/systemui/statusbar/policy/
PhoneStatusBar$MyTicker.smali /smali/com/android/systemui/statusbar/phone/
Click to expand...
Click to collapse
Sorry about that. Files are up!
loserskater said:
I was going to go that route, but wanted to get this done first. Sharing that color changer apk would be awesome!
Sorry about that. Files are up!
Click to expand...
Click to collapse
Thanks mate!
---------- Post added at 11:25 PM ---------- Previous post was at 10:48 PM ----------
Well, this worked great
The only issue I can notice is that to set the statusbar colour, you must pick the colour, then pick the transparency.
Not a big deal though!
Thanks loserskater!
Kryten2k35 said:
Thanks mate!
---------- Post added at 11:25 PM ---------- Previous post was at 10:48 PM ----------
Well, this worked great
The only issue I can notice is that to set the statusbar colour, you must pick the colour, then pick the transparency.
Not a big deal though!
Thanks loserskater!
Click to expand...
Click to collapse
It works just fine for me. Post your BaseStatusBar
Sent from my SAMSUNG-SGH-I747
Ok
It's not a massive deal though.
loserskater said:
I was going to go that route, but wanted to get this done first. Sharing that color changer apk would be awesome!
Click to expand...
Click to collapse
I think you have to be part of The Family for that.
I also get this now:
Code:
W/BroadcastQueue( 2707): Failure sending broadcast Intent { act=android.intent.action.SCREEN_OFF flg=0x50000010 }
W/BroadcastQueue( 2707): android.os.DeadObjectException
W/BroadcastQueue( 2707): at android.os.BinderProxy.transact(Native Method)
W/BroadcastQueue( 2707): at android.content.IIntentReceiver$Stub$Proxy.performReceive(IIntentReceiver.java)
W/BroadcastQueue( 2707): at com.android.server.am.BroadcastQueue.performReceiveLocked(BroadcastQueue.java)
W/BroadcastQueue( 2707): at com.android.server.am.BroadcastQueue.deliverToRegisteredReceiverLocked(BroadcastQueue.java)
W/BroadcastQueue( 2707): at com.android.server.am.BroadcastQueue.processNextBroadcast(BroadcastQueue.java)
W/BroadcastQueue( 2707): at com.android.server.am.ActivityManagerService.finishReceiver(ActivityManagerService.java)
W/BroadcastQueue( 2707): at android.content.BroadcastReceiver$PendingResult.sendFinished(BroadcastReceiver.java)
W/BroadcastQueue( 2707): at android.content.BroadcastReceiver$PendingResult.finish(BroadcastReceiver.java)
W/BroadcastQueue( 2707): at android.app.LoadedApk$ReceiverDispatcher$Args.run(LoadedApk.java)
W/BroadcastQueue( 2707): at android.os.Handler.handleCallback(Handler.java)
W/BroadcastQueue( 2707): at android.os.Handler.dispatchMessage(Handler.java)
W/BroadcastQueue( 2707): at android.os.Looper.loop(Looper.java)
W/BroadcastQueue( 2707): at com.android.server.ServerThread.run(SystemServer.java)
W/BroadcastQueue( 2707): Failure sending broadcast Intent { act=android.intent.action.SCREEN_OFF flg=0x50000010 }
W/BroadcastQueue( 2707): android.os.DeadObjectException
W/BroadcastQueue( 2707): at android.os.BinderProxy.transact(Native Method)
W/BroadcastQueue( 2707): at android.content.IIntentReceiver$Stub$Proxy.performReceive(IIntentReceiver.java)
W/BroadcastQueue( 2707): at com.android.server.am.BroadcastQueue.performReceiveLocked(BroadcastQueue.java)
W/BroadcastQueue( 2707): at com.android.server.am.BroadcastQueue.deliverToRegisteredReceiverLocked(BroadcastQueue.java)
W/BroadcastQueue( 2707): at com.android.server.am.BroadcastQueue.processNextBroadcast(BroadcastQueue.java)
W/BroadcastQueue( 2707): at com.android.server.am.ActivityManagerService.finishReceiver(ActivityManagerService.java)
W/BroadcastQueue( 2707): at android.app.ActivityManagerNative.onTransact(ActivityManagerNative.java)
W/BroadcastQueue( 2707): at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java)
W/BroadcastQueue( 2707): at android.os.Binder.execTransact(Binder.java)
W/BroadcastQueue( 2707): at dalvik.system.NativeStart.run(Native Method)
W/AlarmManager( 2707): FACTORY_ON= 0
D/dalvikvm( 2707): GC_CONCURRENT freed 310K, 57% free 18664K/43015K, paused 13ms+13ms, total 164ms
E/Trace ( 8497): error opening trace file: No such file or directory (2)
E/JavaBinder( 8497): *** Uncaught remote exception! (Exceptions are not yet supported across processes.)
E/JavaBinder( 8497): java.lang.RuntimeException: android.os.DeadObjectException
E/JavaBinder( 8497): at android.os.Parcel.writeException(Parcel.java)
E/JavaBinder( 8497): at android.os.Binder.execTransact(Binder.java)
E/JavaBinder( 8497): at dalvik.system.NativeStart.run(Native Method)
E/JavaBinder( 8497): Caused by: android.os.DeadObjectException
E/JavaBinder( 8497): at android.os.BinderProxy.transact(Native Method)
E/JavaBinder( 8497): at android.content.IIntentReceiver$Stub$Proxy.performReceive(IIntentReceiver.java)
E/JavaBinder( 8497): at android.app.ActivityThread$ApplicationThread.scheduleRegisteredReceiver(ActivityThread.java)
E/JavaBinder( 8497): at android.app.ApplicationThreadNative.onTransact(ApplicationThreadNative.java)
E/JavaBinder( 8497): ... 2 more
Whenever the screen turns off, the wallpaper and statusbar die and then come back. It also happens sometimes when changing the clock, and sometimes the left and center clocks shot together :/
Very odd because it worked great last night!
i get this when trying to compile..can anyone help please
[2932,4] ALL REGISTER ARGS MUST FIT 4 BITS
[2938,4] THE REGISTER NUMBER MUST BE LESS THAN V16
[2940,4] MISMATCHED TREE NODE ....
[2942,4] MISMATCHED TREE NODE ....
Click to expand...
Click to collapse
THANKS

[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:

[Porting Guide][ICS] Mod 4.2 Statusbar tilesview (TABS, Slider, Flip Anim, Lidroid )

PORTING GUIDE - MOD 4.2 STATUSBAR
( TABS, Slider control, Flip button/Flip Anim, Lidroid )
FOR ICS 4.0
This is been requested so many times, so here I made the guide
But don't use it on JB or Touchwiz based
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 @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
NOTE !!
I USE CM9/HDPI AS BASE FOR THIS GUIDE, SO FOR OTHER ROM OR DEVICE SHOULD ADAPT THIS GUIDE,
BUT FOR CM9 DON'T FOLLOW THIS GUIDE, YOU CAN JUST FLASH MY MOD FROM :
- [MOD][CM9] JB 4.2.2 Quicksettings & Tabbed Settings V 4 ( WITH TWEAK )
- [MOD][CM9] JB 4.2.2 Quicksettings & Tabbed Settings V 5 ( TWEAK & GESTURE )
STEP - 1
Decompile SystemUI.apk
SystemUI.apk\res\layout
status_bar_expanded.xml
BEFORE
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 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>
AFTER
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">
<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="@*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: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>
</com.android.systemui.statusbar.phone.ExpandedView>
status_bar_tracking.xml
BEFORE
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.TrackingView android:orientation="vertical" android:paddingLeft="0.0px" android:paddingRight="0.0px" android:paddingBottom="0.0px" android:focusable="true" android:visibility="gone" android:descendantFocusability="afterDescendants"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:background="@drawable/notification_tracking_bg" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1.0">
<com.android.systemui.statusbar.phone.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:layout_gravity="bottom" android:paddingBottom="20.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content" />
</FrameLayout>
<com.android.systemui.statusbar.phone.CloseDragHandle android:orientation="vertical" android:id="@id/close" android:layout_width="fill_parent" android:layout_height="wrap_content">
<ImageView android:layout_gravity="bottom" android:layout_width="fill_parent" android:layout_height="wrap_content" android:src="@drawable/status_bar_close_on" android:scaleType="fitXY" />
</com.android.systemui.statusbar.phone.CloseDragHandle>
</com.android.systemui.statusbar.phone.TrackingView>
AFTER
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.TrackingView android:orientation="vertical" android:background="@drawable/notification_tracking_bg" android:paddingLeft="0.0px" android:paddingRight="0.0px" android:paddingBottom="0.0px" android:focusable="true" android:visibility="gone" android:descendantFocusability="afterDescendants"
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">
<com.android.systemui.statusbar.phone.CarrierLabel android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:layout_gravity="bottom" android:id="@id/carrier_label" android:paddingBottom="20.0dip" android:layout_width="fill_parent" android:layout_height="wrap_content" />
</FrameLayout>
<com.android.systemui.statusbar.phone.CloseDragHandle android:orientation="vertical" android:id="@id/close" android:layout_width="fill_parent" android:layout_height="35.0dip">
<ImageView android:layout_gravity="bottom" android:background="@drawable/status_bar_close" android:clickable="true" android:layout_width="fill_parent" android:layout_height="35.0dip" android:scaleType="fitXY" />
</com.android.systemui.statusbar.phone.CloseDragHandle>
</com.android.systemui.statusbar.phone.TrackingView>
NEXT CONTINUE IN POST #3
:thumbup:
Sent from my GT-I8150 using XDA Premium 4 mobile app
SystemUI.apk\res\values : add the blue code to the end line of :
dimens.xml, ids.xml, strings.xml, styles.xml,
dimens.xml
Code:
[COLOR="Blue"]
<dimen name="notification_panel_header_height">48.0dip</dimen>
<dimen name="quickpanel_button_height">107.0dip</dimen>
<dimen name="quickpanel_tabs_height">40.0dip</dimen>[/COLOR]
</resources>
ids.xml
Code:
[COLOR="Blue"]
<item type="id" name="datetime">false</item>
<item type="id" name="header_flipper">false</item>
<item type="id" name="carrier_label">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>[/COLOR]
</resources>
strings.xml
make change this line
before
Code:
<string name="status_bar_date_formatter">%2$s</string>
change it to
Code:
<string name="status_bar_date_formatter">"%1$s
%2$s"</string>
strings.xml
add the blue code
Code:
[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">CWM 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">Quicksettings</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_action_text">Lock Now</string>[/COLOR]
</resources>
styles.xml
Code:
[COLOR="Blue"]
<style name="TextAppearance.StatusBar.Expanded" parent="@*android:style/TextAppearance.Small.CalendarViewWeekDayView" />
<style name="TextAppearance.StatusBar.Expanded.Clock" parent="@style/TextAppearance.StatusBar.Expanded">
<item name="android:textSize">31.0dip</item>
<item name="android:textStyle">normal</item>
<item name="android:textColor">#ffffffff</item>
</style>
<style name="TextAppearance.StatusBar.Expanded.Date" parent="@style/TextAppearance.StatusBar.Expanded">
<item name="android:textSize">11.0dip</item>
<item name="android:textStyle">normal</item>
<item name="android:textColor">#ffcccccc</item>
<item name="android:textAllCaps">true</item>
</style>
<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>
NEXT CONTINUE IN POST #4
STEP -2
Download attached ICS_JB.4.2_Smali_&_XML_SystemUI.apk, exstract it and merge to your decompiled SystemUI.apk,.
NOTE !!
if your device has arays.xml, adapt it with the arays.xml inside ICS_JB.4.2_Smali_&_XML_SystemUI.apk
STEP -3
go to your decompiled
SystemUI.apk\smali\com\android\systemui\statusbar\phone\ PhoneStatusBar.smali
add the blue code
Code:
.field mAnimating:Z
.field mAnimatingReveal:Z
[COLOR="Blue"].field private mAudioManager:Landroid/media/AudioManager;[/COLOR]
.field private mAutoBrightness:Z
.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 mClearButton:Landroid/view/View;
.field private mClearButtonListener:Landroid/view/View$OnClickListener;
.field mCloseView:Lcom/android/systemui/statusbar/phone/CloseDragHandle;
.field private mCollapseAccelPx:F
.field private mCollapseMinDisplayFraction:F
[COLOR="Blue"].field mContentsFlipper:Landroid/widget/ViewFlipper;[/COLOR]
.field mCurAnimationTime:J
.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 mExpandAccelPx:F
.field private mExpandMinDisplayFraction:F
.field mExpanded:Z
.field mExpandedContents:Landroid/view/View;
.field mExpandedDialog:Landroid/app/Dialog;
.field mExpandedParams:Landroid/view/WindowManager$LayoutParams;
.field mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
.field mExpandedVisible:Z
.field private mFlingCollapseMinVelocityPx:F
.field private mFlingExpandMinVelocityPx:F
.field private mFlingGestureMaxXVelocityPx:F
[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;
.field mHandler:Lcom/android/systemui/statusbar/phone/PhoneStatusBar$H;
[COLOR="Blue"].field mHeaderFlipper:Landroid/widget/ViewFlipper;[/COLOR]
.field mIconHPadding:I
.field mIconPolicy:Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;
.field mIconSize:I
.field mIcons:Landroid/widget/LinearLayout;
.field private mIntruderAlertView:Landroid/view/View;
.field mLinger:I
.field mLocationController:Lcom/android/systemui/statusbar/policy/LocationController;
[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 mNetworkController:Lcom/android/systemui/statusbar/policy/NetworkController;
.field mNoNotificationsTitle:Landroid/widget/TextView;
.field mNotificationData:Lcom/android/systemui/statusbar/NotificationData;
.field mNotificationIcons:Lcom/android/systemui/statusbar/phone/IconMerger;
.field private mPanelSlightlyVisible:Z
.field mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
.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;[/COLOR]
.field private mRecentTasksLoader:Lcom/android/systemui/recent/RecentTasksLoader;
[COLOR="Blue"].field mRecentsButton:Landroid/view/View;[/COLOR]
.field private mRecentsClickListener:Landroid/view/View$OnClickListener;
.field private mRecentsPanel:Lcom/android/systemui/recent/RecentsPanelView;
.field private mRecreating:Z
.field private mScreenWidth:F
.field mScrollView:Landroid/widget/ScrollView;
Next
find this method
Code:
# direct methods
.method public constructor <init>()V
add the blue code above its return-void
Code:
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$11;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$11;-><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$FlipToQuickPanel;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FlipToQuickPanel;-><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$FlipToNotifications;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FlipToNotifications;-><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$FlipToQuickPanelToggles;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FlipToQuickPanelToggles;-><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$FlipToQuickPanelSliders;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FlipToQuickPanelSliders;-><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$FlipToBottomQuickPanelToggles;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FlipToBottomQuickPanelToggles;-><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$FlipToBottomQuickPanelSliders;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$FlipToBottomQuickPanelSliders;-><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 2531
return-void
.end method
Next , add the blue code bellow .end method
Code:
.line 2531
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[/COLOR]
Next , find this method
Code:
.method private getNavigationBarLayoutParams()Landroid/view/WindowManager$LayoutParams;
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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, 0x7f0e00b4
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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 getNavigationBarLayoutParams()Landroid/view/WindowManager$LayoutParams;
.locals 6
.prologue
const/4 v1, -0x1
Next, find this method
Code:
.method private inflateViews(Lcom/android/systemui/statusbar/NotificationData$Entry;Landroid/view/ViewGroup;)Z
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;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
const v1, 0x7f0e009c
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/TrackingView;->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 inflateViews(Lcom/android/systemui/statusbar/NotificationData$Entry;Landroid/view/ViewGroup;)Z
.locals 11
.parameter
.parameter
.prologue
.line 991
NEXT CONTINUE IN POST #5
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 3
.prologue
.line 534
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
Next, find this method
Code:
.method private setAreThereNotifications()V
add the blue 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 setAreThereNotifications()V
.locals 8
.prologue
const/4 v4, 0x0
Next, find this method
Code:
.method private tick(Lcom/android/internal/statusbar/StatusBarNotification;)V
add the blue code above it
Code:
[COLOR="Blue"].method private setQuickPanelUserButtonInfo()V
.locals 4
.prologue
.line 52
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v3, 0x7f0e00a9
invoke-virtual {v2, v3}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v3, 0x7f0e00a8
invoke-virtual {v1, v3}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v8, 0x7f0e00af
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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$SetQuickPanelVolumeSlidersOne;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SetQuickPanelVolumeSlidersOne;-><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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v8, 0x7f0e00b0
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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$SetQuickPanelVolumeSlidersTwo;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SetQuickPanelVolumeSlidersTwo;-><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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v8, 0x7f0e00b1
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$SetQuickPanelVolumeSlidersThree;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SetQuickPanelVolumeSlidersThree;-><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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v8, 0x7f0e00b2
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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$SetQuickPanelVolumeSlidersFour;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SetQuickPanelVolumeSlidersFour;-><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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v8, 0x7f0e00b3
invoke-virtual {v5, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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$SetQuickPanelVolumeSlidersFive;
invoke-direct {v5, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SetQuickPanelVolumeSlidersFive;-><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
.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, 0x7f08008e
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;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
invoke-direct {p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->preferenceStatusbarExpandedShowCarrierLabel(Landroid/view/View;)Z
move-result v1
if-eqz v1, :cond_0
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
const v1, 0x7f0e009c
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/TrackingView;->findViewById(I)Landroid/view/View;
move-result-object v0
.local v0, carrierLabel:Landroid/view/View;
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
:cond_0
return-void
.end method[/COLOR]
.method private tick(Lcom/android/internal/statusbar/StatusBarNotification;)V
.locals 2
.parameter
.prologue
.line 1797
NEXT CONTINUE IN POST #6
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, 0x7f08008e
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
.line 1871
Next find this method
Code:
# virtual methods
.method public addIcon(Ljava/lang/String;IILcom/android/internal/statusbar/StatusBarIcon;)V
scroll down and add the blue code above return-void
Code:
[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 615
return-void
.end method
Next find this method
Code:
.method public disable(I)V
add the 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
const/high16 v7, 0x100
Nex find this method
Code:
.method getExpandedHeight(I)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, 0x7f040014
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, 0x7f040015
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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, 0x7f0e00b4
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, 0x7f0e00b5
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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, 0x7f040014
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, 0x7f040015
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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, 0x7f0e00b5
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, 0x7f0e00b4
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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 getExpandedHeight(I)I
.locals 2
.parameter "disph"
.prologue
.line 2166
NEXT CONTINUE IN POST #7
Nex find this method
Code:
.method protected makeStatusBarView()Landroid/view/View;
scroll down in the method , and add the blue code, but you must adapt the register number v8, v1 and v9 with yours, do not copy the red code, you must use your own register
Code:
[COLOR="Blue"]const [COLOR="Red"]v8[/COLOR], 0x7f0e00aa
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelContents:Landroid/view/View;[/COLOR]
.line 390
const v8, 0x7f0e004e
invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v8
check-cast v8, Landroid/widget/TextView;
iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNoNotificationsTitle:Landroid/widget/TextView;
.line 391
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNoNotificationsTitle:Landroid/widget/TextView;
invoke-virtual {v8, v11}, Landroid/widget/TextView;->setVisibility(I)V
.line 393
const v8, 0x7f0e004d
invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v8
iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
.line 394
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v8, v9}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 395
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/4 v9, 0x0
invoke-virtual {v8, v9}, Landroid/view/View;->setAlpha(F)V
.line 396
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
const/4 v9, 0x0
invoke-virtual {v8, v9}, Landroid/view/View;->setEnabled(Z)V
.line 397
const v8, 0x7f0e004b
invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v8
check-cast v8, Lcom/android/systemui/statusbar/policy/DateView;
iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
.line 398
const v8, 0x7f0e004c
invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v8
iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/view/View;
.line 399
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/view/View;
iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v8, v9}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
[COLOR="Blue"]const [COLOR="Red"]v8[/COLOR], 0x7f0e00a4
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButton:Landroid/view/View;
.line 101
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButton:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToQuickPanelButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 110
const [COLOR="Red"]v8[/COLOR], 0x7f0e00a5
invoke-virtual [COLOR="Red"]{v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButton:Landroid/view/View;
.line 111
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButton:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mFlipToNotificationsButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 120
const [COLOR="Red"]v8[/COLOR], 0x7f0e009b
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
check-cast [COLOR="Red"]v8[/COLOR], Landroid/widget/ViewFlipper;
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHeaderFlipper:Landroid/widget/ViewFlipper;
.line 121
const [COLOR="Red"]v8[/COLOR], 0x7f0e00a6
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
check-cast [COLOR="Red"]v8[/COLOR], Landroid/widget/ViewFlipper;
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContentsFlipper:Landroid/widget/ViewFlipper;
.line 130
const [COLOR="Red"]v8[/COLOR], 0x7f0e003d
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentsButton:Landroid/view/View;
.line 131
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentsButton:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentsClickListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 140
const [COLOR="Red"]v8[/COLOR], 0x7f0e00ac
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsToggles:Landroid/view/View;
.line 141
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsToggles:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsTogglesListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 150
const [COLOR="Red"]v8[/COLOR], 0x7f0e00ad
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSliders:Landroid/view/View;
.line 151
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSliders:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelTopTabsSlidersListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 152
const [COLOR="Red"]v8[/COLOR], 0x7f0e00b7
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsToggles:Landroid/view/View;
.line 153
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsToggles:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsTogglesListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 154
const [COLOR="Red"]v8[/COLOR], 0x7f0e00b8
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSliders:Landroid/view/View;
.line 155
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSliders:Landroid/view/View;
iget-object [COLOR="Red"]v9[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickPanelBottomTabsSlidersListener:Landroid/view/View$OnClickListener;
invoke-virtual {[COLOR="Red"]v8, v9[/COLOR]}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 156
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->selectQuickPanelInitialTab()V
.line 160
const [COLOR="Red"]v8[/COLOR], 0x7f0e00ae
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
check-cast [COLOR="Red"]v8[/COLOR], Landroid/widget/ViewFlipper;
iput-object [COLOR="Red"]v8[/COLOR], 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 400
const v8, 0x7f0e004f
invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object v8
check-cast v8, Landroid/widget/ScrollView;
iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mScrollView:Landroid/widget/ScrollView;
[COLOR="Blue"]const [COLOR="Red"]v8[/COLOR], 0x7f0e00b6
invoke-virtual {[COLOR="Red"]v1, v8[/COLOR]}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
move-result-object [COLOR="Red"]v8[/COLOR]
check-cast [COLOR="Red"]v8[/COLOR], Lcom/lidroid/systemui/quickpanel/PowerWidget;
iput-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
.line 404
iget-object [COLOR="Red"]v8[/COLOR], p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;[/COLOR]
.line 403
new-instance v9, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$1;
invoke-direct {v9, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$1;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v8, v9}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setGlobalButtonOnClickListener(Landroid/view/View$OnClickListener;)V
.line 412
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPowerWidget:Lcom/lidroid/systemui/quickpanel/PowerWidget;
new-instance v9, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$2;
invoke-direct {v9, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$2;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
invoke-virtual {v8, v9}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setGlobalButtonOnLongClickListener(Landroid/view/View$OnLongClickListener;)V
.line 419
new-instance v8, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;
invoke-direct {v8, p0, v0, v4}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/content/Context;Landroid/view/View;)V
iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTicker:Lcom/android/systemui/statusbar/phone/Ticker;
Next , scroll down still in the same method
add the blue code and adapt the red code
Code:
]const-string v8, "android.intent.action.CLOSE_SYSTEM_DIALOGS"
invoke-virtual {v2, v8}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
.line 457
const-string v8, "android.intent.action.SCREEN_ON"
invoke-virtual {v2, v8[/COLOR]}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
.line 458
const-string [COLOR="Red"]v8[/COLOR], "android.intent.action.SCREEN_OFF"
invoke-virtual {[COLOR="Red"]v2, v8[/COLOR]}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
[COLOR="Blue"]const-string [COLOR="Red"]v8[/COLOR], "android.media.VOLUME_CHANGED_ACTION"
invoke-virtual {[COLOR="Red"]v2, v8[/COLOR]}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V[/COLOR]
.line 459
iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBroadcastReceiver:Landroid/content/BroadcastReceiver;
invoke-virtual {v0, v8, v2}, 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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v6, 0x7f0e008a
invoke-virtual {v5, v6}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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 463
return-object v4
.line 368
.end local v2 #filter:Landroid/content/IntentFilter;
.end local v6 #signalCluster:Lcom/android/systemui/statusbar/SignalClusterView;
.end local v7 #tickerView:Lcom/android/systemui/statusbar/phone/TickerView;
:catch_0
move-exception v8
goto/16 :goto_0
.end method
NEXT CONTINUE IN POST #8
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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v2, 0x7f0e00a9
invoke-virtual {v1, v2}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v2, 0x7f0e00a8
invoke-virtual {v0, v2}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v7, 0x7f0e00af
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v7, 0x7f0e00b0
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v7, 0x7f0e00b1
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v7, 0x7f0e00b2
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v7, 0x7f0e00b3
invoke-virtual {v5, v7}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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 9
.prologue
const/4 v8, 0x0
.line 489
const/4 v3, 0x0
.line 490
.local v3, visible:Z
DONE !!, AND RECOMPILE YOUR SYSTEMUI.APK
NEXT CONTINUE IN POST #9
STEP -4
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 ICS_4.2_source_public.xml, exstract it and open it with Notepad++
so now you have two xml which is opened in the Notepad++
1. your second decompiled SystemUI.apk public.xml and
2. ICS_4.2_source_public.xml
next, go to your
- Second decompiled SystemUI.apk / smali/com/android/systemui/statusbar/phone/ PhoneStatusBar.smali
find all ID which is started with
Code:
0x7f[COLOR="Red"]xxxxxx[/COLOR]
in all blue code you have added
find those ID in the ICS_ 4.2_source_public.xml for
EXAMPLE :
Code:
.method private fastFlipToQuickPanelToggles()V
.locals 2
.prologue
.line 2255
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
const v1, [COLOR="Red"]0x7f0e00b4[/COLOR] [COLOR="Magenta"]<------ Replace this ID with your new ID [/COLOR]
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/ExpandedView;->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
FIND this ID 0x7f0e00b4 in ICS_4.2_source_public.xml is for
we find that is for
Code:
<public type="[COLOR="Green"]id[/COLOR]" name="[COLOR="Blue"]quickpanel_scrollview_toggles[/COLOR]" id="[COLOR="Red"]0x7f0e00b4[/COLOR]" />
pay attention to the green code can be
id
strings
drawable
anim
arays
dimens
layout
you must match it too
next find quickpanel_scrollview_toggles new ID in your second decompiled SystemUI.apk public.xml
Code:
<public type="[COLOR="Green"]id[/COLOR]" name="[COLOR="Blue"]quickpanel_scrollview_toggles[/COLOR]" id="[COLOR="Red"]0x7f??????[/COLOR]" />
Code:
const v1, [COLOR="Red"]0x7f0e00b4[/COLOR] [COLOR="Magenta"]<---Replace this ID with your new ID [COLOR="Red"]0x7f??????[/COLOR][/COLOR]
do it too to all
Code:
0x7f[COLOR="Red"]xxxxxx[/COLOR]
in all blue code you have added to PhoneStatusBar.smali
and in all smalis in SystemUI.apk\smali\com\lidroid\systemui\quickpanel \ here ..
DONE and recompile your SystemUI.apk,. push to system/app with right permission
and
Download Attached Power_Widget_Settings.apk and push to system/app with right permission
Screenshot
Move TABS to top of tilesview
SystemUI.apk\res\layout\ status_bar_expanded_quickpanel.XML
remove the red code
Code:
<include android:id="[COLOR="Green"]@id/quickpanel_top_tabs[/COLOR]" [COLOR="Red"]android:visibility="gone"[/COLOR] android:layout_width="fill_parent" android:layout_height="@dimen/quickpanel_tabs_height" android:layout_alignParentLeft="true" android:layout_alignParentTop="true" android:layout_alignParentRight="true" layout="@layout/status_bar_expanded_quickpanel_top_tabs" />
And make sure the blue code is there
Code:
<include android:id="[COLOR="Green"]@id/quickpanel_bottom_tabs[/COLOR]" [COLOR="Blue"]android:visibility="gone"[/COLOR] android:layout_width="fill_parent" [COLOR="Blue"]android:layout_height="0.0dip[/COLOR]" android:layout_alignParentLeft="true" android:layout_alignParentRight="true" android:layout_alignParentBottom="true" layout="@layout/status_bar_expanded_quickpanel_bottom_tabs" />
Hide all TABS from tilesview
SystemUI.apk\res\layout\ status_bar_expanded_quickpanel.XML
make sure the red code is there
Code:
<include android:id="[COLOR="Green"]@id/quickpanel_top_tabs[/COLOR]" [COLOR="Red"]android:visibility="gone"[/COLOR] android:layout_width="fill_parent" android:layout_height="@dimen/quickpanel_tabs_height" android:layout_alignParentLeft="true" android:layout_alignParentTop="true" android:layout_alignParentRight="true" layout="@layout/status_bar_expanded_quickpanel_top_tabs" />
And
Code:
<include android:id="[COLOR="Green"]@id/quickpanel_bottom_tabs[/COLOR]" [COLOR="Red"]android:visibility="gone"[/COLOR] android:layout_width="fill_parent" [COLOR="Red"]android:layout_height="0.0dip"[/COLOR] android:layout_alignParentLeft="true" android:layout_alignParentRight="true" android:layout_alignParentBottom="true" layout="@layout/status_bar_expanded_quickpanel_bottom_tabs" />
How to full screen Expanded Pulldown JB style
go here : Guide How to full screen Expanded Pulldown JB style
How to change ME toggle Photo and Name
Go to contact app ( people app )
tap first contact ( ME )
and Edit it, don't forget to save it and reboot once.
Additional Tips and Instruction for two SIM card devices
for two SIM card devices, read my explanation about carrier label in JB guide http://forum.xda-developers.com/showthread.php?t=2406596&page=2
Thats a lot of reserves im first here
EDIT: aww looks like someone else posted a reply before me
Sent from my H100 using xda app-developers app
awesome dude you rock!!
Great guide!!
Gửi từ... mà thật ra thì cũng đéo ai quan tâm #
thanksssssssss
Added Guide How to full screen Expanded Pulldown JB style
http://forum.xda-developers.com/showthread.php?p=45130177#post45130177
unlucky i got my statusbar fc'd
Sent from my AD683G using xda app-developers app
Hi buddy...
Here is a teaser of my new creation titled Power Toggles.
For better quality choose 480p http://youtu.be/5zk0jHBxHhE
I´m gonna release it on Xperia L forum soon, and port it to any device was never so easy (even non-xperia)... believe me!!
(sorry about spamming your thread... pm me if u mind)

MOD][GUIDE] Stand Alone Battery Bar With Options

Original Guide is made by Didact74 here :
[MOD][GUIDE] Stand Alone Battery Bar w/Options and color picker
All credit to him and Kryten2k35 for some smali method
This guide allows you to add the battery bar to your ROM with out any Add-On APKs
Ok, let's go to guide!!!
We will be working with two files:
SystemUI.apk
SecSettings.apk
Note : Blue=add
PART I, Secsettings.apk
navigate to res/xml/display_settings.xml
Code:
[COLOR="Blue"]<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<ListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:entryValues="@array/battery_bar_values" />
<ListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:entryValues="@array/battery_bar_style_values" />
<ListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:entryValues="@array/battery_bar_thickness_values" />
<CheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>[/COLOR]
<PreferenceCategory android:title="@string/more_settings" android:key="more_settings" />[/HIDE]
Navigate to res/values/arrays
Code:
[COLOR="Blue"]<string-array name="battery_bar_entries">
<item>Hide</item>
<item>Show</item>
</string-array>
<string-array name="battery_bar_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_style_entries">
<item>Regular</item>
<item>Center-mirrored</item>
</string-array>
<string-array name="battery_bar_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_thickness_entries">
<item>1 dp</item>
<item>2 dp</item>
<item>3 dp</item>
<item>4 dp</item>
</string-array>
<string-array name="battery_bar_thickness_values">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</string-array>[/COLOR]
</resources>
Navigate to res/values/strings
Code:
[COLOR="Blue"]<string name="battery_bar_setting">Battery Bar Setting</string>
<string name="battery_bar">Enable battery bar</string>
<string name="battery_bar_color">Choose battery bar color</string>
<string name="battery_bar_style_title">Battery bar style</string>
<string name="battery_bar_thickness_title">Battery Bar Thickness</string>
<string name="battery_bar_animate_title">Battery Bar Animation</string>
<string name="battery_bar_animate_summary">Animate bar when charging</string>
<string name="battery_bar_summary">%s</string>
<string name="battery_bar_color_summary">Bar color</string>
<string name="battery_bar_style_title_summary">%s</string>
<string name="battery_bar_thickness_title_summary">%s</string>[/COLOR]
</resources>
Navigate to com/android/setting/DisplaySettings.smali
Code:
.field private mAnimationView:Landroid/widget/ImageView;
.field private mAutoLockmode:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"].field mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
.field mBatteryBarList:Landroid/preference/ListPreference;
.field mBatteryBarStyle:Landroid/preference/ListPreference;
.field mBatteryBarThickness:Landroid/preference/ListPreference;[/COLOR]
go to : .method private updateState()V
Code:
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="Blue"]iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar"
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;->mBatteryBarStyle:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_style"
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;->mBatteryBarThickness:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_thickness"
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[/COLOR]
.line 883
iget-boolean v0, p0, Lcom/android/settings/DisplaySettings;->mSupportFolderType:Z
if-eqz v0, :cond_0
.line 884
invoke-direct {p0}, Lcom/android/settings/DisplaySettings;->updateAccelerometerRotationSecondCheckbox()V
.line 885
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"
go to : .method public onCreate(Landroid/os/BundleV
Code:
const-string v10, "font_size"
invoke-virtual {p0, v10}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v10
check-cast v10, Landroid/preference/ListPreference;
iput-object v10, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
.line 428
iget-object v10, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
invoke-virtual {v10, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
[COLOR="Blue"]const-string v11, "battery_bar"
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;->mBatteryBarList:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "battery_bar_style"
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;->mBatteryBarStyle:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarStyle:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "battery_bar_thickness"
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;->mBatteryBarThickness:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarThickness:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V[/COLOR]
.line 430
const-string v10, "display_battery_level"
still same method :
Code:
.line 553
const-string v10, "key_multi_window"
invoke-virtual {p0, v10}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v10
check-cast v10, Landroid/preference/CheckBoxPreference;
iput-object v10, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"]const-string v11, "battery_bar_animate"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Landroid/preference/CheckBoxPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;[/COLOR]
.line 554
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v10
const-string v11, "com.sec.feature.multiwindow.phone"
go to : .method public onPreferenceChange(Landroid/preference/Preference;Ljava/lang/ObjectZ
Code:
.line 1071
const-string v1, "DisplaySettings"
const-string v2, "could not persist Touch key light setting"
invoke-static {v1, v2, v0}, Landroid/util/secutil/Log;->secE(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
goto/16 :goto_4
.line 1073
:cond_a
[COLOR="Blue"]const-string v2, "battery_bar_style"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_barstyle
.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, "battery_bar_style"
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;->mBatteryBarStyle: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;->mBatteryBarStyle:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarStyle: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_barstyle
const-string v2, "battery_bar"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_style
.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, "battery_bar"
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;->mBatteryBarList: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;->mBatteryBarList:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList: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_style
const-string v2, "battery_bar_thickness"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_tickness
.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, "battery_bar_thickness"
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;->mBatteryBarThickness: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;->mBatteryBarThickness:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarThickness: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_tickness[/COLOR]
const-string v2, "quick_launch"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
go to : .method public onPreferenceTreeClick(Landroid/preference/PreferenceScreen;Landroid/preference/PreferenceZ
BEFORE :
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, [COLOR="DarkOrange"]:cond_0[/COLOR]
.line 990
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 991
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
if-eqz v0, :cond_16
:goto_a
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 [COLOR="Yellow"]:goto_1[/COLOR]
:cond_16
move v1, v2
goto :goto_a
.end method
AFTER :
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, [COLOR="Blue"]:cond_batteryAnimate[/COLOR] <-- (change from ":cond_0" to new cond below = :cond_batteryAnimate)
.line 990
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 991
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
if-eqz v0, :cond_16
:goto_a
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 [COLOR="Yellow"]:goto_1[/COLOR]
:cond_16
move v1, v2
goto :goto_a
[COLOR="Blue"]:cond_batteryAnimate
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0,[/COLOR] [COLOR="DarkOrange"]:cond_0[/COLOR] <-- (this cond is from old cond i'm marked orange)
[COLOR="Blue"].line 1022
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 1023
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_animate"
if-eqz v0, :cond_battAnim
:goto_anM
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16[/COLOR] [COLOR="Yellow"]:goto_1[/COLOR] <--- (this cond is from cond above i'm marked yellow)
[COLOR="Blue"] :cond_battAnim
move v1, v2
goto :goto_anM[/COLOR]
.end method
go to : .method public onResume()V
BEFORE :
Code:
.line 821
:cond_1
sget-boolean v0, Lcom/android/settings/DisplaySettings;->UseMultiWindow:Z
if-eqz v0, [COLOR="Yellow"]:cond_2[/COLOR]
.line 822
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-ne v3, v1, :cond_6
:goto_2
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 823
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "multi_window_enabled"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowModeObserver:Landroid/database/ContentObserver;
invoke-virtual {v0, v1, v2, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 825
:cond_2
return-void
:cond_3
move v0, v2
AFTER :
Code:
.line 821
:cond_1
sget-boolean v0, Lcom/android/settings/DisplaySettings;->UseMultiWindow:Z
if-eqz v0, [COLOR="Blue"]:cond_newAnim[/COLOR]
.line 822
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-ne v3, v1, :cond_6
:goto_2
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 823
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "multi_window_enabled"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowModeObserver:Landroid/database/ContentObserver;
invoke-virtual {v0, v1, v2, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
[COLOR="Blue"]:cond_newAnim
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
if-eqz v0,[/COLOR][COLOR="Yellow"] :cond_2[/COLOR]
[COLOR="Blue"].line 3001
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_animate"
const/4 v1, 0x0
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-eqz v3, :cond_noShow
const/4 v1, 0x1
goto :goto_yesShow
:cond_noShow
const/4 v1, 0x0
:goto_yesShow
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V[/COLOR]
.line 825
:cond_2
return-void
:cond_3
move v0, v2
PART II, SystemUI.apk
Navigate to res/layout/tw_status_bar.xml
Code:
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginRight="4.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
</ImageSwitcher>
<com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_old" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_new" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.phone.TickerView>
</LinearLayout>
[COLOR="Blue"]<com.android.systemui.statusbar.policy.BatteryBarController android:visibility="gone" android:layout_width="fill_parent" android:layout_height="1.0dip" android:layout_alignParentTop="true" systemui:viewLocation="1" />[/COLOR]
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
Navigate to res/values/attrs
Code:
[COLOR="Blue"]<attr name="viewLocation" format="integer" />[/COLOR]
</resources>
Navigate to smali/com/android/systemui/statusbar/policy/Prefs.smali
add this :
Code:
.method public static read(Landroid/content/Context;)Landroid/content/SharedPreferences;
.locals 2
.parameter "context"
.prologue
.line 32
const-string v0, "status_bar"
const/4 v1, 0x0
invoke-virtual {p0, v0, v1}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;
move-result-object v0
return-object v0
.end method
[COLOR="Blue"].method public static getLastBatteryLevel(Landroid/content/Context;)I
.locals 3
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->read(Landroid/content/Context;)Landroid/content/SharedPreferences;
move-result-object v0
const-string v1, "last_battery_level"
const/16 v2, 0x32
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I
move-result v0
return v0
.end method
.method public static getLastFastChargeState(Landroid/content/Context;)Z
.locals 3
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->read(Landroid/content/Context;)Landroid/content/SharedPreferences;
move-result-object v0
const-string v1, "last_fcharge_state"
const/4 v2, 0x0
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z
move-result v0
return v0
.end method
.method public static setLastBatteryLevel(Landroid/content/Context;I)V
.locals 2
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->edit(Landroid/content/Context;)Landroid/content/SharedPreferences$Editor;
move-result-object v0
const-string v1, "last_battery_level"
invoke-interface {v0, v1, p1}, Landroid/content/SharedPreferences$Editor;->putInt(Ljava/lang/String;I)Landroid/content/SharedPreferences$Editor;
move-result-object v0
invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z
return-void
.end method
.method public static setLastFastChargeState(Landroid/content/Context;Z)V
.locals 2
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->edit(Landroid/content/Context;)Landroid/content/SharedPreferences$Editor;
move-result-object v0
const-string v1, "last_fcharge_state"
invoke-interface {v0, v1, p1}, Landroid/content/SharedPreferences$Editor;->putBoolean(Ljava/lang/String;Z)Landroid/content/SharedPreferences$Editor;
move-result-object v0
invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z
return-void
.end method[/COLOR]
Find the attached zip file and place all files in smali/com/android/systemui/statusbar/policy
Nice guide sir thanks :good:
wahyu adhy wicaksono said:
Nice guide sir thanks :good:
Click to expand...
Click to collapse
Thank you sir
for compare.
I attach :
DisplaySettingsBefore.smali <-- Before edit
DisplaySettingsAfter <-- After edit
syaeful said:
for compare.
I attach :
DisplaySettingsBefore.smali <-- Before edit
DisplaySettingsAfter <-- After edit
Click to expand...
Click to collapse
i rom 4.1.2 LG not the same SS
--------------------------------------------------------------------------
|Mon 20/04/2015 -- 17:00:33.48|
--------------------------------------------------------------------------
java version "1.8.0_40"
Java(TM) SE Runtime Environment (build 1.8.0_40-b25)
Java HotSpot(TM) Client VM (build 25.40-b25, mixed mode)
I: Checking whether sources has changed...
I: Smaling...
[4698,13] Label "goto_4" is not defined.
[4744,13] Label "goto_4" is not defined.
[4750,4] mismatched tree node: I_STATEMENT_FORMAT35c_METHOD expecting I_CATCHES
[4752,4] mismatched tree node: I_STATEMENT_FORMAT11x expecting <UP>
Exception in thread "main" brut.androlib.AndrolibException: Could not smali file: D:\GL F120L\VH\APK-Multi-Tool HDKP\other\..\projects\LGSettings3_2_kp41.apk\smali\com\android\settings\DisplaySettings.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)
f120ltn said:
i rom 4.1.2 LG not the same SS
--------------------------------------------------------------------------
|Mon 20/04/2015 -- 17:00:33.48|
--------------------------------------------------------------------------
java version "1.8.0_40"
Java(TM) SE Runtime Environment (build 1.8.0_40-b25)
Java HotSpot(TM) Client VM (build 25.40-b25, mixed mode)
I: Checking whether sources has changed...
I: Smaling...
[4698,13] Label "goto_4" is not defined.
[4744,13] Label "goto_4" is not defined.
[4750,4] mismatched tree node: I_STATEMENT_FORMAT35c_METHOD expecting I_CATCHES
[4752,4] mismatched tree node: I_STATEMENT_FORMAT11x expecting <UP>
Exception in thread "main" brut.androlib.AndrolibException: Could not smali file: D:\GL F120L\VH\APK-Multi-Tool HDKP\other\..\projects\LGSettings3_2_kp41.apk\smali\com\android\settings\DisplaySettings.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)
Click to expand...
Click to collapse
ok sir, You can't just copy and paste from guide, you must do compare, because every rom has different condition,
For more easy, follow my guide :
PART I, Secsettings.apk
Download attachment file and merged to your decompiled Settings.apk
navigate to res/xml/display_settings.xml
Code:
[COLOR="Blue"]<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_values" />
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_style_values" />
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_thickness_values" />
<com.android.settings.syaeful.SystemSettingCheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>[/COLOR]
</PreferenceScreen>
Navigate to res/values/arrays.xml
Code:
[COLOR="Blue"]<string-array name="battery_bar_entries">
<item>Hide</item>
<item>Show</item>
</string-array>
<string-array name="battery_bar_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_style_entries">
<item>Regular</item>
<item>Center-mirrored</item>
</string-array>
<string-array name="battery_bar_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_thickness_entries">
<item>1 dp</item>
<item>2 dp</item>
<item>3 dp</item>
<item>4 dp</item>
</string-array>
<string-array name="battery_bar_thickness_values">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</string-array>[/COLOR]
</resources>
Navigate to res/values/strings.xml
Code:
[COLOR="Blue"]<string name="battery_bar_setting">Battery Bar Setting</string>
<string name="battery_bar">Enable battery bar</string>
<string name="battery_bar_color">Choose battery bar color</string>
<string name="battery_bar_style_title">Battery bar style</string>
<string name="battery_bar_thickness_title">Battery Bar Thickness</string>
<string name="battery_bar_animate_title">Battery Bar Animation</string>
<string name="battery_bar_animate_summary">Animate bar when charging</string>
<string name="battery_bar_summary">%s</string>
<string name="battery_bar_color_summary">Bar color</string>
<string name="battery_bar_style_title_summary">%s</string>
<string name="battery_bar_thickness_title_summary">%s</string>[/COLOR]
</resources>
finish for part setting.. recompile, sign, push to your system.. check in Display menu. it should not fc.
Note : if you follow this guide for part settings.. skip edit samli DisplaySettings.smali!!!!
syaeful said:
ok sir, You can't just copy and paste from guide, you must do compare, because every rom has different condition,
For more easy, follow my guide :
PART I, Secsettings.apk
Download attachment file and merged to your decompiled Settings.apk
navigate to res/xml/display_settings.xml
Code:
[COLOR="Blue"]<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_values" />
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_style_values" />
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_thickness_values" />
<com.android.settings.syaeful.SystemSettingCheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>[/COLOR]
</PreferenceScreen>
Navigate to res/values/arrays.xml
Code:
[COLOR="Blue"]<string-array name="battery_bar_entries">
<item>Hide</item>
<item>Show</item>
</string-array>
<string-array name="battery_bar_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_style_entries">
<item>Regular</item>
<item>Center-mirrored</item>
</string-array>
<string-array name="battery_bar_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_thickness_entries">
<item>1 dp</item>
<item>2 dp</item>
<item>3 dp</item>
<item>4 dp</item>
</string-array>
<string-array name="battery_bar_thickness_values">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</string-array>[/COLOR]
</resources>
Navigate to res/values/strings.xml
Code:
[COLOR="Blue"]<string name="battery_bar_setting">Battery Bar Setting</string>
<string name="battery_bar">Enable battery bar</string>
<string name="battery_bar_color">Choose battery bar color</string>
<string name="battery_bar_style_title">Battery bar style</string>
<string name="battery_bar_thickness_title">Battery Bar Thickness</string>
<string name="battery_bar_animate_title">Battery Bar Animation</string>
<string name="battery_bar_animate_summary">Animate bar when charging</string>
<string name="battery_bar_summary">%s</string>
<string name="battery_bar_color_summary">Bar color</string>
<string name="battery_bar_style_title_summary">%s</string>
<string name="battery_bar_thickness_title_summary">%s</string>[/COLOR]
</resources>
finish for part setting.. recompile, sign, push to your system.. check in Display menu. it should not fc.
Note : if you follow this guide for part settings.. skip edit samli DisplaySettings.smali!!!!
Click to expand...
Click to collapse
Thankyou
i work "ok" on file .xml. not edit DisplaySettings.smali
f120ltn said:
Thankyou
i work "ok" on file .xml. not edit DisplaySettings.smali
Click to expand...
Click to collapse
Yes. Should work. Regards.
syaeful said:
ok sir, You can't just copy and paste from guide, you must do compare, because every rom has different condition,
For more easy, follow my guide :
PART I, Secsettings.apk
Download attachment file and merged to your decompiled Settings.apk
navigate to res/xml/display_settings.xml
Code:
[COLOR="Blue"]<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_values" />
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_style_values" />
<com.android.settings.syaeful.SystemSettingListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:widgetLayout="@layout/round_more_icon" android:entryValues="@array/battery_bar_thickness_values" />
<com.android.settings.syaeful.SystemSettingCheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>[/COLOR]
</PreferenceScreen>
Navigate to res/values/arrays.xml
Code:
[COLOR="Blue"]<string-array name="battery_bar_entries">
<item>Hide</item>
<item>Show</item>
</string-array>
<string-array name="battery_bar_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_style_entries">
<item>Regular</item>
<item>Center-mirrored</item>
</string-array>
<string-array name="battery_bar_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_thickness_entries">
<item>1 dp</item>
<item>2 dp</item>
<item>3 dp</item>
<item>4 dp</item>
</string-array>
<string-array name="battery_bar_thickness_values">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</string-array>[/COLOR]
</resources>
Navigate to res/values/strings.xml
Code:
[COLOR="Blue"]<string name="battery_bar_setting">Battery Bar Setting</string>
<string name="battery_bar">Enable battery bar</string>
<string name="battery_bar_color">Choose battery bar color</string>
<string name="battery_bar_style_title">Battery bar style</string>
<string name="battery_bar_thickness_title">Battery Bar Thickness</string>
<string name="battery_bar_animate_title">Battery Bar Animation</string>
<string name="battery_bar_animate_summary">Animate bar when charging</string>
<string name="battery_bar_summary">%s</string>
<string name="battery_bar_color_summary">Bar color</string>
<string name="battery_bar_style_title_summary">%s</string>
<string name="battery_bar_thickness_title_summary">%s</string>[/COLOR]
</resources>
finish for part setting.. recompile, sign, push to your system.. check in Display menu. it should not fc.
Note : if you follow this guide for part settings.. skip edit samli DisplaySettings.smali!!!!
Click to expand...
Click to collapse
syaeful said:
Yes. Should work. Regards.
Click to expand...
Click to collapse
style Bar color not work.
f120ltn said:
style Bar color not work.
Click to expand...
Click to collapse
yes sir. not for now (maybe later will fix).. that's why I did't include the word "colorpicker" in this guide title
syaeful said:
yes sir. not for now (maybe later will fix).. that's why I did't include the word "colorpicker" in this guide title
Click to expand...
Click to collapse
Thankyou.
i adder "colorpicker" in rom.
ok it for later.
Please correct me pictures attached. the red circle. after exit and then re-enter the same
f120ltn said:
Thankyou.
i adder "colorpicker" in rom.
ok it for later.
Please correct me pictures attached. the red circle. after exit and then re-enter the same
Click to expand...
Click to collapse
it should not affected from DisplaySettings.smali sir... maybe from SystemSettingCheckBoxPreference.smali and SystemSettingListPreference.smali. i will check again. but for show/hide battery bar is normal or not?
Sorry for late response
syaeful said:
it should not affected from DisplaySettings.smali sir... maybe from SystemSettingCheckBoxPreference.smali and SystemSettingListPreference.smali. i will check again. but for show/hide battery bar is normal or not?
Sorry for late response
Click to expand...
Click to collapse
ok, so the correct answer.
Please help me mod in DisplaySettings.smali sir...
f120ltn said:
ok, so the correct answer.
Please help me mod in DisplaySettings.smali sir...
Click to expand...
Click to collapse
oohh.. yess.ofc. wait sir
f120ltn said:
ok, so the correct answer.
Please help me mod in DisplaySettings.smali sir...
Click to expand...
Click to collapse
try with smali in the attachment that I have modified.
and just use smali SystemSettingCheckBoxPreference.smali for battery bar animate
so you must fill this in res/xml/display_settings.xml
Code:
<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<ListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:entryValues="@array/battery_bar_values" />
<ListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:entryValues="@array/battery_bar_style_values" />
<ListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:entryValues="@array/battery_bar_thickness_values" />
<com.android.settings.syaeful.SystemSettingCheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>
syaeful said:
try with smali in the attachment that I have modified.
and just use smali SystemSettingCheckBoxPreference.smali for battery bar animate
so you must fill this in res/xml/display_settings.xml
Code:
<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<ListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:entryValues="@array/battery_bar_values" />
<ListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:entryValues="@array/battery_bar_style_values" />
<ListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:entryValues="@array/battery_bar_thickness_values" />
<com.android.settings.syaeful.SystemSettingCheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>
Click to expand...
Click to collapse
ok sir...
i try with smali in the attachment.
I hope it will run
thank you
PL: i sorry. i try but not run
(V11? My in rom V8)
kitul
syaeful said:
Original Guide is made by Didact74 here :
[MOD][GUIDE] Stand Alone Battery Bar w/Options and color picker
All credit to him and Kryten2k35 for some smali method
This guide allows you to add the battery bar to your ROM with out any Add-On APKs
Ok, let's go to guide!!!
We will be working with two files:
SystemUI.apk
SecSettings.apk
Note : Blue=add
PART I, Secsettings.apk
navigate to res/xml/display_settings.xml
Code:
[COLOR="Blue"]<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<ListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:entryValues="@array/battery_bar_values" />
<ListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:entryValues="@array/battery_bar_style_values" />
<ListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:entryValues="@array/battery_bar_thickness_values" />
<CheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>[/COLOR]
<PreferenceCategory android:title="@string/more_settings" android:key="more_settings" />[/HIDE]
Navigate to res/values/arrays
Code:
[COLOR="Blue"]<string-array name="battery_bar_entries">
<item>Hide</item>
<item>Show</item>
</string-array>
<string-array name="battery_bar_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_style_entries">
<item>Regular</item>
<item>Center-mirrored</item>
</string-array>
<string-array name="battery_bar_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_thickness_entries">
<item>1 dp</item>
<item>2 dp</item>
<item>3 dp</item>
<item>4 dp</item>
</string-array>
<string-array name="battery_bar_thickness_values">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</string-array>[/COLOR]
</resources>
Navigate to res/values/strings
Code:
[COLOR="Blue"]<string name="battery_bar_setting">Battery Bar Setting</string>
<string name="battery_bar">Enable battery bar</string>
<string name="battery_bar_color">Choose battery bar color</string>
<string name="battery_bar_style_title">Battery bar style</string>
<string name="battery_bar_thickness_title">Battery Bar Thickness</string>
<string name="battery_bar_animate_title">Battery Bar Animation</string>
<string name="battery_bar_animate_summary">Animate bar when charging</string>
<string name="battery_bar_summary">%s</string>
<string name="battery_bar_color_summary">Bar color</string>
<string name="battery_bar_style_title_summary">%s</string>
<string name="battery_bar_thickness_title_summary">%s</string>[/COLOR]
</resources>
Navigate to com/android/setting/DisplaySettings.smali
Code:
.field private mAnimationView:Landroid/widget/ImageView;
.field private mAutoLockmode:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"].field mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
.field mBatteryBarList:Landroid/preference/ListPreference;
.field mBatteryBarStyle:Landroid/preference/ListPreference;
.field mBatteryBarThickness:Landroid/preference/ListPreference;[/COLOR]
go to : .method private updateState()V
Code:
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="Blue"]iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar"
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;->mBatteryBarStyle:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_style"
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;->mBatteryBarThickness:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_thickness"
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[/COLOR]
.line 883
iget-boolean v0, p0, Lcom/android/settings/DisplaySettings;->mSupportFolderType:Z
if-eqz v0, :cond_0
.line 884
invoke-direct {p0}, Lcom/android/settings/DisplaySettings;->updateAccelerometerRotationSecondCheckbox()V
.line 885
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"
go to : .method public onCreate(Landroid/os/BundleV
Code:
const-string v10, "font_size"
invoke-virtual {p0, v10}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v10
check-cast v10, Landroid/preference/ListPreference;
iput-object v10, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
.line 428
iget-object v10, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
invoke-virtual {v10, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
[COLOR="Blue"]const-string v11, "battery_bar"
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;->mBatteryBarList:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "battery_bar_style"
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;->mBatteryBarStyle:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarStyle:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "battery_bar_thickness"
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;->mBatteryBarThickness:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarThickness:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V[/COLOR]
.line 430
const-string v10, "display_battery_level"
still same method :
Code:
.line 553
const-string v10, "key_multi_window"
invoke-virtual {p0, v10}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v10
check-cast v10, Landroid/preference/CheckBoxPreference;
iput-object v10, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"]const-string v11, "battery_bar_animate"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Landroid/preference/CheckBoxPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;[/COLOR]
.line 554
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v10
const-string v11, "com.sec.feature.multiwindow.phone"
go to : .method public onPreferenceChange(Landroid/preference/Preference;Ljava/lang/ObjectZ
Code:
.line 1071
const-string v1, "DisplaySettings"
const-string v2, "could not persist Touch key light setting"
invoke-static {v1, v2, v0}, Landroid/util/secutil/Log;->secE(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
goto/16 :goto_4
.line 1073
:cond_a
[COLOR="Blue"]const-string v2, "battery_bar_style"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_barstyle
.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, "battery_bar_style"
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;->mBatteryBarStyle: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;->mBatteryBarStyle:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarStyle: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_barstyle
const-string v2, "battery_bar"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_style
.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, "battery_bar"
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;->mBatteryBarList: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;->mBatteryBarList:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList: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_style
const-string v2, "battery_bar_thickness"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_tickness
.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, "battery_bar_thickness"
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;->mBatteryBarThickness: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;->mBatteryBarThickness:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarThickness: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_tickness[/COLOR]
const-string v2, "quick_launch"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
go to : .method public onPreferenceTreeClick(Landroid/preference/PreferenceScreen;Landroid/preference/PreferenceZ
BEFORE :
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, [COLOR="DarkOrange"]:cond_0[/COLOR]
.line 990
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 991
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
if-eqz v0, :cond_16
:goto_a
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 [COLOR="Yellow"]:goto_1[/COLOR]
:cond_16
move v1, v2
goto :goto_a
.end method
AFTER :
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, [COLOR="Blue"]:cond_batteryAnimate[/COLOR] <-- (change from ":cond_0" to new cond below = :cond_batteryAnimate)
.line 990
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 991
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
if-eqz v0, :cond_16
:goto_a
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 [COLOR="Yellow"]:goto_1[/COLOR]
:cond_16
move v1, v2
goto :goto_a
[COLOR="Blue"]:cond_batteryAnimate
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0,[/COLOR] [COLOR="DarkOrange"]:cond_0[/COLOR] <-- (this cond is from old cond i'm marked orange)
[COLOR="Blue"].line 1022
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 1023
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_animate"
if-eqz v0, :cond_battAnim
:goto_anM
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16[/COLOR] [COLOR="Yellow"]:goto_1[/COLOR] <--- (this cond is from cond above i'm marked yellow)
[COLOR="Blue"] :cond_battAnim
move v1, v2
goto :goto_anM[/COLOR]
.end method
go to : .method public onResume()V
BEFORE :
Code:
.line 821
:cond_1
sget-boolean v0, Lcom/android/settings/DisplaySettings;->UseMultiWindow:Z
if-eqz v0, [COLOR="Yellow"]:cond_2[/COLOR]
.line 822
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-ne v3, v1, :cond_6
:goto_2
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 823
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "multi_window_enabled"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowModeObserver:Landroid/database/ContentObserver;
invoke-virtual {v0, v1, v2, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 825
:cond_2
return-void
:cond_3
move v0, v2
AFTER :
Code:
.line 821
:cond_1
sget-boolean v0, Lcom/android/settings/DisplaySettings;->UseMultiWindow:Z
if-eqz v0, [COLOR="Blue"]:cond_newAnim[/COLOR]
.line 822
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-ne v3, v1, :cond_6
:goto_2
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 823
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "multi_window_enabled"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowModeObserver:Landroid/database/ContentObserver;
invoke-virtual {v0, v1, v2, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
[COLOR="Blue"]:cond_newAnim
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
if-eqz v0,[/COLOR][COLOR="Yellow"] :cond_2[/COLOR]
[COLOR="Blue"].line 3001
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_animate"
const/4 v1, 0x0
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-eqz v3, :cond_noShow
const/4 v1, 0x1
goto :goto_yesShow
:cond_noShow
const/4 v1, 0x0
:goto_yesShow
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V[/COLOR]
.line 825
:cond_2
return-void
:cond_3
move v0, v2
PART II, SystemUI.apk
Navigate to res/layout/tw_status_bar.xml
Code:
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginRight="4.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
</ImageSwitcher>
<com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_old" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_new" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.phone.TickerView>
</LinearLayout>
[COLOR="Blue"]<com.android.systemui.statusbar.policy.BatteryBarController android:visibility="gone" android:layout_width="fill_parent" android:layout_height="1.0dip" android:layout_alignParentTop="true" systemui:viewLocation="1" />[/COLOR]
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
Navigate to res/values/attrs
Code:
[COLOR="Blue"]<attr name="viewLocation" format="integer" />[/COLOR]
</resources>
Navigate to smali/com/android/systemui/statusbar/policy/Prefs.smali
add this :
Code:
.method public static read(Landroid/content/Context;)Landroid/content/SharedPreferences;
.locals 2
.parameter "context"
.prologue
.line 32
const-string v0, "status_bar"
const/4 v1, 0x0
invoke-virtual {p0, v0, v1}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;
move-result-object v0
return-object v0
.end method
[COLOR="Blue"].method public static getLastBatteryLevel(Landroid/content/Context;)I
.locals 3
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->read(Landroid/content/Context;)Landroid/content/SharedPreferences;
move-result-object v0
const-string v1, "last_battery_level"
const/16 v2, 0x32
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I
move-result v0
return v0
.end method
.method public static getLastFastChargeState(Landroid/content/Context;)Z
.locals 3
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->read(Landroid/content/Context;)Landroid/content/SharedPreferences;
move-result-object v0
const-string v1, "last_fcharge_state"
const/4 v2, 0x0
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z
move-result v0
return v0
.end method
.method public static setLastBatteryLevel(Landroid/content/Context;I)V
.locals 2
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->edit(Landroid/content/Context;)Landroid/content/SharedPreferences$Editor;
move-result-object v0
const-string v1, "last_battery_level"
invoke-interface {v0, v1, p1}, Landroid/content/SharedPreferences$Editor;->putInt(Ljava/lang/String;I)Landroid/content/SharedPreferences$Editor;
move-result-object v0
invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z
return-void
.end method
.method public static setLastFastChargeState(Landroid/content/Context;Z)V
.locals 2
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->edit(Landroid/content/Context;)Landroid/content/SharedPreferences$Editor;
move-result-object v0
const-string v1, "last_fcharge_state"
invoke-interface {v0, v1, p1}, Landroid/content/SharedPreferences$Editor;->putBoolean(Ljava/lang/String;Z)Landroid/content/SharedPreferences$Editor;
move-result-object v0
invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z
return-void
.end method[/COLOR]
Find the attached zip file and place all files in smali/com/android/systemui/statusbar/policy
Click to expand...
Click to collapse
Nice and keep kitul epriwer
syaeful said:
Original Guide is made by Didact74 here :
[MOD][GUIDE] Stand Alone Battery Bar w/Options and color picker
All credit to him and Kryten2k35 for some smali method
This guide allows you to add the battery bar to your ROM with out any Add-On APKs
Ok, let's go to guide!!!
We will be working with two files:
SystemUI.apk
SecSettings.apk
Note : Blue=add
PART I, Secsettings.apk
navigate to res/xml/display_settings.xml
Code:
[COLOR="Blue"]<PreferenceCategory android:title="@string/battery_bar_setting" android:key="battery_icon_category">
<ListPreference android:entries="@array/battery_bar_entries" android:title="@string/battery_bar" android:key="battery_bar" android:entryValues="@array/battery_bar_values" />
<ListPreference android:entries="@array/battery_bar_style_entries" android:title="@string/battery_bar_style_title" android:key="battery_bar_style" android:entryValues="@array/battery_bar_style_values" />
<ListPreference android:entries="@array/battery_bar_thickness_entries" android:title="@string/battery_bar_thickness_title" android:key="battery_bar_thickness" android:entryValues="@array/battery_bar_thickness_values" />
<CheckBoxPreference android:title="@string/battery_bar_animate_title" android:key="battery_bar_animate" android:summary="@string/battery_bar_animate_summary" />
</PreferenceCategory>[/COLOR]
<PreferenceCategory android:title="@string/more_settings" android:key="more_settings" />[/HIDE]
Navigate to res/values/arrays
Code:
[COLOR="Blue"]<string-array name="battery_bar_entries">
<item>Hide</item>
<item>Show</item>
</string-array>
<string-array name="battery_bar_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_style_entries">
<item>Regular</item>
<item>Center-mirrored</item>
</string-array>
<string-array name="battery_bar_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="battery_bar_thickness_entries">
<item>1 dp</item>
<item>2 dp</item>
<item>3 dp</item>
<item>4 dp</item>
</string-array>
<string-array name="battery_bar_thickness_values">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</string-array>[/COLOR]
</resources>
Navigate to res/values/strings
Code:
[COLOR="Blue"]<string name="battery_bar_setting">Battery Bar Setting</string>
<string name="battery_bar">Enable battery bar</string>
<string name="battery_bar_color">Choose battery bar color</string>
<string name="battery_bar_style_title">Battery bar style</string>
<string name="battery_bar_thickness_title">Battery Bar Thickness</string>
<string name="battery_bar_animate_title">Battery Bar Animation</string>
<string name="battery_bar_animate_summary">Animate bar when charging</string>
<string name="battery_bar_summary">%s</string>
<string name="battery_bar_color_summary">Bar color</string>
<string name="battery_bar_style_title_summary">%s</string>
<string name="battery_bar_thickness_title_summary">%s</string>[/COLOR]
</resources>
Navigate to com/android/setting/DisplaySettings.smali
Code:
.field private mAnimationView:Landroid/widget/ImageView;
.field private mAutoLockmode:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"].field mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
.field mBatteryBarList:Landroid/preference/ListPreference;
.field mBatteryBarStyle:Landroid/preference/ListPreference;
.field mBatteryBarThickness:Landroid/preference/ListPreference;[/COLOR]
go to : .method private updateState()V
Code:
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="Blue"]iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar"
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;->mBatteryBarStyle:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_style"
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;->mBatteryBarThickness:Landroid/preference/ListPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_thickness"
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[/COLOR]
.line 883
iget-boolean v0, p0, Lcom/android/settings/DisplaySettings;->mSupportFolderType:Z
if-eqz v0, :cond_0
.line 884
invoke-direct {p0}, Lcom/android/settings/DisplaySettings;->updateAccelerometerRotationSecondCheckbox()V
.line 885
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"
go to : .method public onCreate(Landroid/os/BundleV
Code:
const-string v10, "font_size"
invoke-virtual {p0, v10}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v10
check-cast v10, Landroid/preference/ListPreference;
iput-object v10, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
.line 428
iget-object v10, p0, Lcom/android/settings/DisplaySettings;->mFontSizePref:Landroid/preference/ListPreference;
invoke-virtual {v10, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
[COLOR="Blue"]const-string v11, "battery_bar"
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;->mBatteryBarList:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "battery_bar_style"
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;->mBatteryBarStyle:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarStyle:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
const-string v11, "battery_bar_thickness"
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;->mBatteryBarThickness:Landroid/preference/ListPreference;
iget-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarThickness:Landroid/preference/ListPreference;
invoke-virtual {v11, p0}, Landroid/preference/ListPreference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V[/COLOR]
.line 430
const-string v10, "display_battery_level"
still same method :
Code:
.line 553
const-string v10, "key_multi_window"
invoke-virtual {p0, v10}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v10
check-cast v10, Landroid/preference/CheckBoxPreference;
iput-object v10, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"]const-string v11, "battery_bar_animate"
invoke-virtual {p0, v11}, Lcom/android/settings/DisplaySettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v11
check-cast v11, Landroid/preference/CheckBoxPreference;
iput-object v11, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;[/COLOR]
.line 554
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v10
const-string v11, "com.sec.feature.multiwindow.phone"
go to : .method public onPreferenceChange(Landroid/preference/Preference;Ljava/lang/ObjectZ
Code:
.line 1071
const-string v1, "DisplaySettings"
const-string v2, "could not persist Touch key light setting"
invoke-static {v1, v2, v0}, Landroid/util/secutil/Log;->secE(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
goto/16 :goto_4
.line 1073
:cond_a
[COLOR="Blue"]const-string v2, "battery_bar_style"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_barstyle
.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, "battery_bar_style"
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;->mBatteryBarStyle: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;->mBatteryBarStyle:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarStyle: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_barstyle
const-string v2, "battery_bar"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_style
.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, "battery_bar"
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;->mBatteryBarList: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;->mBatteryBarList:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarList: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_style
const-string v2, "battery_bar_thickness"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_tickness
.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, "battery_bar_thickness"
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;->mBatteryBarThickness: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;->mBatteryBarThickness:Landroid/preference/ListPreference;
iget-object v1, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarThickness: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_tickness[/COLOR]
const-string v2, "quick_launch"
invoke-virtual {v2, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v2
go to : .method public onPreferenceTreeClick(Landroid/preference/PreferenceScreen;Landroid/preference/PreferenceZ
BEFORE :
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, [COLOR="DarkOrange"]:cond_0[/COLOR]
.line 990
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 991
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
if-eqz v0, :cond_16
:goto_a
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 [COLOR="Yellow"]:goto_1[/COLOR]
:cond_16
move v1, v2
goto :goto_a
.end method
AFTER :
Code:
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, [COLOR="Blue"]:cond_batteryAnimate[/COLOR] <-- (change from ":cond_0" to new cond below = :cond_batteryAnimate)
.line 990
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 991
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
if-eqz v0, :cond_16
:goto_a
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 [COLOR="Yellow"]:goto_1[/COLOR]
:cond_16
move v1, v2
goto :goto_a
[COLOR="Blue"]:cond_batteryAnimate
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v0}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-eqz v0,[/COLOR] [COLOR="DarkOrange"]:cond_0[/COLOR] <-- (this cond is from old cond i'm marked orange)
[COLOR="Blue"].line 1022
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {v0}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v0
.line 1023
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_animate"
if-eqz v0, :cond_battAnim
:goto_anM
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16[/COLOR] [COLOR="Yellow"]:goto_1[/COLOR] <--- (this cond is from cond above i'm marked yellow)
[COLOR="Blue"] :cond_battAnim
move v1, v2
goto :goto_anM[/COLOR]
.end method
go to : .method public onResume()V
BEFORE :
Code:
.line 821
:cond_1
sget-boolean v0, Lcom/android/settings/DisplaySettings;->UseMultiWindow:Z
if-eqz v0, [COLOR="Yellow"]:cond_2[/COLOR]
.line 822
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-ne v3, v1, :cond_6
:goto_2
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 823
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "multi_window_enabled"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowModeObserver:Landroid/database/ContentObserver;
invoke-virtual {v0, v1, v2, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 825
:cond_2
return-void
:cond_3
move v0, v2
AFTER :
Code:
.line 821
:cond_1
sget-boolean v0, Lcom/android/settings/DisplaySettings;->UseMultiWindow:Z
if-eqz v0, [COLOR="Blue"]:cond_newAnim[/COLOR]
.line 822
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowPref:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "multi_window_enabled"
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-ne v3, v1, :cond_6
:goto_2
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 823
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
const-string v1, "multi_window_enabled"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
iget-object v3, p0, Lcom/android/settings/DisplaySettings;->mMultiWindowModeObserver:Landroid/database/ContentObserver;
invoke-virtual {v0, v1, v2, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
[COLOR="Blue"]:cond_newAnim
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
if-eqz v0,[/COLOR][COLOR="Yellow"] :cond_2[/COLOR]
[COLOR="Blue"].line 3001
iget-object v0, p0, Lcom/android/settings/DisplaySettings;->mBatteryBarAnimate:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/DisplaySettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string v4, "battery_bar_animate"
const/4 v1, 0x0
invoke-static {v3, v4, v1}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
if-eqz v3, :cond_noShow
const/4 v1, 0x1
goto :goto_yesShow
:cond_noShow
const/4 v1, 0x0
:goto_yesShow
invoke-virtual {v0, v1}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V[/COLOR]
.line 825
:cond_2
return-void
:cond_3
move v0, v2
PART II, SystemUI.apk
Navigate to res/layout/tw_status_bar.xml
Code:
<LinearLayout android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="6.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
<ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginRight="4.0dip">
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
</ImageSwitcher>
<com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" android:paddingTop="2.0dip" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_old" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:id="@id/ticker_text_view_new" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
</com.android.systemui.statusbar.phone.TickerView>
</LinearLayout>
[COLOR="Blue"]<com.android.systemui.statusbar.policy.BatteryBarController android:visibility="gone" android:layout_width="fill_parent" android:layout_height="1.0dip" android:layout_alignParentTop="true" systemui:viewLocation="1" />[/COLOR]
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
Navigate to res/values/attrs
Code:
[COLOR="Blue"]<attr name="viewLocation" format="integer" />[/COLOR]
</resources>
Navigate to smali/com/android/systemui/statusbar/policy/Prefs.smali
add this :
Code:
.method public static read(Landroid/content/Context;)Landroid/content/SharedPreferences;
.locals 2
.parameter "context"
.prologue
.line 32
const-string v0, "status_bar"
const/4 v1, 0x0
invoke-virtual {p0, v0, v1}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;
move-result-object v0
return-object v0
.end method
[COLOR="Blue"].method public static getLastBatteryLevel(Landroid/content/Context;)I
.locals 3
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->read(Landroid/content/Context;)Landroid/content/SharedPreferences;
move-result-object v0
const-string v1, "last_battery_level"
const/16 v2, 0x32
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I
move-result v0
return v0
.end method
.method public static getLastFastChargeState(Landroid/content/Context;)Z
.locals 3
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->read(Landroid/content/Context;)Landroid/content/SharedPreferences;
move-result-object v0
const-string v1, "last_fcharge_state"
const/4 v2, 0x0
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z
move-result v0
return v0
.end method
.method public static setLastBatteryLevel(Landroid/content/Context;I)V
.locals 2
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->edit(Landroid/content/Context;)Landroid/content/SharedPreferences$Editor;
move-result-object v0
const-string v1, "last_battery_level"
invoke-interface {v0, v1, p1}, Landroid/content/SharedPreferences$Editor;->putInt(Ljava/lang/String;I)Landroid/content/SharedPreferences$Editor;
move-result-object v0
invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z
return-void
.end method
.method public static setLastFastChargeState(Landroid/content/Context;Z)V
.locals 2
invoke-static {p0}, Lcom/android/systemui/statusbar/policy/Prefs;->edit(Landroid/content/Context;)Landroid/content/SharedPreferences$Editor;
move-result-object v0
const-string v1, "last_fcharge_state"
invoke-interface {v0, v1, p1}, Landroid/content/SharedPreferences$Editor;->putBoolean(Ljava/lang/String;Z)Landroid/content/SharedPreferences$Editor;
move-result-object v0
invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z
return-void
.end method[/COLOR]
Find the attached zip file and place all files in smali/com/android/systemui/statusbar/policy
Click to expand...
Click to collapse
PL: you're send for me file DisplaySettings.smali in mod rom your
nice guide sir :good:

[Guide][Smali][CM11] How to add toast animations

Hallo All
I want to share how to add animation toast .. with settings..
What can be done with this MOD ?
Click to expand...
Click to collapse
This mod will allow you to have Toast with various types of animations , and can change it without need reboot
Here is a video of what I mean..
okey lets go to Guide:
first of all need some requirement for this MOD-GUIDE
REQUIREMENT:
- BRAIN
- Patient
- experience
- Know how to decompile/recompiling Apk and JAR file
- Tool for decompiling, : apktool/apkmultitools/ or else (I am currently using apktool 1.5.2)
- notepad++
Settings.apk
Decompile your settings.apk
- Download attached file and merge it to your decompiled Settings.apk
- Settings.apk\res\values\arrays.xml
add this lines to end of it before </resources>
Code:
<string-array name="toast_animation_entries">
<item>@string/toast_none_animation</item>
<item>@string/toast_default_animation</item>
<item>@string/toast_fade_animation</item>
<item>@string/toast_SlideLeftRight_animation</item>
<item>@string/toast_SlideRightLeft_animation</item>
<item>@string/toast_SlideRight_animation</item>
<item>@string/toast_SlideLeft_animation</item>
<item>@string/toast_Xylon_animation</item>
<item>@string/toast_Toko_animation</item>
<item>@string/toast_Tn_animation</item>
<item>@string/toast_Honami_animation</item>
<item>@string/toast_FastFade_animation</item>
<item>@string/toast_GrowFade_animation</item>
<item>@string/toast_GrowFadeCenter_animation</item>
<item>@string/toast_GrowFadeBottom_animation</item>
<item>@string/toast_Translucent_animation</item>
</string-array>
<string-array name="toast_animation_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>10</item>
<item>11</item>
<item>12</item>
<item>13</item>
<item>14</item>
<item>15</item>
</string-array>
- Settings.apk\res\values\strings.xml
add this lines to end of it before </resources>
Code:
<string name="toast_animation_title">Toast animations</string>
<string name="toast_none_animation">None</string>
<string name="toast_default_animation">Default</string>
<string name="toast_fade_animation">Fade Animation</string>
<string name="toast_SlideRight_animation">SlideRight Animation</string>
<string name="toast_SlideLeft_animation">SlideLeft Animation</string>
<string name="toast_Xylon_animation">Xylon Animation</string>
<string name="toast_Toko_animation">Toko Animation</string>
<string name="toast_Tn_animation">Tn Animation</string>
<string name="toast_Honami_animation">Honami Animation</string>
<string name="toast_FastFade_animation">FastFade Animation</string>
<string name="toast_GrowFade_animation">GrowFade Animation</string>
<string name="toast_GrowFadeCenter_animation">GrowFadeCenter Animation</string>
<string name="toast_GrowFadeBottom_animation">GrowFadeBottom Animation</string>
<string name="toast_Translucent_animation">Translucent Animation</string>
<string name="toast_SlideLeftRight_animation">Slide Left To Right Animation</string>
<string name="toast_SlideRightLeft_animation">Slide Right To Left Animation</string>
- Settings.apk\res\xml\display_settings.xml
put this line
Code:
[COLOR="Red"]<PreferenceScreen android:title="@string/toast_animation_title" android:key="toast_animation" android:fragment="com.android.settings.cyanogenmod.ToastSettings" />[/COLOR]
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">
<com.android.settings.BrightnessPreference android:persistent="false" android:title="@string/brightness" />
[COLOR="Red"]<PreferenceScreen android:title="@string/toast_animation_title" android:key="toast_animation" android:fragment="com.android.settings.cyanogenmod.ToastSettings" />[/COLOR]
<PreferenceCategory android:title="@string/display_settings_title" android:key="display_prefs">
<PreferenceScreen android:title="@string/display_rotation_title" android:key="display_rotation" android:fragment="com.android.settings.cyanogenmod.DisplayRotation" />
<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:entryValues="@array/screen_timeout_values" />
<com.android.settings.FontDialogPreference android:title="@string/title_font_size" android:key="font_size" android:summary="@string/summary_font_size" android:dialogTitle="@string/dialog_title_font_size" />
<PreferenceScreen android:title="@string/screensaver_settings_title" android:key="screensaver" android:fragment="com.android.settings.DreamSettings" />
<PreferenceScreen android:title="@string/wifi_display_settings_title" android:key="wifi_display" android:fragment="com.android.settings.wfd.WifiDisplaySettings" />
</PreferenceCategory>
but you can put the line whereever you like,.. Can be placed in other xml
- Recompile your Settings.apk
- Decompile the newly recompiled APK again
go to your secondly decompiled Settings.apk\res\values\public.xml
and let it stay open .
Pay attention to this 0x7f?????? !!!
- Now go to Settings.apk\smali\com\android\settings\cyanogenmod\ToastSettings.smali
search this -> const v21, 0x7f05007a
change this -> 0x7f05007a , according to the value you got in your own public.xml
Code:
<public type="xml" name="toast_settings" id="0x7f?????? />
- Done and save
- Recompile it
- Next, go to framework-res.apk...
framework-res.apk
Decompile your framework-res.apk
- Download attached file and merge it to your decompiled framework-res.apk
- framework-res.apk\res\values\styles.xml
add this lines to end of it before </resources>
Code:
<style name="Animation.Toast.Fade" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/fade_in</item>
<item name="windowExitAnimation">@anim/fade_out</item>
</style>
<style name="Animation.Toast.SlideRight" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/slide_in_right</item>
<item name="windowExitAnimation">@anim/slide_out_right</item>
</style>
<style name="Animation.Toast.SlideLeft" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/slide_in_left</item>
<item name="windowExitAnimation">@anim/slide_out_left</item>
</style>
<style name="Animation.Toast.SlideRightLeft" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/slide_in_right</item>
<item name="windowExitAnimation">@anim/slide_out_left</item>
</style>
<style name="Animation.Toast.SlideLeftRight" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/slide_in_left</item>
<item name="windowExitAnimation">@anim/slide_out_right</item>
</style>
<style name="Animation.Toast.Xylon" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/xylon_toast_enter</item>
<item name="windowExitAnimation">@anim/xylon_toast_exit</item>
</style>
<style name="Animation.Toast.Toko" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/toko_toast_enter</item>
<item name="windowExitAnimation">@anim/toko_toast_exit</item>
</style>
<style name="Animation.Toast.Tn" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/tn_toast_enter</item>
<item name="windowExitAnimation">@anim/tn_toast_exit</item>
</style>
<style name="Animation.Toast.Honami" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/honami_toast_enter</item>
<item name="windowExitAnimation">@anim/honami_toast_exit</item>
</style>
<style name="Animation.Toast.FastFade" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/fast_fade_in</item>
<item name="windowExitAnimation">@anim/fast_fade_out</item>
</style>
<style name="Animation.Toast.GrowFade" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/grow_fade_in</item>
<item name="windowExitAnimation">@anim/fast_fade_out</item>
</style>
<style name="Animation.Toast.GrowFadeCenter" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/grow_fade_in_center</item>
<item name="windowExitAnimation">@anim/fast_fade_out</item>
</style>
<style name="Animation.Toast.GrowFadeBottom" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/grow_fade_in_from_bottom</item>
<item name="windowExitAnimation">@anim/fast_fade_out</item>
</style>
<style name="Animation.Toast.Translucent" parent="@style/Animation.Toast">
<item name="windowEnterAnimation">@anim/translucent_enter</item>
<item name="windowExitAnimation">@anim/translucent_exit</item>
</style>
- save and Recompile it
- Decompile the newly recompiled APK again
go to your secondly decompiled framework-res.apk\res\values\public.xml
and let it stay open ...
- Now go to framework.jar...
framework.jar
- Decompile/baksmali your framework.jar
- Navigate to framework.jar.out/smali/android/widget/Toast$TN.smali
- search .method public handleShow()V
Code:
.method public handleShow()V
.locals 6
.prologue
const/high16 v5, 0x3f80
.line 376
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
iget-object v4, p0, Landroid/widget/Toast$TN;->mNextView:Landroid/view/View;
if-eq v3, v4, :cond_4
.line 378
invoke-virtual {p0}, Landroid/widget/Toast$TN;->handleHide()V
.line 379
iget-object v3, p0, Landroid/widget/Toast$TN;->mNextView:Landroid/view/View;
iput-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
.line 380
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v3
invoke-virtual {v3}, Landroid/content/Context;->getApplicationContext()Landroid/content/Context;
move-result-object v1
.line 381
.local v1, context:Landroid/content/Context;
if-nez v1, :cond_0
.line 382
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v1
.line 384
:cond_0
const-string/jumbo v3, "window"
invoke-virtual {v1, v3}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v3
check-cast v3, Landroid/view/WindowManager;
iput-object v3, p0, Landroid/widget/Toast$TN;->mWM:Landroid/view/WindowManager;
.line 387
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v3
invoke-virtual {v3}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v3
invoke-virtual {v3}, Landroid/content/res/Resources;->getConfiguration()Landroid/content/res/Configuration;
move-result-object v0
.line 388
.local v0, config:Landroid/content/res/Configuration;
iget v3, p0, Landroid/widget/Toast$TN;->mGravity:I
invoke-virtual {v0}, Landroid/content/res/Configuration;->getLayoutDirection()I
move-result v4
invoke-static {v3, v4}, Landroid/view/Gravity;->getAbsoluteGravity(II)I
move-result v2
.line 389
.local v2, gravity:I
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iput v2, v3, Landroid/view/WindowManager$LayoutParams;->gravity:I
.line 390
and-int/lit8 v3, v2, 0x7
const/4 v4, 0x7
if-ne v3, v4, :cond_1
.line 391
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iput v5, v3, Landroid/view/WindowManager$LayoutParams;->horizontalWeight:F
.line 393
:cond_1
and-int/lit8 v3, v2, 0x70
const/16 v4, 0x70
if-ne v3, v4, :cond_2
.line 394
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iput v5, v3, Landroid/view/WindowManager$LayoutParams;->verticalWeight:F
.line 396
:cond_2
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mX:I
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->x:I
.line 397
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mY:I
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->y:I
.line 398
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mVerticalMargin:F
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->verticalMargin:F
.line 399
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mHorizontalMargin:F
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->horizontalMargin:F
.line 400
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getParent()Landroid/view/ViewParent;
move-result-object v3
if-eqz v3, :cond_3
.line 402
iget-object v3, p0, Landroid/widget/Toast$TN;->mWM:Landroid/view/WindowManager;
iget-object v4, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-interface {v3, v4}, Landroid/view/WindowManager;->removeView(Landroid/view/View;)V
.line 405
:cond_3
iget-object v3, p0, Landroid/widget/Toast$TN;->mWM:Landroid/view/WindowManager;
iget-object v4, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
iget-object v5, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
invoke-interface {v3, v4, v5}, Landroid/view/WindowManager;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 406
invoke-direct {p0}, Landroid/widget/Toast$TN;->trySendAccessibilityEvent()V
.line 408
.end local v0 #config:Landroid/content/res/Configuration;
.end local v1 #context:Landroid/content/Context;
.end local v2 #gravity:I
:cond_4
return-void
.end method
- Replace all with this :
Code:
[COLOR="Red"].method public handleShow()V
.locals 7
.prologue
const/high16 v6, 0x3f80
.line 377
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
iget-object v4, p0, Landroid/widget/Toast$TN;->mNextView:Landroid/view/View;
if-eq v3, v4, :cond_4
.line 379
invoke-virtual {p0}, Landroid/widget/Toast$TN;->handleHide()V
.line 380
iget-object v3, p0, Landroid/widget/Toast$TN;->mNextView:Landroid/view/View;
iput-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
.line 381
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v3
invoke-virtual {v3}, Landroid/content/Context;->getApplicationContext()Landroid/content/Context;
move-result-object v1
.line 382
.local v1, context:Landroid/content/Context;
if-nez v1, :cond_0
.line 383
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v1
.line 385
:cond_0
const-string/jumbo v3, "window"
invoke-virtual {v1, v3}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v3
check-cast v3, Landroid/view/WindowManager;
iput-object v3, p0, Landroid/widget/Toast$TN;->mWM:Landroid/view/WindowManager;
.line 388
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getContext()Landroid/content/Context;
move-result-object v3
invoke-virtual {v3}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v3
invoke-virtual {v3}, Landroid/content/res/Resources;->getConfiguration()Landroid/content/res/Configuration;
move-result-object v0
.line 389
.local v0, config:Landroid/content/res/Configuration;
iget v3, p0, Landroid/widget/Toast$TN;->mGravity:I
invoke-virtual {v0}, Landroid/content/res/Configuration;->getLayoutDirection()I
move-result v4
invoke-static {v3, v4}, Landroid/view/Gravity;->getAbsoluteGravity(II)I
move-result v2
.line 390
.local v2, gravity:I
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v3
const-string/jumbo v4, "toast_animation"
const/4 v5, 0x1
invoke-static {v3, v4, v5}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
packed-switch v3, :pswitch_data_0
.line 440
:goto_0
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iput v2, v3, Landroid/view/WindowManager$LayoutParams;->gravity:I
.line 441
and-int/lit8 v3, v2, 0x7
const/4 v4, 0x7
if-ne v3, v4, :cond_1
.line 442
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iput v6, v3, Landroid/view/WindowManager$LayoutParams;->horizontalWeight:F
.line 444
:cond_1
and-int/lit8 v3, v2, 0x70
const/16 v4, 0x70
if-ne v3, v4, :cond_2
.line 445
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iput v6, v3, Landroid/view/WindowManager$LayoutParams;->verticalWeight:F
.line 447
:cond_2
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mX:I
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->x:I
.line 448
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mY:I
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->y:I
.line 449
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mVerticalMargin:F
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->verticalMargin:F
.line 450
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
iget v4, p0, Landroid/widget/Toast$TN;->mHorizontalMargin:F
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->horizontalMargin:F
.line 451
iget-object v3, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getParent()Landroid/view/ViewParent;
move-result-object v3
if-eqz v3, :cond_3
.line 453
iget-object v3, p0, Landroid/widget/Toast$TN;->mWM:Landroid/view/WindowManager;
iget-object v4, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
invoke-interface {v3, v4}, Landroid/view/WindowManager;->removeView(Landroid/view/View;)V
.line 456
:cond_3
iget-object v3, p0, Landroid/widget/Toast$TN;->mWM:Landroid/view/WindowManager;
iget-object v4, p0, Landroid/widget/Toast$TN;->mView:Landroid/view/View;
iget-object v5, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
invoke-interface {v3, v4, v5}, Landroid/view/WindowManager;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 457
invoke-direct {p0}, Landroid/widget/Toast$TN;->trySendAccessibilityEvent()V
.line 459
.end local v0 #config:Landroid/content/res/Configuration;
.end local v1 #context:Landroid/content/Context;
.end local v2 #gravity:I
:cond_4
return-void
.line 392
.restart local v0 #config:Landroid/content/res/Configuration;
.restart local v1 #context:Landroid/content/Context;
.restart local v2 #gravity:I
:pswitch_0
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const/4 v4, -0x1
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 395
:pswitch_1
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030004
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 398
:pswitch_2
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030324
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 401
:pswitch_3
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030328
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 404
:pswitch_4
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030327
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 407
:pswitch_5
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030325
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 410
:pswitch_6
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030326
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto :goto_0
.line 413
:pswitch_7
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030329
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 416
:pswitch_8
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x103032a
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 419
:pswitch_9
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x103032b
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 422
:pswitch_a
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x103032c
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 425
:pswitch_b
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x103032d
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 428
:pswitch_c
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x103032e
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 431
:pswitch_d
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x103032f
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 434
:pswitch_e
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030330
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 437
:pswitch_f
iget-object v3, p0, Landroid/widget/Toast$TN;->mParams:Landroid/view/WindowManager$LayoutParams;
const v4, 0x1030331
iput v4, v3, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
goto/16 :goto_0
.line 390
nop
:pswitch_data_0
.packed-switch 0x0
:pswitch_0
:pswitch_1
:pswitch_2
:pswitch_3
:pswitch_4
:pswitch_5
:pswitch_6
:pswitch_7
:pswitch_8
:pswitch_9
:pswitch_a
:pswitch_b
:pswitch_c
:pswitch_d
:pswitch_e
:pswitch_f
.end packed-switch
.end method[/COLOR]
- Then search const v4, 0x1030004
ATTENTION! id public for framework.jar
just TAKE the BLUE CODE
and SKIP the RED CODE
1. change this -> 0x1030004 , according to the value you got in your own public.xml of framework-res.apk
Code:
<public type="style" name="Animation.Toast" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
do it too to all lines below, in the smali
2. const v4, 0x1030324
Code:
<public type="style" name="Animation.Toast.Fade" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
3. const v4, 0x1030328
Code:
<public type="style" name="Animation.Toast.SlideLeftRight" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
4. const v4, 0x1030327
Code:
<public type="style" name="Animation.Toast.SlideRightLeft" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
5. const v4, 0x1030325
Code:
<public type="style" name="Animation.Toast.SlideRight" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
6. const v4, 0x1030326
Code:
<public type="style" name="Animation.Toast.SlideLeft" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
7. const v4, 0x1030329
Code:
<public type="style" name="Animation.Toast.Xylon" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
8. const v4, 0x103032a
Code:
<public type="style" name="Animation.Toast.Toko" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
9. const v4, 0x103032b
Code:
<public type="style" name="Animation.Toast.Tn" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
10. const v4, 0x103032c
Code:
<public type="style" name="Animation.Toast.Honami" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
11. const v4, 0x103032d
Code:
<public type="style" name="Animation.Toast.FastFade" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
12. const v4, 0x103032e
Code:
<public type="style" name="Animation.Toast.GrowFade" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
13. const v4, 0x103032f
Code:
<public type="style" name="Animation.Toast.GrowFadeCenter" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
14. const v4, 0x1030330
Code:
<public type="style" name="Animation.Toast.GrowFadeBottom" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
15. const v4, 0x1030331
Code:
<public type="style" name="Animation.Toast.Translucent" id="[COLOR="Blue"]0x[/COLOR][COLOR="Red"]0[/COLOR][COLOR="Blue"]???????[/COLOR] />
- save and Recompile it
if all thats finished .. then input all to system .. , can be manual , and can also use flashable.zip ,,
make sure you BACKUP first ,
make sure you BACKUP first ,
make sure you BACKUP first ,
Have Nice Moding..
Good Luck
reserved..
reserved...
I love this tutorials! Thank you very much!
It's working on Note3 N9005MIUIv6 (4.4.2 TouchWiz based), with some lines slighty retouched. All it's working fine (menu, animations), but produces FC when I select one of the anims, before "preview toast" show up. Logcat indicates the app stops at tag .line 659, (ToastSettings.smali)
move-result-object v8
aget-object v8, v8, v2
invoke-virtual {v5, v8}, Landroid/preference/ListPreference;->setSummary(Ljava/lang/CharSequenceV
.line 659
iget-object v5, p0, Lcom/android/settings/cyanogenmod/ToastSettings;->mContext:Landroid/content/Context;
const-string v8, "Test toast animation"
invoke-static {v5, v8, v7}, Landroid/widget/Toast;->makeText(Landroid/content/Context;Ljava/lang/CharSequence;I)Landroid/widget/Toast;
move-result-object v5
invoke-virtual {v5}, Landroid/widget/Toast;->show()V
goto :goto_1
I don't know how fix this small part. Thanks in advance.
PD: I´m using framework2.jar instead of framework.jar
Atrankas said:
I love this tutorials! Thank you very much!
It's working on Note3 N9005MIUIv6 (4.4.2 TouchWiz based), with some lines slighty retouched. All it's working fine (menu, animations), but produces FC when I select one of the anims, before "preview toast" show up. Logcat indicates the app stops at tag .line 659, (ToastSettings.smali)
move-result-object v8
aget-object v8, v8, v2
invoke-virtual {v5, v8}, Landroid/preference/ListPreference;->setSummary(Ljava/lang/CharSequenceV
.line 659
iget-object v5, p0, Lcom/android/settings/cyanogenmod/ToastSettings;->mContext:Landroid/content/Context;
const-string v8, "Test toast animation"
invoke-static {v5, v8, v7}, Landroid/widget/Toast;->makeText(Landroid/content/Context;Ljava/lang/CharSequence;I)Landroid/widget/Toast;
move-result-object v5
invoke-virtual {v5}, Landroid/widget/Toast;->show()V
goto :goto_1
I don't know how fix this small part. Thanks in advance.
PD: I´m using framework2.jar instead of framework.jar
Click to expand...
Click to collapse
use smali on attachments
- add on strings.xml
Code:
<string name="toast_test_animation">Test toast animation</string>
- decompile-recompile
- change ids
Code:
const v1, 0x7f050077 ---------- <public type="xml" name="toast_settings" id=
const v5, 0x7f080ca1 ---------- <public type="string" name="toast_test_animation" id=
- recompile
Thanks for your reply, @qoejohn. I have the same error with this new code (FC when I touch one of the element from the list, but the animation is applied correctly).
Logcat
java.lang.NoSuchFieldError:
com.android.settings.cyanogenmod.ToastSettings.mContext
at
com.android.settings.cyanogenmod.ToastSettings.onPreferenceChange(ToastSettings.java:659)
at
android.preference.Preference.callChangeListener(Preference.java)
at
android.preference.ListPreference.onDialogClosed(ListPreference.java)
at
android.preference.DialogPreference.onDismiss(DialogPreference.java)
at
android.app.Dialog$ListenersHandler.handleMessage(Dialog.java)
at android.os.Handler.dispatchMessage(Handler.java)
at android.os.Looper.loop(Looper.java)
at android.app.ActivityThread.main(ActivityThread.java)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
at dalvik.system.NativeStart.main(Native Method)
On the other hand, if I replace the line in xml
<PreferenceScreen android:title="@string/toast_animation_title" android:key="toast_animation" android:fragment="com.android.settings.cyanogenmod.ToastSettings" />
with
<PreferenceScreen android:title="@string/toast_animation_title" android:key="toast_animation" android:fragment="com.android.settings.cyanogenmod.animations.ToastAnimationInterfaceSettings" /> ,the FC is gone, but no effect is applied.
I'll keep on trying, thanks for your time
Atrankas said:
Thanks for your reply, @qoejohn. I have the same error with this new code (FC when I touch one of the element from the list, but the animation is applied correctly).
Logcat
java.lang.NoSuchFieldError:
com.android.settings.cyanogenmod.ToastSettings.mContext
at
com.android.settings.cyanogenmod.ToastSettings.onPreferenceChange(ToastSettings.java:659)
at
android.preference.Preference.callChangeListener(Preference.java)
at
android.preference.ListPreference.onDialogClosed(ListPreference.java)
at
android.preference.DialogPreference.onDismiss(DialogPreference.java)
at
android.app.Dialog$ListenersHandler.handleMessage(Dialog.java)
at android.os.Handler.dispatchMessage(Handler.java)
at android.os.Looper.loop(Looper.java)
at android.app.ActivityThread.main(ActivityThread.java)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
at dalvik.system.NativeStart.main(Native Method)
On the other hand, if I replace the line in xml
<PreferenceScreen android:title="@string/toast_animation_title" android:key="toast_animation" android:fragment="com.android.settings.cyanogenmod.ToastSettings" />
with
<PreferenceScreen android:title="@string/toast_animation_title" android:key="toast_animation" android:fragment="com.android.settings.cyanogenmod.animations.ToastAnimationInterfaceSettings" /> ,the FC is gone, but no effect is applied.
I'll keep on trying, thanks for your time
Click to expand...
Click to collapse
change smali on .jar,, with this
and change id's
on const-string v8, "Test toast animation" change to const-string v8, "test_toast_animation" save and recompile

Categories

Resources