Related
Hi Guys
I have a Samsung GT-S5570 Galaxy Mini and want to change the color of the clock in the status bar, I was reviewing some options and come to decompile the file services.odex, I have seen options to change the color but I have not yet been possible, help me?
PD: Sorry for me english
My File StatusBarIcon.smali
.class Lcom/android/server/status/StatusBarIcon;
.super Ljava/lang/Object;
.source "StatusBarIcon.java"
# static fields
.field private static final ICON_GAP:I = 0x8
.field private static final ICON_HEIGHT:I = 0x19
.field private static final ICON_WIDTH:I = 0x19
# instance fields
.field mData:Lcom/android/server/status/IconData;
.field private mImageView:Lcom/android/server/status/AnimatedImageView;
.field private mNumberView:Landroid/widget/TextView;
.field private mTextView:Landroid/widget/TextView;
.field public view:Landroid/view/View;
# direct methods
.method public constructor <init>(Landroid/content/Context;Lcom/android/server/status/IconData;Landroid/view/ViewGroupV
.registers 13
.parameter "context"
.parameter "data"
.parameter "parent"
.prologue
const/4 v7, -0x1
const/4 v8, 0x0
.line 50
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 51
invoke-virtual {p2}, Lcom/android/server/status/IconData;->clone()Lcom/android/server/status/IconData;
move-result-object v6
iput-object v6, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
.line 53
iget v6, p2, Lcom/android/server/status/IconData;->type:I
packed-switch v6, switch_data_9a
.line 97
:goto_10
return-void
.line 56
switch_11
new-instance v4, Landroid/widget/TextView;
invoke-direct {v4, p1}, Landroid/widget/TextView;-><init>(Landroid/content/ContextV
.line 57
.local v4, t:Landroid/widget/TextView;
iput-object v4, p0, Lcom/android/server/status/StatusBarIcon;->mTextView:Landroid/widget/TextView;
.line 58
new-instance v2, Landroid/widget/LinearLayout$LayoutParams;
const/4 v6, -0x2
invoke-direct {v2, v6, v7}, Landroid/widget/LinearLayout$LayoutParams;-><init>(II)V
.line 61
.local v2, layoutParams:Landroid/widget/LinearLayout$LayoutParams;
const/high16 v6, 0x4180
invoke-virtual {v4, v6}, Landroid/widget/TextView;->setTextSize(F)V
.line 62
invoke-virtual {v4, v7}, Landroid/widget/TextView;->setTextColor(I)V
.line 63
sget-object v6, Landroid/graphics/Typeface;->DEFAULT_BOLD:Landroid/graphics/Typeface;
invoke-virtual {v4, v6}, Landroid/widget/TextView;->setTypeface(Landroid/graphics/TypefaceV
.line 64
const/16 v6, 0x13
invoke-virtual {v4, v6}, Landroid/widget/TextView;->setGravity(I)V
.line 65
const/4 v6, 0x6
invoke-virtual {v4, v6, v8, v8, v8}, Landroid/widget/TextView;->setPadding(IIII)V
.line 66
invoke-virtual {v4, v2}, Landroid/widget/TextView;->setLayoutParams(Landroid/view/ViewGroup$LayoutParamsV
.line 67
iget-object v6, p2, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;
invoke-virtual {v4, v6}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
.line 68
iput-object v4, p0, Lcom/android/server/status/StatusBarIcon;->view:Landroid/view/View;
goto :goto_10
.line 74
.end local v2 #layoutParams:Landroid/widget/LinearLayout$LayoutParams;
.end local v4 #t:Landroid/widget/TextView;
switch_3f
const-string v6, "layout_inflater"
invoke-virtual {p1, v6}, Landroid/content/Context;->getSystemService(Ljava/lang/StringLjava/lang/Object;
move-result-object v1
check-cast v1, Landroid/view/LayoutInflater;
.line 76
.local v1, inflater:Landroid/view/LayoutInflater;
const v6, 0x1090064
invoke-virtual {v1, v6, p3, v8}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;Z)Landroid/view/View;
move-result-object v5
.line 77
.local v5, v:Landroid/view/View;
iput-object v5, p0, Lcom/android/server/status/StatusBarIcon;->view:Landroid/view/View;
.line 80
const v6, 0x102017e
invoke-virtual {v5, v6}, Landroid/view/View;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Lcom/android/server/status/AnimatedImageView;
.line 81
.local v0, im:Lcom/android/server/status/AnimatedImageView;
invoke-static {p1, p2}, Lcom/android/server/status/StatusBarIcon;->getIcon(Landroid/content/Context;Lcom/android/server/status/IconDataLandroid/graphics/drawable/Drawable;
move-result-object v6
invoke-virtual {v0, v6}, Lcom/android/server/status/AnimatedImageView;->setImageDrawable(Landroid/graphics/drawable/DrawableV
.line 82
iget v6, p2, Lcom/android/server/status/IconData;->iconLevel:I
invoke-virtual {v0, v6}, Lcom/android/server/status/AnimatedImageView;->setImageLevel(I)V
.line 83
iput-object v0, p0, Lcom/android/server/status/StatusBarIcon;->mImageView:Lcom/android/server/status/AnimatedImageView;
.line 86
const v6, 0x1020055
invoke-virtual {v5, v6}, Landroid/view/View;->findViewById(I)Landroid/view/View;
move-result-object v3
check-cast v3, Landroid/widget/TextView;
.line 87
.local v3, nv:Landroid/widget/TextView;
iput-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mNumberView:Landroid/widget/TextView;
.line 88
iget v6, p2, Lcom/android/server/status/IconData;->number:I
if-lez v6, :cond_93
.line 89
new-instance v6, Ljava/lang/StringBuilder;
invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V
const-string v7, ""
invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v6
iget v7, p2, Lcom/android/server/status/IconData;->number:I
invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
move-result-object v6
invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v6
invoke-virtual {v3, v6}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
.line 90
invoke-virtual {v3, v8}, Landroid/widget/TextView;->setVisibility(I)V
goto/16 :goto_10
.line 92
:cond_93
const/16 v6, 0x8
invoke-virtual {v3, v6}, Landroid/widget/TextView;->setVisibility(I)V
goto/16 :goto_10
.line 53
switch_data_9a
.packed-switch 0x1
switch_11
switch_3f
.end packed-switch
.end method
.method static getIcon(Landroid/content/Context;Lcom/android/server/status/IconDataLandroid/graphics/drawable/Drawable;
.registers 9
.parameter "context"
.parameter "data"
.prologue
const/4 v5, 0x0
const-string v6, "StatusBar"
.line 155
const/4 v2, 0x0
.line 157
.local v2, r:Landroid/content/res/Resources;
iget-object v3, p1, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
if-eqz v3, :cond_50
.line 159
:try_start_8
invoke-virtual {p0}, Landroid/content/Context;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v3
iget-object v4, p1, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
invoke-virtual {v3, v4}, Landroid/content/pm/PackageManager;->getResourcesForApplication(Ljava/lang/StringLandroid/content/res/Resources;
:try_end_11
.catch Landroid/content/pm/PackageManager$NameNotFoundException; {:try_start_8 .. :try_end_11} :catch_32
move-result-object v2
.line 168
:goto_12
iget v3, p1, Lcom/android/server/status/IconData;->iconId:I
if-nez v3, :cond_55
.line 169
const-string v3, "StatusBar"
new-instance v3, Ljava/lang/StringBuilder;
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
const-string v4, "No icon ID for slot "
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
iget-object v4, p1, Lcom/android/server/status/IconData;->slot:Ljava/lang/String;
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v3
invoke-static {v6, v3}, Landroid/util/Slog;->w(Ljava/lang/String;Ljava/lang/StringI
move-object v3, v5
.line 181
:goto_31
return-object v3
.line 160
:catch_32
move-exception v3
move-object v1, v3
.line 161
.local v1, ex:Landroid/content/pm/PackageManager$NameNotFoundException;
const-string v3, "StatusBar"
new-instance v3, Ljava/lang/StringBuilder;
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
const-string v4, "Icon package not found: "
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
iget-object v4, p1, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v3
invoke-static {v6, v3, v1}, Landroid/util/Slog;->e(Ljava/lang/String;Ljava/lang/String;Ljava/lang/ThrowableI
move-object v3, v5
.line 162
goto :goto_31
.line 165
.end local v1 #ex:Landroid/content/pm/PackageManager$NameNotFoundException;
:cond_50
invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v2
goto :goto_12
.line 174
:cond_55
:try_start_55
iget v3, p1, Lcom/android/server/status/IconData;->iconId:I
invoke-virtual {v2, v3}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;
:try_end_5a
.catch Ljava/lang/RuntimeException; {:try_start_55 .. :try_end_5a} :catch_5c
move-result-object v3
goto :goto_31
.line 175
:catch_5c
move-exception v3
move-object v0, v3
.line 176
.local v0, e:Ljava/lang/RuntimeException;
const-string v3, "StatusBar"
new-instance v3, Ljava/lang/StringBuilder;
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
const-string v4, "Icon not found in "
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
iget-object v4, p1, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
if-eqz v4, :cond_92
iget v4, p1, Lcom/android/server/status/IconData;->iconId:I
invoke-static {v4}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v4
:goto_75
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/ObjectLjava/lang/StringBuilder;
move-result-object v3
const-string v4, ": "
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
iget v4, p1, Lcom/android/server/status/IconData;->iconId:I
invoke-static {v4}, Ljava/lang/Integer;->toHexString(I)Ljava/lang/String;
move-result-object v4
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v3
invoke-static {v6, v3}, Landroid/util/Slog;->w(Ljava/lang/String;Ljava/lang/StringI
move-object v3, v5
.line 181
goto :goto_31
.line 176
:cond_92
const-string v4, "<system>"
goto :goto_75
.end method
# virtual methods
.method getNumber()I
.registers 2
.prologue
.line 185
iget-object v0, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget v0, v0, Lcom/android/server/status/IconData;->number:I
return v0
.end method
.method public update(I)V
.registers 6
.parameter "number"
.prologue
const-string v3, ""
.line 133
iget-object v1, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget v1, v1, Lcom/android/server/status/IconData;->number:I
if-eq v1, p1, :cond_22
.line 134
iget-object v0, p0, Lcom/android/server/status/StatusBarIcon;->mNumberView:Landroid/widget/TextView;
.line 135
.local v0, nv:Landroid/widget/TextView;
if-lez p1, :cond_27
.line 136
new-instance v1, Ljava/lang/StringBuilder;
invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V
const-string v2, ""
invoke-virtual {v1, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v1
invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
.line 141
.end local v0 #nv:Landroid/widget/TextView;
:cond_22
:goto_22
iget-object v1, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iput p1, v1, Lcom/android/server/status/IconData;->number:I
.line 142
return-void
.line 138
.restart local v0 #nv:Landroid/widget/TextView;
:cond_27
const-string v1, ""
invoke-virtual {v0, v3}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
goto :goto_22
.end method
.method public update(Landroid/content/Context;Lcom/android/server/status/IconDataV
.registers 9
.parameter "context"
.parameter "data"
.annotation system Ldalvik/annotation/Throws;
value = {
Lcom/android/server/status/StatusBarException;
}
.end annotation
.prologue
const-string v5, ""
.line 100
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget v3, v3, Lcom/android/server/status/IconData;->type:I
iget v4, p2, Lcom/android/server/status/IconData;->type:I
if-eq v3, v4, :cond_12
.line 101
new-instance v3, Lcom/android/server/status/StatusBarException;
const-string v4, "status bar entry type can\'t change"
invoke-direct {v3, v4}, Lcom/android/server/status/StatusBarException;-><init>(Ljava/lang/StringV
throw v3
.line 103
:cond_12
iget v3, p2, Lcom/android/server/status/IconData;->type:I
packed-switch v3, switch_data_92
.line 129
:cond_17
:goto_17
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
invoke-virtual {v3, p2}, Lcom/android/server/status/IconData;->copyFrom(Lcom/android/server/status/IconDataV
.line 130
return-void
.line 105
switch_1d
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget-object v3, v3, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;
iget-object v4, p2, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;
invoke-static {v3, v4}, Landroid/text/TextUtils;->equals(Ljava/lang/CharSequence;Ljava/lang/CharSequenceZ
move-result v3
if-nez v3, :cond_17
.line 106
iget-object v2, p0, Lcom/android/server/status/StatusBarIcon;->mTextView:Landroid/widget/TextView;
.line 107
.local v2, tv:Landroid/widget/TextView;
iget-object v3, p2, Lcom/android/server/status/IconData;->text:Ljava/lang/CharSequence;
invoke-virtual {v2, v3}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
goto :goto_17
.line 111
.end local v2 #tv:Landroid/widget/TextView;
switch_31
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget-object v3, v3, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
if-eqz v3, :cond_47
iget-object v3, p2, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
if-eqz v3, :cond_47
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget-object v3, v3, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
iget-object v4, p2, Lcom/android/server/status/IconData;->iconPackage:Ljava/lang/String;
invoke-virtual {v3, v4}, Ljava/lang/String;->equals(Ljava/lang/ObjectZ
move-result v3
if-eqz v3, :cond_57
:cond_47
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget v3, v3, Lcom/android/server/status/IconData;->iconId:I
iget v4, p2, Lcom/android/server/status/IconData;->iconId:I
if-ne v3, v4, :cond_57
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget v3, v3, Lcom/android/server/status/IconData;->iconLevel:I
iget v4, p2, Lcom/android/server/status/IconData;->iconLevel:I
if-eq v3, v4, :cond_65
.line 115
:cond_57
iget-object v0, p0, Lcom/android/server/status/StatusBarIcon;->mImageView:Lcom/android/server/status/AnimatedImageView;
.line 116
.local v0, im:Landroid/widget/ImageView;
invoke-static {p1, p2}, Lcom/android/server/status/StatusBarIcon;->getIcon(Landroid/content/Context;Lcom/android/server/status/IconDataLandroid/graphics/drawable/Drawable;
move-result-object v3
invoke-virtual {v0, v3}, Lcom/android/server/status/AnimatedImageView;->setImageDrawable(Landroid/graphics/drawable/DrawableV
.line 117
iget v3, p2, Lcom/android/server/status/IconData;->iconLevel:I
invoke-virtual {v0, v3}, Lcom/android/server/status/AnimatedImageView;->setImageLevel(I)V
.line 119
.end local v0 #im:Landroid/widget/ImageView;
:cond_65
iget-object v3, p0, Lcom/android/server/status/StatusBarIcon;->mData:Lcom/android/server/status/IconData;
iget v3, v3, Lcom/android/server/status/IconData;->number:I
iget v4, p2, Lcom/android/server/status/IconData;->number:I
if-eq v3, v4, :cond_17
.line 120
iget-object v1, p0, Lcom/android/server/status/StatusBarIcon;->mNumberView:Landroid/widget/TextView;
.line 121
.local v1, nv:Landroid/widget/TextView;
iget v3, p2, Lcom/android/server/status/IconData;->number:I
if-lez v3, :cond_8c
.line 122
new-instance v3, Ljava/lang/StringBuilder;
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
const-string v4, ""
invoke-virtual {v3, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/StringLjava/lang/StringBuilder;
move-result-object v3
iget v4, p2, Lcom/android/server/status/IconData;->number:I
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
move-result-object v3
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v3
invoke-virtual {v1, v3}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
goto :goto_17
.line 124
:cond_8c
const-string v3, ""
invoke-virtual {v1, v5}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequenceV
goto :goto_17
.line 103
switch_data_92
.packed-switch 0x1
switch_1d
switch_31
.end packed-switch
.end method
Click to expand...
Click to collapse
Hi xda peoples
I ported this mods from concept showed by dictact74 & Mirko_DDD, so major credits go to their.....
There are two ways to make this mod.
Improve a new method or by use a old unused method.
Here we going to create a new method, if a lot of people will be interested about this thread, I'll post the other method
YOU CAN DOWNLOAD HERE A FLASHABLE FILE:
http://forum.xda-developers.com/showthread.php?t=2047010
Android.policy.jar
Let's start with Android.policy.jar
smali/com/android/internal/policy/imp/LockPatternKeyguardView
Find and replace the whole method,so we'll improve the aosp lockcreen:
Code:
.method createLockScreen()Landroid/view/View;
.locals 6
.prologue
.line 1268
const/4 v0, 0x0
iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;
invoke-virtual {v5}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v5
const-string v4, "darboc_aosp_lock"
invoke-static {v5, v4, v0}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v5
if-nez v5, :cond_dar
.line 1044
new-instance v0, Lcom/android/internal/policy/impl/sec/CircleLockScreen;
iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;
iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;
iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;
iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;
iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;
invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/sec/CircleLockScreen;->(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V
.line 1274
.local v0, lockView:Landroid/view/View;
:goto_0
invoke-direct {p0, v0}, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->initializeTransportControlView(Landroid/view/View;)V
.line 1275
return-object v0
:cond_dar
new-instance v0, Lcom/android/internal/policy/impl/LockScreen;
iget-object v1, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mContext:Landroid/content/Context;
iget-object v2, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mConfiguration:Landroid/content/res/Configuration;
iget-object v3, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mLockPatternUtils:Lcom/android/internal/widget/LockPatternUtils;
iget-object v4, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mUpdateMonitor:Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;
iget-object v5, p0, Lcom/android/internal/policy/impl/LockPatternKeyguardView;->mKeyguardScreenCallback:Lcom/android/internal/policy/impl/KeyguardScreenCallback;
invoke-direct/range {v0 .. v5}, Lcom/android/internal/policy/impl/LockScreen;->(Landroid/content/Context;Landroid/content/res/Configuration;Lcom/android/internal/widget/LockPatternUtils;Lcom/android/internal/policy/impl/KeyguardUpdateMonitor;Lcom/android/internal/policy/impl/KeyguardScreenCallback;)V
.line 1274
goto :goto_0
.end method
Save and exit
Recompile and push to /system/app
SecSettings:
Open
smali/com/android/settings/LockScreenSettings
we going to improve the checkbox.......
add BLU lines
canc RED lines
Code:
.method private updateState()V
.locals 9
.prologue
const/4 v5, 0x1
const/4 v6, 0x0
.line 263
[COLOR="Blue"]iget-object v7, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
const-string v8, "darboc_aosp_lock"
invoke-static {v4, v8, v6}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v4
if-eqz v4, :cond_7
move v4, v5
invoke-virtual {v7, v4}, Landroid/preference/CheckBoxPreference;->setChecked(Z)V
.line 265
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
iget-object v7, p0, Lcom/android/settings/LockScreenSettings;->mClock:Landroid/preference/CheckBoxPreference;
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4[/COLOR]
const-string v8, "show_clock"
Find and replace
Code:
iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mClock:Landroid/preference/CheckBoxPreference;
const/4 v10, 0x0
invoke-virtual {v9, v10}, Landroid/preference/CheckBoxPreference;->setPersistent(Z)V
[COLOR="blue"]const-string v9, "darboc_aosp_lock"
invoke-virtual {p0, v9}, Lcom/android/settings/LockScreenSettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v9
check-cast v9, Landroid/preference/CheckBoxPreference;
iput-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
.line 159
iget-object v9, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
const/4 v10, 0x0
invoke-virtual {v9, v10}, Landroid/preference/CheckBoxPreference;->setPersistent(Z)V
[/COLOR]
.line 161
const-string v9, "weather"
invoke-virtual {p0, v9}, Lcom/android/settings/LockScreenSettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
Find and add the condition
Code:
iget-object v4, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v4}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v4
if-eqz v4, [COLOR="Blue"]:cond_bbb[/COLOR]
.line 338
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
const-string v5, "wake_up_lock_screen"
iget-object v6, p0, Lcom/android/settings/LockScreenSettings;->mSayCommand:Landroid/preference/CheckBoxPreference;
Find and add the new condition method
Code:
invoke-static {v4, v5, v2}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto/16 :goto_1
:cond_a
move v2, v3
goto :goto_5
[COLOR="blue"]:cond_bbb
iget-object v4, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
invoke-virtual {p2, v4}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v4
if-eqz v4, :cond_0
.line 313
invoke-virtual {p0}, Lcom/android/settings/LockScreenSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
const-string v5, "darboc_aosp_lock"
iget-object v6, p0, Lcom/android/settings/LockScreenSettings;->mAospLock:Landroid/preference/CheckBoxPreference;
invoke-virtual {v6}, Landroid/preference/CheckBoxPreference;->isChecked()Z
move-result v6
if-eqz v6, :cond_c
:goto_6
invoke-static {v4, v5, v2}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
.line 314
invoke-direct {p0}, Lcom/android/settings/LockScreenSettings;->updateState()V
.line 340
invoke-super {p0, p1, p2}, Lcom/android/settings/SettingsPreferenceFragment;->onPreferenceTreeClick(Landroid/preference/PreferenceScreen;Landroid/preference/Preference;)Z
move-result v2
return v2
:cond_c
move v2, v3
.line 313
goto :goto_6[/COLOR]
.line 337
.end method
.method public onResume()V
.locals 0
.prologue
.line 257
invoke-super {p0}, Lcom/android/settings/SettingsPreferenceFragment;->onResume()V
Save and exit
Now we'll iprove the xml part that show the checkbox and call the mali part
Go to res/values/strings.xml
Add the following lines somewhere in this file:
Code:
<string name="enable_aosp_lock">AOSP lockscreen</string>
<string name="enable_aosp_lock_text">Enable AOSP lockscreen</string>
Save and exit
Go to res/xml/Lockscreen_Settings.xml
Add the following lines where you like that checkbox would be showed
Code:
<CheckBoxPreference android:title="@string/enable_aosp_lock" android:key="darboc_aosp_lock" android:summary="@string/enable_aosp_lock_text" />
Recompile and push to /system/app
Reboot
Now will find your new toggle in lockscreen options
Enjoy
MERRY X-MAS AND HAPPY MODS NEW YEAR
Reserved.........
Inviato dal mio GT-N7000 con Tapatalk 2
One more
Inviato dal mio GT-N7000 con Tapatalk 2
Thanks for sharing your knowledge ! I will see how far I can get
Click to expand...
Click to collapse
MOD DEV/GUIDE TRANSPARENT STATUS BAR, CENTER CLOCK, ADD MORE TILES COLOUMS TO QUICKSETTINGS, TRANSPARENT LOCKSCREEN, TWEAKING BY "daxgirl", VERTICAL CRT OFF ANIMATION, TABBED SETTINGS, TRANSPARENT NAVBAR, BOTTOM NAVBAR IN LANDSCAPE MODE
Hello XDA,. , especially for Developer only
I've been able to make some mods for CyanogenMod 10.1 ,
and here I want to share it to you all what is my mod and how/guide to build it for your device running CyanogenMod 10.1
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
- Know how to decompile/recompiling jar Apk file
- notepad++
- Tool for decompiling, : apkmanager/apktool/Virtous/apkmultitools/ or else
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Click to expand...
Click to collapse
TRANSPARENT STATUS BAR & CENTER CLOCK
TRANSPARENT STATUS BAR GUIDE IS IN POST #2
CENTER CLOCK GUIDE IS IN POST #3
SCREENSHOT
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
QUICKSETTINGS WITH 4 OR 5 TILES COLOUMS
QUICKSETTINGS WITH 4 OR 5 TILES COLOUMS GUIDE IS IN POST #4
SCREENSHOTS
TRANSPARENT LOCKSCREEN
TRANSPARENT LOCKSCREEN GUIDE IS IN POST #5
SCREENSHOTS
TWEAKING BY "daxgirl"
TWEAKING BY "daxgirl" is in POST #16 DON'T FORGET TO PRESS HER THANKS BUTTON
SCREENSHOTS
VERTICAL CRT OFF ANIMATION
YOUTUBE PREVIEW BY THE ORIGINAL FOUNDER >> IN HERE <<
YOUTUBE PREVIEW BY ME >> IN HERE <<
VERTICAL CRT OFF ANIMATION SMALI GUIDE IS IN POST #6
TABBED SETTINGS WITH SWIPE
Tabbed Settings guide is in here : http://forum.xda-developers.com/showthread.php?t=2273807
TRANSPARENT NAVBAR
Transparent Navbar guide is in here : http://forum.xda-developers.com/showthread.php?t=2361902
BOTTOM NAVBAR IN LANDSCAPE MODE
Guide is in here : http://forum.xda-developers.com/showthread.php?p=43710577#post43710577
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Click to expand...
Click to collapse
Click to expand...
Click to collapse
Click to expand...
Click to collapse
CREDIT & THANKS
ARCO
EVILISTO
Recognized themer @rodman01
@mulbyungjahri
@BOND1987
Daxgirl
XDA
CYANOGEN MOD
[Unofficial Community] Galaxy Wonder CyanogenMod Indonesia
PRESS MY THANKS BUTTON IF I HELPED YOU:good::laugh:
TRANSPARENT STATUS BAR
GUIDE NOW FIXED !!
It also work to, CM10 / CM10.1/ JB 4.1.1/ JB 4.1.2 / JB 4.2.1/JB 4.2.2/ JB 4.3
CREDIT & THANKS TO :
- Senior Member @evilisto
- Recognized themer @rodman01
- @mulbyungjahri
- @BOND1987
1. DECOMPILE android.policy.jar
\com\android\internal\policy\impl\PhoneWindowManager.smali
find this method :
Code:
.method public getSystemDecorRectLw(Landroid/graphics/Rect;)I
DELETE the RED CODE
AND REPLACE it with the BLUE CODE
Code:
.method public getSystemDecorRectLw(Landroid/graphics/Rect;)I
.registers 3
.parameter "systemRect"
.prologue
.line 3057
iget v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemLeft:I
iput v0, p1, Landroid/graphics/Rect;->left:I
.line 3058
iget v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemTop:I
iput v0, p1, Landroid/graphics/Rect;->top:I
.line 3059
iget v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemRight:I
iput v0, p1, Landroid/graphics/Rect;->right:I
.line 3060
iget v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemBottom:I
iput v0, p1, Landroid/graphics/Rect;->bottom:I
.line 3061
[COLOR="Red"]iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mStatusBar:Landroid/view/WindowManagerPolicy$WindowState;
if-eqz v0, :cond_1b
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mStatusBar:Landroid/view/WindowManagerPolicy$WindowState;
invoke-interface {v0}, Landroid/view/WindowManagerPolicy$WindowState;->getSurfaceLayer()I
move-result v0
.line 3063
:goto_1a
return v0
.line 3062
:cond_1b
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBar:Landroid/view/WindowManagerPolicy$WindowState;
if-eqz v0, :cond_26
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBar:Landroid/view/WindowManagerPolicy$WindowState;
invoke-interface {v0}, Landroid/view/WindowManagerPolicy$WindowState;->getSurfaceLayer()I
move-result v0
goto :goto_1a
.line 3063
:cond_26
const/4 v0, 0x0
goto :goto_1a
.end method[/COLOR]
and replace with this BLUE CODE
Code:
[COLOR="Blue"]const/4 v0, 0x0
return v0
.end method[/COLOR]
DONE & COMPILE
2. DECOMPILE SystemUI.apk
. /res/values/drawables.xml
Code:
<item type="drawable" name="notification_number_text_color">#ff000000</item>
<item type="drawable" name="ticker_background_color">#ff1d1d1d</item>
<item type="drawable" name="[COLOR="Blue"]status_bar_background[/COLOR]">[COLOR="Red"]#00000000[/COLOR]</item>
<item type="drawable" name="status_bar_recents_app_thumbnail_background">#88000000</item>
<item type="drawable" name="status_bar_notification_row_background_color">#ff090909</item>
<item type="drawable" name="recents_callout_line">#99ffffff</item>
<item type="drawable" name="notification_item_background_legacy_color">#ffaaaaaa</item>
<item type="drawable" name="intruder_bg_pressed">#ff33b5e5</item>
<item type="drawable" name="notification_header_bg">#ff000000</item>
<item type="drawable" name="system_bar_background">[COLOR="Red"]#88000000[/COLOR]</item>
<item type="drawable" name="notification_icon_area_smoke">[COLOR="Red"]#88000000[/COLOR]</item>
100% Transparency :
Code:
[COLOR="Red"]#00000000[/COLOR]
80% Transparency :
Code:
[COLOR="Red"]#88000000[/COLOR][/B]
DONE !!, AND COMPILE
NEXT READ THIS
Cancelling autodimming for transparent status bar by "daxgirl"
SEE IN POST #20, Don't forget to press her THANKS BUTTON
CENTER CLOCK
DECOMPILE, SystemUI.apk
1. /res/layout/status_bar.xml
DELETE whole line and replace with this :
Code:
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants" android:layout_width="fill_parent" android:layout_height="fill_parent"
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_large" android:scaleType="center" />
<LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:paddingLeft="6.0dip" android:paddingRight="6.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
<LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<LinearLayout android:orientation="horizontal" android:id="@id/notification_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
<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_image_error" />
<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>
</LinearLayout>
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:gravity="center" android:id="@id/clock" android:paddingLeft="6.0dip" android:clickable="false" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
<LinearLayout android:gravity="right" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/system_icon_area" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<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/signal_cluster_view" />
<include android:id="@id/signal_cluster_text" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_text_view" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Battery" android:gravity="left|center" android:id="@id/dock_battery_text" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="-3.0dip" android:singleLine="true" />
<ImageView android:id="@id/dock_battery" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.Battery" android:gravity="left|center" android:id="@id/battery_text" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="-3.0dip" android:singleLine="true" />
<ImageView android:id="@id/battery" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<com.android.systemui.statusbar.policy.CircleBattery android:textAppearance="@style/TextAppearance.StatusBar.Battery" android:gravity="bottom" android:id="@id/circle_battery" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
<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="center" />
<com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="center" />
</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:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
<TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" 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>
2. /res/layout/status_bar_expanded_header.xml
LINE 2 , replace with my line
Code:
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/header" android:background="#ff000000" android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_header_height" android:baselineAligned="false"
DONE !!, AND COMPILE
QUICKSETTINGS WITH 4 OR 5 TILES COLOUMS
DECOMPILE, SystemUI.apk
. /res/layout/status_bar_expanded_header.xml
LINE xml 2 , replace with my line
Code:
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/header" android:background="#ff000000" android:layout_width="fill_parent" android:layout_height="@dimen/notification_panel_header_height" android:baselineAligned="false"
. /res/values/integers.xml
Code:
<integer name="quick_settings_num_columns">[COLOR="Red"]3[/COLOR]</integer>
3 is stok , you can change it you like to 4 or 5
. /res/values/dimens/
Code:
<dimen name="notification_panel_header_height">[COLOR="Red"]60.0dip[/COLOR]</dimen>
. /res/values/dimens/
Code:
<dimen name="quick_settings_cell_height">[COLOR="Red"]100.0dip[/COLOR]</dimen>
- SystemUI/res/values/styles.xml/
Code:
<style name="TextAppearance.QuickSettings.TileView" parent="@style/TextAppearance.QuickSettings">
<item name="android:textSize">[COLOR="Red"]9.0dip[/COLOR]</item>
DONE !!, AND COMPILE
TRANSPARENT LOCKSCREEN
DECOMPILE android.policy.jar
com/android/internal/policy/impl/keyguard/KeyguardViewManager.smali
find this method.
Code:
.method private maybeCreateKeyguardLocked(ZZLandroid/os/Bundle;)V
DELETE that line until its end method
Code:
.method private maybeCreateKeyguardLocked(ZZLandroid/os/Bundle;)V
-
-
-
-DELETE UNTIL ITS END METHOD
-
-
-
.end method
and Replace with this
Code:
.method private maybeCreateKeyguardLocked(ZZLandroid/os/Bundle;)V
.registers 13
.parameter "enableScreenRotation"
.parameter "force"
.parameter "options"
.prologue
const/high16 v8, 0x100
const/4 v1, -0x1
.line 158
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mContext:Landroid/content/Context;
instance-of v6, v2, Landroid/app/Activity;
.line 160
.local v6, isActivity:Z
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
if-eqz v2, :cond_12
.line 161
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
iget-object v5, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mStateContainer:Landroid/util/SparseArray;
invoke-virtual {v2, v5}, Landroid/widget/FrameLayout;->saveHierarchyState(Landroid/util/SparseArray;)V
.line 164
:cond_12
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
if-nez v2, :cond_79
.line 167
new-instance v2, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager$ViewManagerHost;
iget-object v5, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mContext:Landroid/content/Context;
invoke-direct {v2, p0, v5}, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager$ViewManagerHost;-><init>(Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;Landroid/content/Context;)V
iput-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
.line 169
const v4, 0x10900
.line 173
.local v4, flags:I
iget-boolean v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mNeedsInput:Z
if-nez v2, :cond_29
.line 174
const/high16 v2, 0x2
or-int/2addr v4, v2
.line 176
:cond_29
invoke-static {}, Landroid/app/ActivityManager;->isHighEndGfx()Z
move-result v2
if-eqz v2, :cond_30
.line 177
or-int/2addr v4, v8
.line 180
:cond_30
const/4 v7, -0x1
.line 181
.local v7, stretch:I
if-eqz v6, :cond_96
const/4 v3, 0x2
.line 183
.local v3, type:I
:goto_34
new-instance v0, Landroid/view/WindowManager$LayoutParams;
const/4 v5, -0x3
move v2, v1
invoke-direct/range {v0 .. v5}, Landroid/view/WindowManager$LayoutParams;-><init>(IIIII)V
.line 185
.local v0, lp:Landroid/view/WindowManager$LayoutParams;
const/16 v1, 0x10
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->softInputMode:I
.line 186
const v1, 0x10301e2
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->windowAnimations:I
.line 187
invoke-static {}, Landroid/app/ActivityManager;->isHighEndGfx()Z
move-result v1
if-eqz v1, :cond_55
.line 188
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
or-int/2addr v1, v8
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->flags:I
.line 189
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->privateFlags:I
or-int/lit8 v1, v1, 0x2
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->privateFlags:I
.line 192
:cond_55
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->privateFlags:I
or-int/lit8 v1, v1, 0x8
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->privateFlags:I
.line 193
if-eqz v6, :cond_63
.line 194
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->privateFlags:I
or-int/lit8 v1, v1, 0x10
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->privateFlags:I
.line 196
:cond_63
iget v1, v0, Landroid/view/WindowManager$LayoutParams;->inputFeatures:I
or-int/lit8 v1, v1, 0x4
iput v1, v0, Landroid/view/WindowManager$LayoutParams;->inputFeatures:I
.line 197
if-eqz v6, :cond_99
const-string v1, "KeyguardMock"
:goto_6d
invoke-virtual {v0, v1}, Landroid/view/WindowManager$LayoutParams;->setTitle(Ljava/lang/CharSequence;)V
.line 198
iput-object v0, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mWindowLayoutParams:Landroid/view/WindowManager$LayoutParams;
.line 199
iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mViewManager:Landroid/view/ViewManager;
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
invoke-interface {v1, v2, v0}, Landroid/view/ViewManager;->addView(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 202
.end local v0 #lp:Landroid/view/WindowManager$LayoutParams;
.end local v3 #type:I
.end local v4 #flags:I
.end local v7 #stretch:I
:cond_79
if-nez p2, :cond_7f
iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardView:Lcom/android/internal/policy/impl/keyguard/KeyguardHostView;
if-nez v1, :cond_82
.line 203
:cond_7f
invoke-direct {p0, p3}, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->inflateKeyguardView(Landroid/os/Bundle;)V
.line 205
:cond_82
invoke-direct {p0}, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->updateUserActivityTimeoutInWindowLayoutParams()V
.line 206
iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mViewManager:Landroid/view/ViewManager;
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
iget-object v5, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mWindowLayoutParams:Landroid/view/WindowManager$LayoutParams;
invoke-interface {v1, v2, v5}, Landroid/view/ViewManager;->updateViewLayout(Landroid/view/View;Landroid/view/ViewGroup$LayoutParams;)V
.line 208
iget-object v1, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mKeyguardHost:Landroid/widget/FrameLayout;
iget-object v2, p0, Lcom/android/internal/policy/impl/keyguard/KeyguardViewManager;->mStateContainer:Landroid/util/SparseArray;
invoke-virtual {v1, v2}, Landroid/widget/FrameLayout;->restoreHierarchyState(Landroid/util/SparseArray;)V
.line 209
return-void
.line 181
.restart local v4 #flags:I
.restart local v7 #stretch:I
:cond_96
const/16 v3, 0x7d4
goto :goto_34
.line 197
.restart local v0 #lp:Landroid/view/WindowManager$LayoutParams;
.restart local v3 #type:I
:cond_99
const-string v1, "Keyguard"
goto :goto_6d
.end method
NEXT
DECOMPILE services.jar
com/android/server/wm/WindowAnimator.smali
find this method
Code:
.method private updateWindowsLocked(I)V
DELETE that line until its end method
Code:
.method private updateWindowsLocked(I)V
-
-
-
-DELETE UNTIL ITS END METHOD
-
-
-.end method
and REPLACE WITH THIS LINES :
Code:
.method private updateWindowsLocked(I)V
.registers 23
.parameter "displayId"
.prologue
.line 343
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mAnimTransactionSequence:I
move/from16 v17, v0
add-int/lit8 v17, v17, 0x1
move/from16 v0, v17
move-object/from16 v1, p0
iput v0, v1, Lcom/android/server/wm/WindowAnimator;->mAnimTransactionSequence:I
.line 345
invoke-direct/range {p0 .. p1}, Lcom/android/server/wm/WindowAnimator;->getDisplayContentsAnimatorLocked(I)Lcom/android/server/wm/WindowAnimator$DisplayContentsAnimator;
move-result-object v17
move-object/from16 v0, v17
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator$DisplayContentsAnimator;->mWinAnimators:Lcom/android/server/wm/WinAnimatorList;
move-object/from16 v16, v0
.line 347
.local v16, winAnimatorList:Lcom/android/server/wm/WinAnimatorList;
const/4 v11, 0x0
.line 348
.local v11, unForceHiding:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Lcom/android/server/wm/WindowStateAnimator;>;"
const/4 v12, 0x0
.line 349
.local v12, wallpaperInUnForceHiding:Z
const/16 v17, 0x0
move/from16 v0, v17
move-object/from16 v1, p0
iput v0, v1, Lcom/android/server/wm/WindowAnimator;->mForceHiding:I
.line 351
invoke-virtual/range {v16 .. v16}, Lcom/android/server/wm/WinAnimatorList;->size()I
move-result v17
add-int/lit8 v9, v17, -0x1
.local v9, i:I
:goto_28
if-ltz v9, :cond_26a
.line 352
move-object/from16 v0, v16
invoke-virtual {v0, v9}, Lcom/android/server/wm/WinAnimatorList;->get(I)Ljava/lang/Object;
move-result-object v15
check-cast v15, Lcom/android/server/wm/WindowStateAnimator;
.line 353
.local v15, winAnimator:Lcom/android/server/wm/WindowStateAnimator;
iget-object v14, v15, Lcom/android/server/wm/WindowStateAnimator;->mWin:Lcom/android/server/wm/WindowState;
.line 354
.local v14, win:Lcom/android/server/wm/WindowState;
iget v7, v15, Lcom/android/server/wm/WindowStateAnimator;->mAttrFlags:I
.line 356
.local v7, flags:I
iget-object v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mSurface:Landroid/view/Surface;
move-object/from16 v17, v0
if-eqz v17, :cond_f4
.line 357
iget-boolean v13, v15, Lcom/android/server/wm/WindowStateAnimator;->mWasAnimating:Z
.line 358
.local v13, wasAnimating:Z
move-object/from16 v0, p0
iget-wide v0, v0, Lcom/android/server/wm/WindowAnimator;->mCurrentTime:J
move-wide/from16 v17, v0
move-wide/from16 v0, v17
invoke-virtual {v15, v0, v1}, Lcom/android/server/wm/WindowStateAnimator;->stepAnimationLocked(J)Z
move-result v10
.line 365
.local v10, nowAnimating:Z
if-eqz v13, :cond_8e
iget-boolean v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mAnimating:Z
move/from16 v17, v0
if-nez v17, :cond_8e
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mWallpaperTarget:Lcom/android/server/wm/WindowState;
move-object/from16 v17, v0
move-object/from16 v0, v17
if-ne v0, v14, :cond_8e
.line 366
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
move/from16 v17, v0
or-int/lit8 v17, v17, 0x2
move/from16 v0, v17
move-object/from16 v1, p0
iput v0, v1, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
.line 367
const/16 v17, 0x0
const/16 v18, 0x4
move-object/from16 v0, p0
move/from16 v1, v17
move/from16 v2, v18
invoke-virtual {v0, v1, v2}, Lcom/android/server/wm/WindowAnimator;->setPendingLayoutChanges(II)V
.line 370
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mService:Lcom/android/server/wm/WindowManagerService;
move-object/from16 v17, v0
const-string v18, "updateWindowsAndWallpaperLocked 2"
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPendingLayoutChanges:Landroid/util/SparseIntArray;
move-object/from16 v19, v0
const/16 v20, 0x0
invoke-virtual/range {v19 .. v20}, Landroid/util/SparseIntArray;->get(I)I
move-result v19
invoke-virtual/range {v17 .. v19}, Lcom/android/server/wm/WindowManagerService;->debugLayoutRepeats(Ljava/lang/String;I)V
.line 375
:cond_8e
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPolicy:Landroid/view/WindowManagerPolicy;
move-object/from16 v17, v0
iget-object v0, v14, Lcom/android/server/wm/WindowState;->mAttrs:Landroid/view/WindowManager$LayoutParams;
move-object/from16 v18, v0
move-object/from16 v0, v17
move-object/from16 v1, v18
invoke-interface {v0, v14, v1}, Landroid/view/WindowManagerPolicy;->doesForceHide(Landroid/view/WindowManagerPolicy$WindowState;Landroid/view/WindowManager$LayoutParams;)Z
move-result v17
if-eqz v17, :cond_17e
.line 376
if-nez v13, :cond_e6
if-eqz v10, :cond_e6
.line 380
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
move/from16 v17, v0
or-int/lit8 v17, v17, 0x4
move/from16 v0, v17
move-object/from16 v1, p0
iput v0, v1, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
.line 381
const/16 v17, 0x4
move-object/from16 v0, p0
move/from16 v1, p1
move/from16 v2, v17
invoke-virtual {v0, v1, v2}, Lcom/android/server/wm/WindowAnimator;->setPendingLayoutChanges(II)V
.line 384
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mService:Lcom/android/server/wm/WindowManagerService;
move-object/from16 v17, v0
const-string v18, "updateWindowsAndWallpaperLocked 3"
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPendingLayoutChanges:Landroid/util/SparseIntArray;
move-object/from16 v19, v0
move-object/from16 v0, v19
move/from16 v1, p1
invoke-virtual {v0, v1}, Landroid/util/SparseIntArray;->get(I)I
move-result v19
invoke-virtual/range {v17 .. v19}, Lcom/android/server/wm/WindowManagerService;->debugLayoutRepeats(Ljava/lang/String;I)V
.line 387
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mService:Lcom/android/server/wm/WindowManagerService;
move-object/from16 v17, v0
const/16 v18, 0x1
move/from16 v0, v18
move-object/from16 v1, v17
iput-boolean v0, v1, Lcom/android/server/wm/WindowManagerService;->mFocusMayChange:Z
.line 389
:cond_e6
invoke-virtual {v14}, Lcom/android/server/wm/WindowState;->isReadyForDisplay()Z
move-result v17
if-eqz v17, :cond_f4
.line 390
const/16 v17, 0x0
move/from16 v0, v17
move-object/from16 v1, p0
iput v0, v1, Lcom/android/server/wm/WindowAnimator;->mForceHiding:I
.line 446
.end local v10 #nowAnimating:Z
.end local v13 #wasAnimating:Z
:cond_f4
:goto_f4
iget-object v5, v14, Lcom/android/server/wm/WindowState;->mAppToken:Lcom/android/server/wm/AppWindowToken;
.line 447
.local v5, atoken:Lcom/android/server/wm/AppWindowToken;
iget v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mDrawState:I
move/from16 v17, v0
const/16 v18, 0x3
move/from16 v0, v17
move/from16 v1, v18
if-ne v0, v1, :cond_13a
.line 448
if-eqz v5, :cond_10a
iget-boolean v0, v5, Lcom/android/server/wm/AppWindowToken;->allDrawn:Z
move/from16 v17, v0
if-eqz v17, :cond_13a
.line 449
:cond_10a
invoke-virtual {v15}, Lcom/android/server/wm/WindowStateAnimator;->performShowLocked()Z
move-result v17
if-eqz v17, :cond_13a
.line 450
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPendingLayoutChanges:Landroid/util/SparseIntArray;
move-object/from16 v17, v0
const/16 v18, 0x8
move-object/from16 v0, v17
move/from16 v1, p1
move/from16 v2, v18
invoke-virtual {v0, v1, v2}, Landroid/util/SparseIntArray;->put(II)V
.line 453
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mService:Lcom/android/server/wm/WindowManagerService;
move-object/from16 v17, v0
const-string v18, "updateWindowsAndWallpaperLocked 5"
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPendingLayoutChanges:Landroid/util/SparseIntArray;
move-object/from16 v19, v0
move-object/from16 v0, v19
move/from16 v1, p1
invoke-virtual {v0, v1}, Landroid/util/SparseIntArray;->get(I)I
move-result v19
invoke-virtual/range {v17 .. v19}, Lcom/android/server/wm/WindowManagerService;->debugLayoutRepeats(Ljava/lang/String;I)V
.line 459
:cond_13a
iget-object v4, v15, Lcom/android/server/wm/WindowStateAnimator;->mAppAnimator:Lcom/android/server/wm/AppWindowAnimator;
.line 460
.local v4, appAnimator:Lcom/android/server/wm/AppWindowAnimator;
if-eqz v4, :cond_17a
iget-object v0, v4, Lcom/android/server/wm/AppWindowAnimator;->thumbnail:Landroid/view/Surface;
move-object/from16 v17, v0
if-eqz v17, :cond_17a
.line 461
iget v0, v4, Lcom/android/server/wm/AppWindowAnimator;->thumbnailTransactionSeq:I
move/from16 v17, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mAnimTransactionSequence:I
move/from16 v18, v0
move/from16 v0, v17
move/from16 v1, v18
if-eq v0, v1, :cond_164
.line 462
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mAnimTransactionSequence:I
move/from16 v17, v0
move/from16 v0, v17
iput v0, v4, Lcom/android/server/wm/AppWindowAnimator;->thumbnailTransactionSeq:I
.line 463
const/16 v17, 0x0
move/from16 v0, v17
iput v0, v4, Lcom/android/server/wm/AppWindowAnimator;->thumbnailLayer:I
.line 465
:cond_164
iget v0, v4, Lcom/android/server/wm/AppWindowAnimator;->thumbnailLayer:I
move/from16 v17, v0
iget v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mAnimLayer:I
move/from16 v18, v0
move/from16 v0, v17
move/from16 v1, v18
if-ge v0, v1, :cond_17a
.line 466
iget v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mAnimLayer:I
move/from16 v17, v0
move/from16 v0, v17
iput v0, v4, Lcom/android/server/wm/AppWindowAnimator;->thumbnailLayer:I
.line 351
:cond_17a
add-int/lit8 v9, v9, -0x1
goto/16 :goto_28
.line 401
.end local v4 #appAnimator:Lcom/android/server/wm/AppWindowAnimator;
.end local v5 #atoken:Lcom/android/server/wm/AppWindowToken;
.restart local v10 #nowAnimating:Z
.restart local v13 #wasAnimating:Z
:cond_17e
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPolicy:Landroid/view/WindowManagerPolicy;
move-object/from16 v17, v0
iget-object v0, v14, Lcom/android/server/wm/WindowState;->mAttrs:Landroid/view/WindowManager$LayoutParams;
move-object/from16 v18, v0
move-object/from16 v0, v17
move-object/from16 v1, v18
invoke-interface {v0, v14, v1}, Landroid/view/WindowManagerPolicy;->canBeForceHidden(Landroid/view/WindowManagerPolicy$WindowState;Landroid/view/WindowManager$LayoutParams;)Z
move-result v17
if-eqz v17, :cond_f4
.line 402
iget v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mAttrFlags:I
move/from16 v17, v0
const/high16 v18, 0x8
and-int v17, v17, v18
if-nez v17, :cond_20b
const/4 v8, 0x1
.line 405
.local v8, hideWhenLocked:Z
:goto_19d
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mForceHiding:I
move/from16 v17, v0
const/16 v18, 0x1
move/from16 v0, v17
move/from16 v1, v18
if-ne v0, v1, :cond_1b3
invoke-virtual {v15}, Lcom/android/server/wm/WindowStateAnimator;->isAnimating()Z
move-result v17
if-eqz v17, :cond_1c3
if-nez v8, :cond_1c3
:cond_1b3
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mForceHiding:I
move/from16 v17, v0
const/16 v18, 0x2
move/from16 v0, v17
move/from16 v1, v18
if-ne v0, v1, :cond_20d
if-eqz v8, :cond_20d
.line 408
:cond_1c3
const/16 v17, 0x0
const/16 v18, 0x0
move/from16 v0, v17
move/from16 v1, v18
invoke-virtual {v14, v0, v1}, Lcom/android/server/wm/WindowState;->hideLw(ZZ)Z
move-result v6
.line 434
.local v6, changed:Z
:cond_1cf
:goto_1cf
if-eqz v6, :cond_f4
const/high16 v17, 0x10
and-int v17, v17, v7
if-eqz v17, :cond_f4
.line 435
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
move/from16 v17, v0
or-int/lit8 v17, v17, 0x2
move/from16 v0, v17
move-object/from16 v1, p0
iput v0, v1, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
.line 436
const/16 v17, 0x0
const/16 v18, 0x4
move-object/from16 v0, p0
move/from16 v1, v17
move/from16 v2, v18
invoke-virtual {v0, v1, v2}, Lcom/android/server/wm/WindowAnimator;->setPendingLayoutChanges(II)V
.line 439
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mService:Lcom/android/server/wm/WindowManagerService;
move-object/from16 v17, v0
const-string v18, "updateWindowsAndWallpaperLocked 4"
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPendingLayoutChanges:Landroid/util/SparseIntArray;
move-object/from16 v19, v0
const/16 v20, 0x0
invoke-virtual/range {v19 .. v20}, Landroid/util/SparseIntArray;->get(I)I
move-result v19
invoke-virtual/range {v17 .. v19}, Lcom/android/server/wm/WindowManagerService;->debugLayoutRepeats(Ljava/lang/String;I)V
goto/16 :goto_f4
.line 402
.end local v6 #changed:Z
.end local v8 #hideWhenLocked:Z
:cond_20b
const/4 v8, 0x0
goto :goto_19d
.line 412
.restart local v8 #hideWhenLocked:Z
:cond_20d
const/16 v17, 0x0
const/16 v18, 0x0
move/from16 v0, v17
move/from16 v1, v18
invoke-virtual {v14, v0, v1}, Lcom/android/server/wm/WindowState;->showLw(ZZ)Z
move-result v6
.line 415
.restart local v6 #changed:Z
if-eqz v6, :cond_1cf
.line 416
move-object/from16 v0, p0
iget v0, v0, Lcom/android/server/wm/WindowAnimator;->mBulkUpdateParams:I
move/from16 v17, v0
and-int/lit8 v17, v17, 0x4
if-eqz v17, :cond_23c
invoke-virtual {v14}, Lcom/android/server/wm/WindowState;->isVisibleNow()Z
move-result v17
if-eqz v17, :cond_23c
.line 418
if-nez v11, :cond_232
.line 419
new-instance v11, Ljava/util/ArrayList;
.end local v11 #unForceHiding:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Lcom/android/server/wm/WindowStateAnimator;>;"
invoke-direct {v11}, Ljava/util/ArrayList;-><init>()V
.line 421
.restart local v11 #unForceHiding:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Lcom/android/server/wm/WindowStateAnimator;>;"
:cond_232
invoke-virtual {v11, v15}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
.line 422
const/high16 v17, 0x10
and-int v17, v17, v7
if-eqz v17, :cond_23c
.line 423
const/4 v12, 0x1
.line 426
:cond_23c
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mCurrentFocus:Lcom/android/server/wm/WindowState;
move-object/from16 v17, v0
if-eqz v17, :cond_25a
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mCurrentFocus:Lcom/android/server/wm/WindowState;
move-object/from16 v17, v0
move-object/from16 v0, v17
iget v0, v0, Lcom/android/server/wm/WindowState;->mLayer:I
move/from16 v17, v0
iget v0, v14, Lcom/android/server/wm/WindowState;->mLayer:I
move/from16 v18, v0
move/from16 v0, v17
move/from16 v1, v18
if-ge v0, v1, :cond_1cf
.line 430
:cond_25a
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mService:Lcom/android/server/wm/WindowManagerService;
move-object/from16 v17, v0
const/16 v18, 0x1
move/from16 v0, v18
move-object/from16 v1, v17
iput-boolean v0, v1, Lcom/android/server/wm/WindowManagerService;->mFocusMayChange:Z
goto/16 :goto_1cf
.line 473
.end local v6 #changed:Z
.end local v7 #flags:I
.end local v8 #hideWhenLocked:Z
.end local v10 #nowAnimating:Z
.end local v13 #wasAnimating:Z
.end local v14 #win:Lcom/android/server/wm/WindowState;
.end local v15 #winAnimator:Lcom/android/server/wm/WindowStateAnimator;
:cond_26a
if-eqz v11, :cond_294
.line 474
invoke-virtual {v11}, Ljava/util/ArrayList;->size()I
move-result v17
add-int/lit8 v9, v17, -0x1
:goto_272
if-ltz v9, :cond_294
.line 475
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/server/wm/WindowAnimator;->mPolicy:Landroid/view/WindowManagerPolicy;
move-object/from16 v17, v0
move-object/from16 v0, v17
invoke-interface {v0, v12}, Landroid/view/WindowManagerPolicy;->createForceHideEnterAnimation(Z)Landroid/view/animation/Animation;
move-result-object v3
.line 476
.local v3, a:Landroid/view/animation/Animation;
if-eqz v3, :cond_291
.line 477
invoke-virtual {v11, v9}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;
move-result-object v15
check-cast v15, Lcom/android/server/wm/WindowStateAnimator;
.line 478
.restart local v15 #winAnimator:Lcom/android/server/wm/WindowStateAnimator;
invoke-virtual {v15, v3}, Lcom/android/server/wm/WindowStateAnimator;->setAnimation(Landroid/view/animation/Animation;)V
.line 479
const/16 v17, 0x1
move/from16 v0, v17
iput-boolean v0, v15, Lcom/android/server/wm/WindowStateAnimator;->mAnimationIsEntrance:Z
.line 474
.end local v15 #winAnimator:Lcom/android/server/wm/WindowStateAnimator;
:cond_291
add-int/lit8 v9, v9, -0x1
goto :goto_272
.line 483
.end local v3 #a:Landroid/view/animation/Animation;
:cond_294
return-void
.end method
DONE !! :good::laugh:
VERTICAL CRT OFF ANIMATION
DECOMPILE services.jar
\com\android\server\power\ElectronBeam.smali
1.find this method
Code:
.method private drawHStretch(F)V
Delete that line until its .end method
Code:
.method private drawHStretch(F)V
-
-
-
DELETE that line until its .end method
-
-
-
.end method
and replace with this
Code:
.method private drawHStretch(F)V
.registers 9
.parameter "stretch"
.prologue
const v6, 0x8074
const/4 v5, 0x0
const/high16 v4, 0x3f80
.line 325
const/high16 v1, 0x4100
invoke-static {p1, v1}, Lcom/android/server/power/ElectronBeam;->scurve(FF)F
move-result v0
.line 330
.local v0, ag:F
cmpg-float v1, p1, v4
if-gez v1, :cond_37
.line 332
const/4 v1, 0x2
const/16 v2, 0x1406
iget-object v3, p0, Lcom/android/server/power/ElectronBeam;->mVertexBuffer:Ljava/nio/FloatBuffer;
invoke-static {v1, v2, v5, v3}, Landroid/opengl/GLES10;->glVertexPointer(IIILjava/nio/Buffer;)V
.line 333
invoke-static {v6}, Landroid/opengl/GLES10;->glEnableClientState(I)V
.line 336
iget-object v1, p0, Lcom/android/server/power/ElectronBeam;->mVertexBuffer:Ljava/nio/FloatBuffer;
iget v2, p0, Lcom/android/server/power/ElectronBeam;->mDisplayWidth:I
int-to-float v2, v2
iget v3, p0, Lcom/android/server/power/ElectronBeam;->mDisplayHeight:I
int-to-float v3, v3
invoke-static {v1, v2, v3, v0}, Lcom/android/server/power/ElectronBeam;->setHStretchQuad(Ljava/nio/FloatBuffer;FFF)V
.line 337
sub-float v1, v4, v0
sub-float v2, v4, v0
sub-float v3, v4, v0
invoke-static {v1, v2, v3, v4}, Landroid/opengl/GLES10;->glColor4f(FFFF)V
.line 338
const/4 v1, 0x6
const/4 v2, 0x4
invoke-static {v1, v5, v2}, Landroid/opengl/GLES10;->glDrawArrays(III)V
.line 341
invoke-static {v6}, Landroid/opengl/GLES10;->glDisableClientState(I)V
.line 343
:cond_37
return-void
.end method
2.NEXT find this method
Code:
.method private drawVStretch(F)V
Delete that line until its .end method
Code:
.method private drawVStretch(F)V
-
-
-
- DELETE that line until its .end method
-
-
-
.end method
and Replace with this
Code:
.method private drawVStretch(F)V
.registers 13
.parameter "stretch"
.prologue
const/4 v10, 0x6
const/4 v9, 0x4
const/16 v8, 0xde1
const/4 v7, 0x1
const/4 v6, 0x0
.line 253
const/high16 v3, 0x40f0
invoke-static {p1, v3}, Lcom/android/server/power/ElectronBeam;->scurve(FF)F
move-result v2
.line 254
.local v2, ar:F
const/high16 v3, 0x4100
invoke-static {p1, v3}, Lcom/android/server/power/ElectronBeam;->scurve(FF)F
move-result v1
.line 255
.local v1, ag:F
const/high16 v3, 0x4108
invoke-static {p1, v3}, Lcom/android/server/power/ElectronBeam;->scurve(FF)F
move-result v0
.line 262
.local v0, ab:F
invoke-static {v7, v7}, Landroid/opengl/GLES10;->glBlendFunc(II)V
.line 263
const/16 v3, 0xbe2
invoke-static {v3}, Landroid/opengl/GLES10;->glEnable(I)V
.line 266
const/4 v3, 0x2
const/16 v4, 0x1406
iget-object v5, p0, Lcom/android/server/power/ElectronBeam;->mVertexBuffer:Ljava/nio/FloatBuffer;
invoke-static {v3, v4, v6, v5}, Landroid/opengl/GLES10;->glVertexPointer(IIILjava/nio/Buffer;)V
.line 267
const v3, 0x8074
invoke-static {v3}, Landroid/opengl/GLES10;->glEnableClientState(I)V
.line 270
iget-object v3, p0, Lcom/android/server/power/ElectronBeam;->mTexNames:[I
aget v3, v3, v6
invoke-static {v8, v3}, Landroid/opengl/GLES10;->glBindTexture(II)V
.line 271
const/16 v4, 0x2300
const/16 v5, 0x2200
iget v3, p0, Lcom/android/server/power/ElectronBeam;->mMode:I
if-nez v3, :cond_c8
const/16 v3, 0x2100
:goto_3f
invoke-static {v4, v5, v3}, Landroid/opengl/GLES10;->glTexEnvx(III)V
.line 273
const/16 v3, 0x2800
const/16 v4, 0x2601
invoke-static {v8, v3, v4}, Landroid/opengl/GLES10;->glTexParameterx(III)V
.line 275
const/16 v3, 0x2801
const/16 v4, 0x2601
invoke-static {v8, v3, v4}, Landroid/opengl/GLES10;->glTexParameterx(III)V
.line 277
const/16 v3, 0x2802
const v4, 0x812f
invoke-static {v8, v3, v4}, Landroid/opengl/GLES10;->glTexParameterx(III)V
.line 279
const/16 v3, 0x2803
const v4, 0x812f
invoke-static {v8, v3, v4}, Landroid/opengl/GLES10;->glTexParameterx(III)V
.line 281
invoke-static {v8}, Landroid/opengl/GLES10;->glEnable(I)V
.line 282
const/4 v3, 0x2
const/16 v4, 0x1406
iget-object v5, p0, Lcom/android/server/power/ElectronBeam;->mTexCoordBuffer:Ljava/nio/FloatBuffer;
invoke-static {v3, v4, v6, v5}, Landroid/opengl/GLES10;->glTexCoordPointer(IIILjava/nio/Buffer;)V
.line 283
const v3, 0x8078
invoke-static {v3}, Landroid/opengl/GLES10;->glEnableClientState(I)V
.line 286
iget-object v3, p0, Lcom/android/server/power/ElectronBeam;->mVertexBuffer:Ljava/nio/FloatBuffer;
iget v4, p0, Lcom/android/server/power/ElectronBeam;->mDisplayWidth:I
int-to-float v4, v4
iget v5, p0, Lcom/android/server/power/ElectronBeam;->mDisplayHeight:I
int-to-float v5, v5
invoke-static {v3, v4, v5, v2}, Lcom/android/server/power/ElectronBeam;->setVStretchQuad(Ljava/nio/FloatBuffer;FFF)V
.line 287
invoke-static {v7, v6, v6, v7}, Landroid/opengl/GLES10;->glColorMask(ZZZZ)V
.line 288
invoke-static {v10, v6, v9}, Landroid/opengl/GLES10;->glDrawArrays(III)V
.line 291
iget-object v3, p0, Lcom/android/server/power/ElectronBeam;->mVertexBuffer:Ljava/nio/FloatBuffer;
iget v4, p0, Lcom/android/server/power/ElectronBeam;->mDisplayWidth:I
int-to-float v4, v4
iget v5, p0, Lcom/android/server/power/ElectronBeam;->mDisplayHeight:I
int-to-float v5, v5
invoke-static {v3, v4, v5, v1}, Lcom/android/server/power/ElectronBeam;->setVStretchQuad(Ljava/nio/FloatBuffer;FFF)V
.line 292
invoke-static {v6, v7, v6, v7}, Landroid/opengl/GLES10;->glColorMask(ZZZZ)V
.line 293
invoke-static {v10, v6, v9}, Landroid/opengl/GLES10;->glDrawArrays(III)V
.line 296
iget-object v3, p0, Lcom/android/server/power/ElectronBeam;->mVertexBuffer:Ljava/nio/FloatBuffer;
iget v4, p0, Lcom/android/server/power/ElectronBeam;->mDisplayWidth:I
int-to-float v4, v4
iget v5, p0, Lcom/android/server/power/ElectronBeam;->mDisplayHeight:I
int-to-float v5, v5
invoke-static {v3, v4, v5, v0}, Lcom/android/server/power/ElectronBeam;->setVStretchQuad(Ljava/nio/FloatBuffer;FFF)V
.line 297
invoke-static {v6, v6, v7, v7}, Landroid/opengl/GLES10;->glColorMask(ZZZZ)V
.line 298
invoke-static {v10, v6, v9}, Landroid/opengl/GLES10;->glDrawArrays(III)V
.line 301
invoke-static {v8}, Landroid/opengl/GLES10;->glDisable(I)V
.line 302
const v3, 0x8078
invoke-static {v3}, Landroid/opengl/GLES10;->glDisableClientState(I)V
.line 303
invoke-static {v7, v7, v7, v7}, Landroid/opengl/GLES10;->glColorMask(ZZZZ)V
.line 306
iget v3, p0, Lcom/android/server/power/ElectronBeam;->mMode:I
if-ne v3, v7, :cond_bc
.line 307
const/high16 v3, 0x3f80
invoke-static {v1, v1, v1, v3}, Landroid/opengl/GLES10;->glColor4f(FFFF)V
.line 308
invoke-static {v10, v6, v9}, Landroid/opengl/GLES10;->glDrawArrays(III)V
.line 312
:cond_bc
const v3, 0x8074
invoke-static {v3}, Landroid/opengl/GLES10;->glDisableClientState(I)V
.line 313
const/16 v3, 0xbe2
invoke-static {v3}, Landroid/opengl/GLES10;->glDisable(I)V
.line 314
return-void
.line 271
:cond_c8
const/16 v3, 0x1e01
goto/16 :goto_3f
.end method
3. NEXT find this method
Code:
.method private static setHStretchQuad(Ljava/nio/FloatBuffer;FFF)V
DELETE that line until its .end method
Code:
.method private static setHStretchQuad(Ljava/nio/FloatBuffer;FFF)V
-
-
-
- DELETE that line until its .end method
-
-
-
.end method
and Replace with this
Code:
.method private static setHStretchQuad(Ljava/nio/FloatBuffer;FFF)V
.registers 11
.parameter "vtx"
.parameter "dw"
.parameter "dh"
.parameter "a"
.prologue
const/high16 v6, 0x3f80
const/high16 v5, 0x3f00
.line 354
const/high16 v1, 0x3f80
.line 355
.local v1, w:F
mul-float v4, p1, p3
add-float v0, p1, v4
.line 356
.local v0, h:F
sub-float v4, p1, v6
mul-float v2, v4, v5
.line 357
.local v2, x:F
sub-float v4, p2, v0
mul-float v3, v4, v5
.line 358
.local v3, y:F
invoke-static {p0, v2, v3, v6, v0}, Lcom/android/server/power/ElectronBeam;->setQuad(Ljava/nio/FloatBuffer;FFFF)V
.line 359
return-void
.end method
4. NEXT find this method
Code:
.method private static setVStretchQuad(Ljava/nio/FloatBuffer;FFF)V
Delete that line Until its .end method
Code:
.method private static setVStretchQuad(Ljava/nio/FloatBuffer;FFF)V
-
-
-
- DELETE that line until its .end method
-
-
-
-.end.method
and Replace with this
Code:
.method private static setVStretchQuad(Ljava/nio/FloatBuffer;FFF)V
.registers 10
.parameter "vtx"
.parameter "dw"
.parameter "dh"
.parameter "a"
.prologue
const/high16 v5, 0x3f00
.line 346
mul-float v4, p1, p3
sub-float v1, p1, v4
.line 347
.local v1, w:F
mul-float v4, p2, p3
add-float v0, p2, v4
.line 348
.local v0, h:F
sub-float v4, p1, v1
mul-float v2, v4, v5
.line 349
.local v2, x:F
sub-float v4, p2, v0
mul-float v3, v4, v5
.line 350
.local v3, y:F
invoke-static {p0, v2, v3, v1, v0}, Lcom/android/server/power/ElectronBeam;->setQuad(Ljava/nio/FloatBuffer;FFFF)V
.line 351
return-void
.end method
DONE !!! and Compile.
wonderful/aweful Mod and Guide....
Hi Hi and gongrats for your great work and your effort! Hats up and :highfive::good:....I tried to realize this since hours, days...yes even weeks...got lot of headaches and finally almost gave up....but now you did it...many thanks for it and for the guide and sharing your knowledge!!
I already got it "portet" to Galaxy S1 and Supernexus Rom...and it sure works .
Do you mind, and do you give me your permission to use it in a new Thread in the Themes/Apps section of SGS1? I am thinking of title the thread for CM10.1 Nightlys as you did, but if there are inquiries from users for other ROMs I would like to fullfill them in that thread too. Sure all thanks and credits will only go to you and I mention you and your threads in the very first position of my OP.
rodman01 said:
Hi Hi and gongrats for your great work and your effort! Hats up and :highfive::good:....I tried to realize this since hours, days...yes even weeks...got lot of headaches and finally almost gave up....but now you did it...many thanks for it and for the guide and sharing your knowledge!!
I already got it "portet" to Galaxy S1 and Supernexus Rom...and it sure works .
Do you mind, and do you give me your permission to use it in a new Thread in the Themes/Apps section of SGS1? I am thinking of title the thread for CM10.1 Nightlys as you did, but if there are inquiries rom users for other ROMs I would like to fullfill them in that thread too. Sure all thanks and credits will only go to you and I mention you and your threads in the very first position of my OP.
Click to expand...
Click to collapse
No problem.. you can re-post it again with your own style packaging..
And Glad to know it work to your device :thumbup:
Sent from my GT-I8150 using xda app-developers app
THANK YOU!!!!!!!!!!!!
@Adi Aisiteru Reborn
You'v helped me soooooooooooooo much!!! Thank you for a wonderful guide!!!!
:good:
I have a question, you seem to be quite skilled in modding the cm10.1 platform. Would you by any chance know how to make the notification item bg transparent or at least replace it with a nice transparent pic? I've been replacing .9.pngs and working on both framework-res and SystemUI and I can't seem to get it done no matter what I do.
Any clue?
Any suggestion would be highly appreciated!!!
Thank you in advance,
Dax
Thanks can you add one to make the navigation bar transparent too
Sent from my Galaxy Nexus using xda premium
daxgirl said:
@Adi Aisiteru Reborn
You'v helped me soooooooooooooo much!!! Thank you for a wonderful guide!!!!
:good:
I have a question, you seem to be quite skilled in modding the cm10.1 platform. Would you by any chance know how to make the notification item bg transparent or at least replace it with a nice transparent pic? I've been replacing .9.pngs and working on both framework-res and SystemUI and I can't seem to get it done no matter what I do.
Any clue?
Any suggestion would be highly appreciated!!!
Thank you in advance,
Dax
Click to expand...
Click to collapse
you mean like this :
DECOMPILE framework-res.apk
/res/drawable/notification_bg.xml
BEFORE
LINE xml 5
Code:
<item android:state_pressed="false" android:drawable=[COLOR="Red"]"@drawable/notification_bg_normal"[/COLOR] />
CHANGE IT TO
Code:
<item android:state_pressed="false" android:drawable=[COLOR="Red"]"@drawable/notification_item_background_color"[/COLOR] />
NEXT
/res/values/drawables.xml
Code:
<item type="drawable" name="notification_item_background_color">[COLOR="Red"]#00000000[/COLOR]</item>
DONE , AND COMPILE,. no need 9.png :good::laugh:
nirvanax said:
Thanks can you add one to make the navigation bar transparent too
Sent from my Galaxy Nexus using xda premium
Click to expand...
Click to collapse
sure I will,. just wait for that..
EDIT,. I've tried it, but the navbar still show black background
I will try to solve this
Wow many thanks for the QuickSettings 4/5 columns how-to!
For me it's simple..if no QuickSettings 4 columns choice in a rom I prefer keep it up with power toggles.
Something could be added mainly for a 5 columns choice maybe, text on tiles appears often truncated with 5 columns so a way to un-display text on tiles would be great.
It could be done artificially too by changing tiles text color to be the same as tiles background maybe? I have no real idea about it if possible or not (maybe text on tiles is "same"text used on others parts?), personally i only made tiles backround color changes for now (since Rodman01 once talked to me about this ).
Thanks!
Bejda said:
Wow many thanks for the QuickSettings 4/5 columns how-to!
For me it's simple..if no QuickSettings 4 columns choice in a rom I prefer keep it up with power toggles.
Something could be added mainly for a 5 columns choice maybe, text on tiles appears often truncated with 5 columns so a way to un-display text on tiles would be great.
It could be done artificially too by changing tiles text color to be the same as tiles background maybe? I have no real idea about it if possible or not (maybe text on tiles is "same"text used on others parts?), personally i only made tiles backround color changes for now (since Rodman01 once talked to me about this ).
Thanks!
Click to expand...
Click to collapse
can you explain it more specific ?
give me example screenshot bro,.
ADDED - GUIDE TRANSPARENT LOCKSCREEN IN POST #5
:good::laugh:
Some tweaking for your mod
Hi Adi!
Did some tweaking to your quick settings mode. If you like it (or anyone else for that matter), here is how it goes:
Decompile SystemUI.apk
Navigate to res/drawable/qs_tile_background.xml
Replace the entire content of the document with my code:
Code:
<?xml version="1.0" encoding="utf-8"?>
<selector
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true">
<shape>
<solid android:color="#7f33b5e5" />
<stroke
android:width="1dp"
android:color="#ffffffff" />
<corners
android:radius="3dp" />
</shape>
</item>
<item>
<shape>
<gradient
android:startColor="#7fffffff"
android:centerColor="#00000000"
android:endColor="#7fffffff"
android:angle="270"
android:centerX="0.2"
android:centerY="0.3" />
<stroke
android:width="1dp"
android:color="#ff33b5e5" />
<corners
android:radius="4dp" />
</shape>
</item>
</selector>
The picture is with 4 columns. Since the mod is in XML it doesn't matter how many columns you create - it'll fit
Some additional things that I modded here:
res/values/dimens.xml
Code:
<dimen name="quick_settings_cell_gap">[COLOR="Red"]3.0dip[/COLOR]</dimen>
res/values/styles.xml
Code:
<style name="TextAppearance.QuickSettings.TileView" parent="@style/TextAppearance.QuickSettings">
<item name="android:textSize">[COLOR="red"]11.0dip[/COLOR]</item>
<item name="android:textStyle">[COLOR="red"]bold[/COLOR]</item>
<item name="android:textColor">[COLOR="red"]#ffffffff[/COLOR]</item>
<item name="android:ellipsize">marquee</item>
<item name="android:paddingLeft">6.0dip</item>
<item name="android:paddingRight">6.0dip</item>
<item name="android:paddingBottom">2.0dip</item>
<item name="android:fadingEdge">horizontal</item>
<item name="android:singleLine">true</item>
<item name="android:drawablePadding">12.0dip</item>
<item name="android:textAllCaps">[COLOR="red"]false[/COLOR]</item>
Cheers!!!
daxgirl said:
Hi Adi!
Did some tweaking to your quick settings mode. If you like it (or anyone else for that matter), here is how it goes:
Decompile SystemUI.apk
Navigate to res/drawable/qs_tile_background.xml
Replace the entire content of the document with my code:
Code:
<?xml version="1.0" encoding="utf-8"?>
<selector
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true">
<shape>
<solid android:color="#7f33b5e5" />
<stroke
android:width="1dp"
android:color="#ffffffff" />
<corners
android:radius="3dp" />
</shape>
</item>
<item>
<shape>
<gradient
android:startColor="#7fffffff"
android:centerColor="#00000000"
android:endColor="#7fffffff"
android:angle="270"
android:centerX="0.2"
android:centerY="0.3" />
<stroke
android:width="1dp"
android:color="#ff33b5e5" />
<corners
android:radius="4dp" />
</shape>
</item>
</selector>
The picture is with 4 columns. Since the mod is in XML it doesn't matter how many columns you create - it'll fit
Some additional things that I modded here:
res/values/dimens.xml
Code:
<dimen name="quick_settings_cell_gap">[COLOR="Red"]3.0dip[/COLOR]</dimen>
res/values/styles.xml
Code:
<style name="TextAppearance.QuickSettings.TileView" parent="@style/TextAppearance.QuickSettings">
<item name="android:textSize">[COLOR="red"]11.0dip[/COLOR]</item>
<item name="android:textStyle">[COLOR="red"]bold[/COLOR]</item>
<item name="android:textColor">[COLOR="red"]#ffffffff[/COLOR]</item>
<item name="android:ellipsize">marquee</item>
<item name="android:paddingLeft">6.0dip</item>
<item name="android:paddingRight">6.0dip</item>
<item name="android:paddingBottom">2.0dip</item>
<item name="android:fadingEdge">horizontal</item>
<item name="android:singleLine">true</item>
<item name="android:drawablePadding">12.0dip</item>
<item name="android:textAllCaps">[COLOR="red"]false[/COLOR]</item>
Cheers!!!
Click to expand...
Click to collapse
Nice Broo, :good::laugh:
I 'll put this post to first post :good:
THANKS
Adi Aisiteru Reborn said:
Nice Broo, :good::laugh:
I 'll put this post to first post :good:
THANKS
Click to expand...
Click to collapse
You're welcome. Anytime!!! It was created on Galaxy S. I'll post it there at some point with full credit to you for the 4clmn QS mod of course Keep up the great work!!!
P.S. it's not broo. if anything, it's sis
Cheers, mate!
daxgirl said:
You're welcome. Anytime!!! It was created on Galaxy S. I'll post it there at some point with full credit to you for the 4clmn QS mod of course Keep up the great work!!!
P.S. it's not broo. if anything, it's sis
Cheers, mate!
Click to expand...
Click to collapse
DONE in first post, please Check sist
Cancelling autodimming for transparent status bar
Thanks, appreciate it
One more thing I forgot to tell you. It's about the transparent status bar.
As you know, google introduced the autodimming of notification icons (top left) couple APIs back.
So when you set the status bar to transparent, the icons look dim and kinda transparent and not at all easy to see on any wallpaper.
In order to tweak the notifications drawing alpha, go to:
SystemUI.apk/res/values/dimens.xml
find this dimen:
Code:
<item type="dimen" name="status_bar_icon_drawing_alpha">[COLOR="Green"]65.0%[/COLOR]</item>
and change the percentage value to anything you want. Usually I'm using rather bright wallpapers, so I set it to 100%.
You can just increase it to whatever value you want and find nicely visible
Cheers!!!
Guide for CyanogenMod11 KOT49H
Navigationbar Enabler, Navigation bar dimension, StatusBar Clock and Date Style, QuickSettings with 3,4,5 per row, NetworkTrafic thingking bridge/ChaOS
Hello guys, I want to share to you Guide how to with settings.
1. Navbar Enable/Disable, Navbar dimension
2. Status bar clock style, choose normal/center, add date to clock, date format, add AM/PM to clock, colorpicker style
3. QuickSettings with 3,4, or 5 per row
4. Network traffic thingking bridge , Chameleon OS style, colorpicker style
This guide will only working for pure CM11 KK 4.4.2 ( Don't try this on stock KK AOSP, due to different structure of APK and etc with CM11 )
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 and JAR file
- notepad++
- Tool for decompiling, : apkmanager/apktool/Virtous/apkmultitools/ or else
All these changes will work on the fly with no reboot necessary :good::laugh:
SETTINGS.APK
STEP-1
Decompile Settings.apk
1. go to Settings.apk/res/values/
Add the following at the end of the file
arrays.xml
Code:
<string-array name="clock_style_entries">
<item>@string/right_clock</item>
<item>@string/center_clock</item>
</string-array>
<string-array name="clock_style_values">
<item>0</item>
<item>1</item>
</string-array>
<string-array name="entries_status_bar_am_pm">
<item>@string/am_pm_clock_none</item>
<item>@string/am_pm_clock_small</item>
<item>@string/am_pm_clock_normal</item>
</string-array>
<string-array name="values_status_bar_am_pm">
<item>0</item>
<item>1</item>
<item>2</item>
</string-array>
<string-array name="clock_date_display_entries">
<item>@string/clock_date_display_none</item>
<item>@string/clock_date_display_small</item>
<item>@string/clock_date_display_normal</item>
</string-array>
<string-array name="clock_date_display_values">
<item>0</item>
<item>1</item>
<item>2</item>
</string-array>
<string-array name="clock_date_style_entries">
<item>@string/clock_date_style_normal</item>
<item>@string/clock_date_style_lowercase</item>
<item>@string/clock_date_style_uppercase</item>
</string-array>
<string-array name="clock_date_style_values">
<item>0</item>
<item>1</item>
<item>2</item>
</string-array>
<string-array name="clock_date_format_entries_values">
<item>dd/MM/yy</item>
<item>MM/dd/yy</item>
<item>yyyy-MM-dd</item>
<item>yyyy-dd-MM</item>
<item>dd-MM-yyyy</item>
<item>MM-dd-yyyy</item>
<item>MMM dd</item>
<item>MMM dd, yyyy</item>
<item>MMMM dd, yyyy</item>
<item>EEE</item>
<item>EEE dd</item>
<item>EEE dd/MM</item>
<item>EEE MM/dd</item>
<item>EEE dd MMM</item>
<item>EEE MMM dd</item>
<item>EEE MMMM dd</item>
<item>EEEE dd/MM</item>
<item>EEEE MM/dd</item>
<item>@string/clock_date_format_custom</item>
</string-array>
<string-array name="entries_status_bar_network_stats_update">
<item>½ second</item>
<item>1 second</item>
<item>2 seconds</item>
<item>5 seconds</item>
</string-array>
<string-array name="values_status_bar_network_stats_update">
<item>500</item>
<item>1000</item>
<item>2000</item>
<item>5000</item>
</string-array>
<string-array name="navigation_bar_width_entries">
<item>@string/navigation_bar_size_42_dp_default</item>
<item>@string/navigation_bar_size_40_dp</item>
<item>@string/navigation_bar_size_36_dp</item>
<item>@string/navigation_bar_size_30_dp</item>
<item>@string/navigation_bar_size_24_dp</item>
<item>@string/navigation_bar_size_0_dp</item>
</string-array>
<string-array name="navigation_bar_width">
<item>42</item>
<item>40</item>
<item>36</item>
<item>30</item>
<item>24</item>
<item>0</item>
</string-array>
<string-array name="navigation_bar_height_entries">
<item>@string/navigation_bar_size_48_dp_default</item>
<item>@string/navigation_bar_size_44_dp</item>
<item>@string/navigation_bar_size_42_dp</item>
<item>@string/navigation_bar_size_40_dp</item>
<item>@string/navigation_bar_size_36_dp</item>
<item>@string/navigation_bar_size_30_dp</item>
<item>@string/navigation_bar_size_24_dp</item>
<item>@string/navigation_bar_size_0_dp</item>
</string-array>
<string-array name="navigation_bar_height">
<item>48</item>
<item>44</item>
<item>42</item>
<item>40</item>
<item>36</item>
<item>30</item>
<item>24</item>
<item>0</item>
</string-array>
<string-array name="tiles_per_row_entries">
<item>3</item>
<item>4</item>
<item>5</item>
</string-array>
<string-array name="tiles_per_row_values">
<item>3</item>
<item>4</item>
<item>5</item>
</string-array>
ids.xml
Code:
<item type="id" name="hex">false</item>
<item type="id" name="enter">false</item>
<item type="id" name="white_panel">false</item>
<item type="id" name="black_panel">false</item>
<item type="id" name="cyan_panel">false</item>
<item type="id" name="red_panel">false</item>
<item type="id" name="green_panel">false</item>
<item type="id" name="yellow_panel">false</item>
<item type="id" name="old_color_panel">false</item>
<item type="id" name="new_color_panel">false</item>
dimens.xml
Code:
<item type="dimen" name="settings_side_margin">@*android:dimen/preference_fragment_padding_side</item>
<dimen name="navigation_bar_48">48.0dip</dimen>
<dimen name="navigation_bar_44">44.0dip</dimen>
<dimen name="navigation_bar_42">42.0dip</dimen>
<dimen name="navigation_bar_40">40.0dip</dimen>
<dimen name="navigation_bar_36">36.0dip</dimen>
<dimen name="navigation_bar_30">30.0dip</dimen>
<dimen name="navigation_bar_24">24.0dip</dimen>
<dimen name="navigation_bar_0">0.0dip</dimen>
strings.xml
Code:
<string name="reset">Reset</string>
<string name="enabled">Enabled</string>
<string name="attention">Attention</string>
<string name="default_string">Default</string>
<string name="reset_message">Reset all entries to default?</string>
<string name="style_title">Style</string>
<string name="alerts_and_warnings_title">Alerts and warnings</string>
<string name="alerts_and_warnings_style_title">Alerts and warnings options</string>
<string name="sound_title">Sound</string>
<string name="sound_settings_title">Sound settings</string>
<string name="dialog_color_picker">Color Picker</string>
<string name="press_color_to_apply">Press on color below to apply</string>
<string name="arrow_right">→</string>
<string name="arrow_down">↓</string>
<string name="hex">Hex:</string>
<string name="hex_hint">\#ff000000</string>
<string name="set">Set</string>
<string name="status_bar_style_title">Status bar options</string>
<string name="status_bar_general_title">General</string>
<string name="status_bar_clock">Clock and date</string>
<string name="status_bar_clock_title">Clock and date style</string>
<string name="clock_title_enable">Alignment</string>
<string name="clock_enabled">Enabled</string>
<string name="clock_disabled">Disabled</string>
<string name="clock_color_title">Color</string>
<string name="status_bar_clock_style_reset">Reset color</string>
<string name="status_bar_am_pm_title">AM/PM</string>
<string name="status_bar_am_pm_info">24-hour clock is enabled</string>
<string name="enable_clock_weekday">Day of the week</string>
<string name="enable_clock_weekday_summary">Abbreviated day of the week before the time</string>
<string name="right_clock">Right clock</string>
<string name="center_clock">Center clock</string>
<string name="dont_show">"Don't show"</string>
<string name="clock_date_display">Date</string>
<string name="clock_date_display_summary">Display custom date before the clock</string>
<string name="clock_date_style">Date style</string>
<string name="clock_date_format">Date format</string>
<string name="clock_date_string_edittext_title">Must be in DateFormat eg. MM/dd/yy</string>
<string name="clock_date_string_edittext_summary">Enter string</string>
<string name="am_pm_clock_normal">Normal font size</string>
<string name="am_pm_clock_small">Small font size</string>
<string name="am_pm_clock_none">"Don't show"</string>
<string name="clock_date_display_none">"Don't show"</string>
<string name="clock_date_display_small">Small font size</string>
<string name="clock_date_display_normal">Normal font size</string>
<string name="clock_date_style_normal">Normal</string>
<string name="clock_date_style_lowercase">Lowercase</string>
<string name="clock_date_style_uppercase">Uppercase</string>
<string name="clock_date_format_custom">Custom java format</string>
<string name="status_bar_clock_style_reset_message">Reset clock color?</string>
<string name="notification_drawer_style_title">Notification drawer options</string>
<string name="notification_style_summary">Change your notification drawer style</string>
<string name="general_settings_title">General settings</string>
<string name="general_settings_style_title">General options</string>
<string name="display_short">Display</string>
<string name="misc_short">Misc</string>
<string name="alt_resolver">Use Alt Default App Grid</string>
<string name="alt_resolver_summary">Use Alternate Default App Picker</string>
<string name="status_bar_network_cat">Network traffic meter</string>
<string name="status_bar_network_header">Network traffic meter</string>
<string name="status_bar_network_title">Network traffic</string>
<string name="status_bar_show_network_stats_title">Show network speeds</string>
<string name="status_bar_network_stats_update_title">Update frequency</string>
<string name="status_bar_network_usage_color_style">Color style</string>
<string name="status_bar_network_usage_color_reset">Reset color</string>
<string name="status_bar_network_usage_color_reset_message">Reset network stats color to default?</string>
<string name="hide_network_speed">Hide when there is no traffic</string>
<string name="hide_network_speed_summary">Hide network stats indicator when there is no traffic</string>
<string name="navbar_enable_bar">Enable navigation bar</string>
<string name="navbar_enable_bar_summary">Enable the navigation bar</string>
<string name="navbar_style_dimen_title">Dimensions</string>
<string name="navbar_dimensions_reset_message">Reset all dimensions entries to default?</string>
<string name="navigation_bar_height_title">Navigation bar height</string>
<string name="navigation_bar_height_summary">Navigation bar height while in portrait</string>
<string name="navigation_bar_width_title">Navigation bar width</string>
<string name="navigation_bar_width_summary">Navigation bar height if the bar is along a side</string>
<string name="navigation_bar_size_42_dp_default">42 dp (default)</string>
<string name="navigation_bar_size_36_dp">36 dp</string>
<string name="navigation_bar_size_30_dp">30 dp</string>
<string name="navigation_bar_size_24_dp">24 dp</string>
<string name="navigation_bar_size_48_dp_default">48 dp (default)</string>
<string name="navigation_bar_size_44_dp">44 dp</string>
<string name="navigation_bar_size_40_dp">40 dp</string>
<string name="navigation_bar_size_42_dp">42 dp</string>
<string name="navigation_bar_size_0_dp">0 dp (off)</string>
<string name="notification_style_title">Notification drawer style</string>
<string name="status_bar_network_traffic">Network speed meter</string>
<string name="status_bar_network_traffic_summary">Show network speed in statusbar (Thinking Bridge)</string>
<string name="status_bar_network_cat_summary">Show network traffic in statusbar (ChameleonOS)</string>
<string name="quicksettings_tiles_style">Quick Settings style</string>
<string name="summary_quicksettings_tiles_style">Show or change Quick Settings style options</string>
<string name="quicksettings_tiles_style_additional_options">Additional options</string>
<string name="tiles_per_row_title">Tiles per row</string>
<string name="tiles_per_row_duplicate_landscape_title">Scale landscape quantity</string>
<string name="tiles_per_row_duplicate_landscape_summary">Landscape view doubles tiles per row quantity</string>
<string name="qs_reset">Reset</string>
<string name="status_bar_show_network_traffic_title">Show network speeds</string>
2. Settings.apk/res/xml/
status_bar.xml
remove all lines and replace all by this :
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen android:title="@string/status_bar_title"
xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceCategory android:title="@string/status_bar_style_title">
<PreferenceScreen android:title="@string/status_bar_clock" android:key="clock_style_pref" android:fragment="com.android.settings.adi.StatusBarClockStyle" />
<PreferenceScreen android:title="@string/status_bar_network_cat" android:key="network_usage_stats" android:summary="@string/status_bar_network_cat_summary" android:fragment="com.android.settings.adi.NetworkUsageStats" />
<PreferenceScreen android:title="@string/status_bar_network_traffic" android:key="traffic_usage_stats" android:summary="@string/status_bar_network_traffic_summary" android:fragment="com.android.settings.adi.Traffic" />
</PreferenceCategory>
<PreferenceCategory android:title="@string/status_bar_general_title">
<ListPreference android:entries="@array/entries_status_bar_battery" android:title="@string/status_bar_battery_title" android:key="status_bar_battery" android:defaultValue="0" android:dialogTitle="@string/status_bar_battery_title" android:entryValues="@array/values_status_bar_battery" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/status_bar_battery_show_percent_title" android:key="status_bar_battery_show_percent" android:defaultValue="false" />
<ListPreference android:entries="@array/entries_status_bar_signal" android:title="@string/status_bar_signal_text_title" android:key="status_bar_signal" android:dialogTitle="@string/status_bar_signal_text_title" android:entryValues="@array/values_status_bar_signal" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/status_bar_toggle_brightness" android:key="status_bar_brightness_control" android:summary="@string/status_bar_toggle_brightness_summary" android:defaultValue="false" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/status_bar_notif_count_title" android:key="status_bar_notif_count" android:summary="@string/status_bar_notif_count_summary" android:defaultValue="false" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/status_bar_double_tap_to_sleep_title" android:key="double_tap_sleep_gesture" android:defaultValue="false" />
</PreferenceCategory>
</PreferenceScreen>
system_ui_settings.xml
change to like in 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/status_bar_title" android:key="status_bar" android:fragment="com.android.settings.cyanogenmod.StatusBar" />
<PreferenceScreen android:title="@string/quick_settings_panel_title" android:key="quick_settings_panel" android:fragment="com.android.settings.quicksettings.QuickSettings" />
<PreferenceScreen android:title="@string/notification_drawer_title" android:key="notification_drawer" android:fragment="com.android.settings.cyanogenmod.NotificationDrawer" />
<ListPreference android:persistent="false" android:entries="@array/expanded_desktop_entries" android:title="@string/power_menu_expanded_desktop" android:key="expanded_desktop" android:entryValues="@array/expanded_desktop_values" />
<CheckBoxPreference android:persistent="true" android:title="@string/power_menu_expanded_desktop" android:key="expanded_desktop_no_navbar" />
<Preference android:key="touch_screen_gesture_settings">
<intent android:targetPackage="com.cyanogenmod.settings.device" android:action="com.cyanogenmod.action.LAUNCH_TOUCHSCREEN_GESTURE_SETTINGS" android:targetClass="com.cyanogenmod.settings.device.TouchscreenGestureSettings" />
</Preference>
[COLOR="Red"]<PreferenceCategory android:title="@string/navigation_bar_category">
<CheckBoxPreference android:title="@string/navbar_enable_bar" android:key="enable_nav_bar" android:summary="@string/navbar_enable_bar_summary" />
<PreferenceScreen android:title="@string/navbar_style_dimen_title" android:key="navbar_dimen_settings" android:fragment="com.android.settings.adi.NavbarDimenSettings" />
<PreferenceScreen android:title="@string/navigation_bar_title" android:key="navigation_bar" android:fragment="com.android.settings.cyanogenmod.NavBar" />
<PreferenceScreen android:title="@string/navigation_ring_title" android:key="navigation_ring" android:fragment="com.android.settings.cyanogenmod.NavRing" />
</PreferenceCategory>[/COLOR]
</PreferenceScreen>
quick_settings_panel.xml
add the red code
Code:
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen
xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceCategory android:title="@string/title_general" android:key="pref_general_settings">
[COLOR="Red"]<PreferenceScreen android:title="@string/quicksettings_tiles_style" android:key="quicksettings_tiles_style" android:summary="@string/summary_quicksettings_tiles_style" android:fragment="com.android.settings.adi.QuickSettingsTilesStyle" />[/COLOR]
<ListPreference android:persistent="false" android:entries="@array/quick_pulldown_entries" android:title="@string/title_quick_pulldown" android:key="quick_pulldown" android:entryValues="@array/quick_pulldown_values" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_collapse_panel" android:key="qs_collapse_panel" android:summary="@string/summary_collapse_panel" />
</PreferenceCategory>
<PreferenceCategory android:title="@string/title_static_tiles" android:key="static_tiles">
<PreferenceScreen android:title="@string/tile_picker_title" android:key="tile_picker" android:summary="@string/tile_picker_summary" android:fragment="com.android.settings.quicksettings.QuickSettingsTiles" />
<MultiSelectListPreference android:entries="@array/entries_ring_widget" android:title="@string/pref_ring_mode_title" android:key="pref_ring_mode" android:summary="@string/pref_ring_mode_summary" android:dialogTitle="@string/pref_ring_mode_title" android:entryValues="@array/values_ring_widget" />
<ListPreference android:entries="@array/entries_network_widget" android:title="@string/pref_network_mode_title" android:key="pref_network_mode" android:dialogTitle="@string/pref_network_mode_title" android:entryValues="@array/values_network_widget" />
<ListPreference android:entries="@array/entries_screentimeout_widget" android:title="@string/pref_screentimeout_mode_title" android:key="pref_screentimeout_mode" android:dialogTitle="@string/pref_screentimeout_mode_title" android:entryValues="@array/values_screentimeout_widget" />
</PreferenceCategory>
<PreferenceCategory android:title="@string/title_dynamic_tiles" android:key="pref_dynamic_tiles">
<Preference android:title="@string/dynamic_tiles_note_title" android:selectable="false" android:summary="@string/dynamic_tiles_note_summary" style="?android:preferenceInformationStyle" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_dynamic_alarm" android:key="qs_dyanmic_alarm" android:defaultValue="true" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_dynamic_bugreport" android:key="qs_dyanmic_bugreport" android:defaultValue="true" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_dynamic_dock_battery" android:key="qs_dyanmic_dock_battery" android:defaultValue="true" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_dynamic_ime" android:key="qs_dyanmic_ime" android:defaultValue="true" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_dynamic_usbtether" android:key="qs_dyanmic_usbtether" android:defaultValue="true" />
<com.android.settings.cyanogenmod.SystemSettingCheckBoxPreference android:title="@string/title_dynamic_wifi" android:key="qs_dyanmic_wifi" android:defaultValue="true" />
</PreferenceCategory>
</PreferenceScreen>
Next Download attached on_the_fly_CM11_Settings.apk_by_Adi.zip, exstract it and merge to your decompiled Settings.apk
and compile your settings,apk
continue to STEP-2 in POST#2
STEP-2
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 on_the_fly_CM11_Settings.apk_public.xml
so now you have two public.xml which is opened in the Notepad++
1. your secondly decompiled Settings.apk public.xml and
2. on_the_fly_CM11_Settings.apk_public.xml
- Next go to all smalis you've merged to your settings.apk
find all ids which is started with :
Code:
0x7f[COLOR="Red"]xxxxxx[/COLOR]
and search it in on_the_fly_CM11_Settings.apk_public.xml
change, match the ids in the smali with your own new secondly decompiled public.xml
Done and recompile your settings.apk
SYSTEMUI.APK
STEP-1
Decompile SystemUI.apk
Download attached new_on_the_fly_CM11_SystemUI.apk.zip extract it and merge to your decompiled SystemUI.apk
1. go to SystemUI.apk/res/values/
Add the following at the end of the file
ids.xml
Code:
<item type="id" name="network_stats">false</item>
<item type="id" name="bytes_tx">false</item>
<item type="id" name="bytes_rx">false</item>
<item type="id" name="center_clock_layout">false</item>
<item type="id" name="center_clock">false</item>
<item type="id" name="traffic">false</item>
<item type="id" name="background">false</item>
dimens.xml
Code:
<dimen name="network_stats_text_size">9.0dip</dimen>
<dimen name="qs_4_column_text_padding">14.0dip</dimen>
<dimen name="qs_5_column_text_padding">12.0dip</dimen>
<dimen name="qs_3_column_text_size">12.0sp</dimen>
<dimen name="qs_4_column_text_size">10.0sp</dimen>
<dimen name="qs_5_column_text_size">9.0sp</dimen>
styles.xml
Code:
<style name="TextAppearance.StatusBar.NetworkStats" parent="@*android:style/TextAppearance.StatusBar">
<item name="android:textSize">@dimen/network_stats_text_size</item>
<item name="android:textColor">#ffffffff</item>
<item name="android:layout_gravity">center_vertical</item>
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_weight">1.0</item>
</style>
<style name="TextAppearance.StatusBar.Traffic" parent="@*android:style/TextAppearance.StatusBar.Icon">
<item name="android:textSize">11.0dip</item>
<item name="android:textStyle">normal</item>
<item name="android:textColor">#ffffffff</item>
</style>
2. SystemUI.apk/smali/com/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver.smali
add the red code
Code:
const-string v1, "status_bar_clock"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 373
const-string v1, "status_bar_signal"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
[COLOR="Red"]const-string v1, "quick_tiles_per_row"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 373
const-string v1, "quick_tiles_per_row_duplicate_landscape"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V[/COLOR]
.line 375
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$SettingsObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateSettings()V
invoke-static {v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$300(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.line 376
return-void
.end method
3. SystemUI.apk/smali/com/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver.smali
add the red code
Code:
.method public onChange(ZLandroid/net/Uri;)V
.locals 7
.parameter "selfChange"
.parameter "uri"
.prologue
const/4 v6, -0x2
const/4 v2, 0x1
const/4 v3, 0x0
.line 3301
if-eqz p2, :cond_3
const-string v4, "qs_quick_access"
invoke-static {v4}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v4
invoke-virtual {p2, v4}, Landroid/net/Uri;->equals(Ljava/lang/Object;)Z
move-result v4
if-eqz v4, :cond_3
.line 3303
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v4, v4, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v4}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
.line 3304
.local v1, resolver:Landroid/content/ContentResolver;
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
const-string v5, "qs_quick_access"
invoke-static {v1, v5, v3, v6}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v5
if-ne v5, v2, :cond_1
:goto_0
#setter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHasQuickAccessSettings:Z
invoke-static {v4, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4702(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Z)Z
.line 3306
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHasQuickAccessSettings:Z
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4700(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Z
move-result v2
if-eqz v2, :cond_2
.line 3307
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->inflateRibbon()V
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4800(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.line 3308
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRibbonView:Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;
move-result-object v2
invoke-virtual {v2, v3}, Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;->setVisibility(I)V
.line 3335
.end local v1 #resolver:Landroid/content/ContentResolver;
:cond_0
:goto_1
return-void
.restart local v1 #resolver:Landroid/content/ContentResolver;
:cond_1
move v2, v3
.line 3304
goto :goto_0
.line 3310
:cond_2
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->cleanupRibbon()V
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
goto :goto_1
.line 3312
.end local v1 #resolver:Landroid/content/ContentResolver;
:cond_3
if-eqz p2, :cond_5
const-string v4, "qs_quick_access_linked"
invoke-static {v4}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v4
invoke-virtual {p2, v4}, Landroid/net/Uri;->equals(Ljava/lang/Object;)Z
move-result v4
if-eqz v4, :cond_5
.line 3314
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v4, v4, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v4}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
.line 3315
.restart local v1 #resolver:Landroid/content/ContentResolver;
const-string v4, "qs_quick_access_linked"
invoke-static {v1, v4, v2, v6}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v4
if-ne v4, v2, :cond_4
move v0, v2
.line 3317
.local v0, layoutLinked:Z
:goto_2
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickAccessLayoutLinked:Z
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5100(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Z
move-result v2
if-eq v2, v0, :cond_0
.line 3319
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#setter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickAccessLayoutLinked:Z
invoke-static {v2, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5102(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Z)Z
.line 3320
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->cleanupRibbon()V
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.line 3321
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->inflateRibbon()V
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4800(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.line 3322
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRibbonView:Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;
move-result-object v2
invoke-virtual {v2, v3}, Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;->setVisibility(I)V
goto :goto_1
.end local v0 #layoutLinked:Z
:cond_4
move v0, v3
.line 3315
goto :goto_2
.line 3324
.end local v1 #resolver:Landroid/content/ContentResolver;
:cond_5
if-eqz p2, :cond_6
const-string v2, "quick_settings_ribbon_tiles"
invoke-static {v2}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v2
invoke-virtual {p2, v2}, Landroid/net/Uri;->equals(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_6
.line 3326
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->cleanupRibbon()V
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.line 3327
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->inflateRibbon()V
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4800(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
.line 3328
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRibbonView:Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$4900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;
move-result-object v2
invoke-virtual {v2, v3}, Lcom/android/systemui/statusbar/phone/QuickSettingsHorizontalScrollView;->setVisibility(I)V
goto :goto_1
.line 3329
:cond_6
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v2, v2, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsContainer:Lcom/android/systemui/statusbar/phone/QuickSettingsContainerView;
if-eqz v2, :cond_0
[COLOR="Red"]iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v2, v2, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsContainer:Lcom/android/systemui/statusbar/phone/QuickSettingsContainerView;
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/QuickSettingsContainerView;->removeAllViews()V[/COLOR]
.line 3330
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v2, v2, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQS:Lcom/android/systemui/statusbar/phone/QuickSettingsController;
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/QuickSettingsController;->setupQuickSettings()V
[COLOR="Red"]iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v2, v2, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsContainer:Lcom/android/systemui/statusbar/phone/QuickSettingsContainerView;
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/QuickSettingsContainerView;->updateResources()V[/COLOR]
.line 3331
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mQuickAccessLayoutLinked:Z
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5100(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Z
move-result v2
if-eqz v2, :cond_0
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRibbonQS:Lcom/android/systemui/statusbar/phone/QuickSettingsController;
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5200(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Lcom/android/systemui/statusbar/phone/QuickSettingsController;
move-result-object v2
if-eqz v2, :cond_0
.line 3332
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRibbonQS:Lcom/android/systemui/statusbar/phone/QuickSettingsController;
invoke-static {v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$5200(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Lcom/android/systemui/statusbar/phone/QuickSettingsController;
move-result-object v2
invoke-virtual {v2}, Lcom/android/systemui/statusbar/phone/QuickSettingsController;->setupQuickSettings()V
goto/16 :goto_1
.end method
Remove all this lines
Code:
.method public startObserving()V
.locals 4
.prologue
const/4 v3, 0x0
const/4 v2, -0x1
.line 3338
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v1, v1, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
.line 3339
.local v0, cr:Landroid/content/ContentResolver;
const-string v1, "quick_settings_tiles"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3343
const-string v1, "qs_dyanmic_alarm"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3347
const-string v1, "qs_dyanmic_bugreport"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3351
const-string v1, "qs_dyanmic_dock_battery"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3355
const-string v1, "qs_dyanmic_ime"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3359
const-string v1, "qs_dyanmic_usbtether"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3363
const-string v1, "qs_dyanmic_wifi"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3367
const-string v1, "qs_quick_access"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3371
const-string v1, "qs_quick_access_linked"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3375
const-string v1, "quick_settings_ribbon_tiles"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3378
return-void
.end method
Replace with this :
Code:
[COLOR="Blue"].method public startObserving()V
.locals 4
.prologue
const/4 v3, -0x1
const/4 v2, 0x0
.line 3407
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$TilesChangedObserver;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v1, v1, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v0
.line 3408
.local v0, cr:Landroid/content/ContentResolver;
const-string v1, "quick_settings_tiles"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3412
const-string v1, "qs_dyanmic_alarm"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3416
const-string v1, "qs_dyanmic_bugreport"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3420
const-string v1, "qs_dyanmic_dock_battery"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3424
const-string v1, "qs_dyanmic_ime"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3428
const-string v1, "qs_dyanmic_usbtether"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3432
const-string v1, "qs_dyanmic_wifi"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3436
const-string v1, "qs_quick_access"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3440
const-string v1, "qs_quick_access_linked"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3444
const-string v1, "quick_settings_ribbon_tiles"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0, v3}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 3448
const-string v1, "quick_tiles_per_row"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 3452
const-string v1, "quick_tiles_per_row_duplicate_landscape"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v2, p0}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;)V
.line 3456
return-void
.end method[/COLOR]
4. SystemUI.apk/smali/com/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker.smali
remove all lines , and replace with this :
Code:
.class Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;
.super Lcom/android/systemui/statusbar/phone/Ticker;
.source "PhoneStatusBar.java"
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x2
name = "MyTicker"
.end annotation
# instance fields
.field final synthetic this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
# direct methods
.method constructor <init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/content/Context;Landroid/view/View;)V
.locals 0
.parameter
.parameter "context"
.parameter "sb"
.prologue
.line 2473
iput-object p1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
.line 2474
invoke-direct {p0, p2, p3}, Lcom/android/systemui/statusbar/phone/Ticker;-><init>(Landroid/content/Context;Landroid/view/View;)V
.line 2475
return-void
.end method
# virtual methods
.method public tickerDone()V
.locals 6
.prologue
const/4 v5, 0x0
const v4, 0x10a002d
const/4 v1, 0x0
.line 2492
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->setVisibility(I)V
.line 2493
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->setVisibility(I)V
.line 2494
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
invoke-static {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$2900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
move-result-object v0
const/16 v1, 0x8
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
.line 2495
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v4, v5}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2496
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
invoke-static {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$2900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
move-result-object v0
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
const v2, 0x10a002f
iget-object v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v3, v3, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickingDoneListener:Landroid/view/animation/Animation$AnimationListener;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v2, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/view/View;->startAnimation(Landroid/view/animation/Animation;)V
.line 2498
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v4, v5}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2501
return-void
.end method
.method public tickerHalting()V
.locals 4
.prologue
const/4 v1, 0x0
const/4 v3, 0x0
const/high16 v2, 0x10a
.line 2504
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
invoke-virtual {v0}, Landroid/widget/LinearLayout;->getVisibility()I
move-result v0
if-eqz v0, :cond_0
.line 2505
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->setVisibility(I)V
.line 2506
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->setVisibility(I)V
.line 2507
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v2, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2510
:cond_0
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
invoke-static {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$2900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
move-result-object v0
const/16 v1, 0x8
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
.line 2511
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v2, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2512
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v2, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2514
return-void
.end method
.method public tickerStarting()V
.locals 5
.prologue
const v4, 0x10a0032
const/16 v2, 0x8
const/4 v3, 0x0
.line 2479
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
const/4 v1, 0x1
#setter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTicking:Z
invoke-static {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$2802(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Z)Z
.line 2480
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
invoke-virtual {v0, v2}, Landroid/widget/LinearLayout;->setVisibility(I)V
.line 2481
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;
invoke-virtual {v0, v2}, Landroid/widget/LinearLayout;->setVisibility(I)V
.line 2482
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
invoke-static {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$2900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
move-result-object v0
const/4 v1, 0x0
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
.line 2483
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
invoke-static {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$2900(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
move-result-object v0
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
const v2, 0x10a0031
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v2, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/view/View;->startAnimation(Landroid/view/animation/Animation;)V
.line 2484
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v4, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2485
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
iget-object v0, v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;->this$0:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
#calls: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadAnim(ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
invoke-static {v1, v4, v3}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->access$3000(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;ILandroid/view/animation/Animation$AnimationListener;)Landroid/view/animation/Animation;
move-result-object v1
invoke-virtual {v0, v1}, Landroid/widget/LinearLayout;->startAnimation(Landroid/view/animation/Animation;)V
.line 2488
return-void
.end method
Note !!, make sure for access$xxxx got the correct line in PhoneStatusBar.smali
example
Code:
#getter for: Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->[COLOR="Red"]mTickerView:Landroid/view/View;[/COLOR]
invoke-static {v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->[COLOR="Red"]access$2900[/COLOR](Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
will get same in PhoneStatusBar.smali
Code:
.method static synthetic [COLOR="Red"]access$2900[/COLOR](Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)Landroid/view/View;
.locals 1
.parameter "x0"
.prologue
.line 124
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->[COLOR="Red"]mTickerView:Landroid/view/View;[/COLOR]
return-object v0
.end method
5. SystemUI.apk/smali/com/android/systemui/statusbar/phone/PhoneStatusBar.smali
add the red code
remove the blue code
Code:
.field private mCarrierLabelVisible:Z
[COLOR="Red"].field mCenterClockLayout:Landroid/widget/LinearLayout;[/COLOR]
.field private final mCheckBarModes:Ljava/lang/Runnable;
.field mClearButton:Landroid/view/View;
.field mClearButtonAnim:Landroid/animation/Animator;
.field private mClearButtonListener:Landroid/view/View$OnClickListener;
[COLOR="Blue"].field private mClockEnabled:Z[/COLOR]
[COLOR="Red"].field private mClockClickListener:Landroid/view/View$OnClickListener;[/COLOR]
.field private mCollapseAccelPx:F
.field private mCollapseMinDisplayFraction:F
Code:
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$34;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$34;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStartTracing:Ljava/lang/Runnable;
.line 3154
new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$35;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$35;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStopTracing:Ljava/lang/Runnable;
[COLOR="Red"]new-instance v0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$Adi;
invoke-direct {v0, p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$Adi;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;)V
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockClickListener:Landroid/view/View$OnClickListener;[/COLOR]
.line 3289
return-void
.end method
find this method
Code:
.method protected makeStatusBarView()Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
add the red code
and pay attention to the Blue highlight IDs , you must change , match it with your new ids
Code:
const v2, 0x7f070042
invoke-virtual {v0, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/LinearLayout;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarContents:Landroid/widget/LinearLayout;
[COLOR="Red"]iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v2, [COLOR="Blue"]0x7f070084[/COLOR]
invoke-virtual {v0, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v0
check-cast v0, Landroid/widget/LinearLayout;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCenterClockLayout:Landroid/widget/LinearLayout;[/COLOR]
.line 616
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v2, 0x7f07004e
invoke-virtual {v0, v2}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
Code:
const v0, 0x7f0a000b
invoke-virtual {v1, v0}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v0
iput-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHasFlipSettings:Z
.line 635
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationPanelHeader:Landroid/view/View;
const v2, 0x7f070058
invoke-virtual {v0, v2}, Landroid/view/View;->findViewById(I)Landroid/view/View;
move-result-object v0
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateTimeView:Landroid/view/View;
[COLOR="Red"]iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateTimeView:Landroid/view/View;
if-eqz v0, :cond_adi
.line 639
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateTimeView:Landroid/view/View;
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockClickListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v2}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 640
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateTimeView:Landroid/view/View;
invoke-virtual {v0, v6}, Landroid/view/View;->setEnabled(Z)V
:cond_adi[/COLOR]
.line 637
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarWindow:Lcom/android/systemui/statusbar/phone/StatusBarWindowView;
const v2, 0x7f07005d
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;
iput-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/widget/ImageView;
.line 638
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/widget/ImageView;
if-eqz v0, :cond_2
.line 639
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/widget/ImageView;
iget-object v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButtonListener:Landroid/view/View$OnClickListener;
invoke-virtual {v0, v2}, Landroid/widget/ImageView;->setOnClickListener(Landroid/view/View$OnClickListener;)V
.line 640
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mHasSettingsPanel:Z
Remove this lines
Code:
.method public showClock(Z)V
.locals 0
.parameter "show"
.prologue
.line 1395
iput-boolean p1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mShowClock:Z
.line 1396
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateClockVisibility()V
.line 1397
return-void
.end method
replace by this :
Code:
.method public showClock(Z)V
.locals 9
.parameter
.prologue
const/4 v8, -0x2
const/16 v4, 0x8
const/4 v1, 0x1
const/4 v2, 0x0
.line 1401
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
if-nez v0, :cond_1
.line 1417
:cond_0
:goto_0
return-void
.line 1402
:cond_1
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 v3
.line 1403
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v5, [COLOR="Blue"]0x7f07004d[/COLOR]
invoke-virtual {v0, v5}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v5
.line 1404
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v6, [COLOR="Blue"]0x7f070085[/COLOR]
invoke-virtual {v0, v6}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v6
.line 1405
const-string v0, "status_bar_clock"
invoke-static {v3, v0, v1, v8}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
if-ne v0, v1, :cond_4
move v0, v1
.line 1408
:goto_1
const-string v7, "statusbar_clock_style"
invoke-static {v3, v7, v2, v8}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v7
.line 1411
if-nez v7, :cond_2
if-eqz v5, :cond_2
.line 1412
if-eqz p1, :cond_6
if-eqz v0, :cond_5
move v3, v2
:goto_2
invoke-virtual {v5, v3}, Landroid/view/View;->setVisibility(I)V
.line 1414
:cond_2
if-ne v7, v1, :cond_0
if-eqz v6, :cond_0
.line 1415
if-eqz p1, :cond_3
if-eqz v0, :cond_3
move v4, v2
:cond_3
invoke-virtual {v6, v4}, Landroid/view/View;->setVisibility(I)V
goto :goto_0
:cond_4
move v0, v2
.line 1405
goto :goto_1
:cond_5
move v3, v4
.line 1412
goto :goto_2
:cond_6
move v3, v4
goto :goto_2
.end method
6. SystemUI.apk/smali/com/android/systemui/statusbar/phone/PhoneStatusBar.smali
Remove this method, and we don't replace it/we don't need it.
Code:
.method private updateClockVisibility()V
.locals 2
.prologue
.line 1400
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
if-nez v0, :cond_1
.line 1405
:cond_0
:goto_0
return-void
.line 1401
:cond_1
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
const v1, 0x7f07004d
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v1
.line 1402
if-eqz v1, :cond_0
.line 1403
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockEnabled:Z
if-eqz v0, :cond_2
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mShowClock:Z
if-eqz v0, :cond_2
const/4 v0, 0x0
:goto_1
invoke-virtual {v1, v0}, Landroid/view/View;->setVisibility(I)V
goto :goto_0
:cond_2
const/16 v0, 0x8
goto :goto_1
.end method
next :
remove all this lines
Code:
.method private updateSettings()V
.locals 6
.prologue
const/4 v1, 0x1
const/4 v2, 0x0
.line 2878
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 v4
.line 2879
const-string v0, "screen_brightness_mode"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
.line 2882
if-ne v0, v1, :cond_0
.line 2883
iput-boolean v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBrightnessControl:Z
.line 2889
:goto_0
const-string v0, "status_bar_battery"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v3
.line 2891
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_ICON_PORTRAIT:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
.line 2892
packed-switch v3, :pswitch_data_0
.line 2913
:goto_1
:pswitch_0
const-string v3, "status_bar_battery_show_percent"
iget v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v3, v2, v5}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v3
if-ne v3, v1, :cond_2
move v3, v1
.line 2916
:goto_2
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryView:Lcom/android/systemui/BatteryMeterView;
invoke-virtual {v5, v0}, Lcom/android/systemui/BatteryMeterView;->setMode(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2917
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
invoke-virtual {v5, v0}, Lcom/android/systemui/statusbar/policy/BatteryController;->onBatteryMeterModeChanged(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2918
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryView:Lcom/android/systemui/BatteryMeterView;
invoke-virtual {v5, v3}, Lcom/android/systemui/BatteryMeterView;->setShowPercent(Z)V
.line 2919
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
invoke-virtual {v5, v3}, Lcom/android/systemui/statusbar/policy/BatteryController;->onBatteryMeterShowPercent(Z)V
.line 2921
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryView:Lcom/android/systemui/DockBatteryMeterView;
invoke-virtual {v5, v0}, Lcom/android/systemui/DockBatteryMeterView;->setMode(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2922
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryController:Lcom/android/systemui/statusbar/policy/DockBatteryController;
invoke-virtual {v5, v0}, Lcom/android/systemui/statusbar/policy/DockBatteryController;->onBatteryMeterModeChanged(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2923
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryView:Lcom/android/systemui/DockBatteryMeterView;
invoke-virtual {v0, v3}, Lcom/android/systemui/DockBatteryMeterView;->setShowPercent(Z)V
.line 2924
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryController:Lcom/android/systemui/statusbar/policy/DockBatteryController;
invoke-virtual {v0, v3}, Lcom/android/systemui/statusbar/policy/DockBatteryController;->onBatteryMeterShowPercent(Z)V
.line 2926
const-string v0, "status_bar_clock"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v1, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
if-eqz v0, :cond_3
:goto_3
iput-boolean v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockEnabled:Z
.line 2928
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateClockVisibility()V
.line 2930
const-string v0, "status_bar_signal"
iget v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v1}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
.line 2933
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSignalClusterView:Lcom/android/systemui/statusbar/SignalClusterView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/SignalClusterView;->setStyle(I)V
.line 2934
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSignalTextView:Lcom/android/systemui/statusbar/SignalClusterTextView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/SignalClusterTextView;->setStyle(I)V
.line 2935
return-void
.line 2885
:cond_0
const-string v0, "status_bar_brightness_control"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
if-ne v0, v1, :cond_1
move v0, v1
:goto_4
iput-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBrightnessControl:Z
goto :goto_0
:cond_1
move v0, v2
goto :goto_4
.line 2894
:pswitch_1
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_CIRCLE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_1
.line 2898
:pswitch_2
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_GONE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_1
.line 2902
:pswitch_3
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_ICON_LANDSCAPE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_1
.line 2906
:pswitch_4
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_TEXT:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_1
:cond_2
move v3, v2
.line 2913
goto :goto_2
:cond_3
move v1, v2
.line 2926
goto :goto_3
.line 2892
:pswitch_data_0
.packed-switch 0x2
:pswitch_1
:pswitch_0
:pswitch_2
:pswitch_3
:pswitch_4
.end packed-switch
.end method
replace by this :
Code:
.method private updateSettings()V
.locals 5
.prologue
const/4 v1, 0x1
const/4 v2, 0x0
.line 2908
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 v3
.line 2910
const-string v0, "screen_brightness_mode"
invoke-static {v3, v0, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
if-ne v0, v1, :cond_0
move v0, v1
.line 2913
:goto_0
if-nez v0, :cond_1
const-string v0, "status_bar_brightness_control"
invoke-static {v3, v0, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
if-ne v0, v1, :cond_1
move v0, v1
:goto_1
iput-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBrightnessControl:Z
.line 2916
const-string v0, "status_bar_battery"
invoke-static {v3, v0, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v4
.line 2917
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_ICON_PORTRAIT:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
.line 2918
packed-switch v4, :pswitch_data_0
.line 2935
:goto_2
:pswitch_0
const-string v4, "status_bar_battery_show_percent"
invoke-static {v3, v4, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v4
if-ne v4, v1, :cond_2
.line 2938
:goto_3
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryView:Lcom/android/systemui/BatteryMeterView;
invoke-virtual {v4, v0}, Lcom/android/systemui/BatteryMeterView;->setMode(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2939
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
invoke-virtual {v4, v0}, Lcom/android/systemui/statusbar/policy/BatteryController;->onBatteryMeterModeChanged(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2940
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryView:Lcom/android/systemui/BatteryMeterView;
invoke-virtual {v4, v1}, Lcom/android/systemui/BatteryMeterView;->setShowPercent(Z)V
.line 2941
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
invoke-virtual {v4, v1}, Lcom/android/systemui/statusbar/policy/BatteryController;->onBatteryMeterShowPercent(Z)V
.line 2943
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryView:Lcom/android/systemui/DockBatteryMeterView;
invoke-virtual {v4, v0}, Lcom/android/systemui/DockBatteryMeterView;->setMode(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2944
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryController:Lcom/android/systemui/statusbar/policy/DockBatteryController;
invoke-virtual {v4, v0}, Lcom/android/systemui/statusbar/policy/DockBatteryController;->onBatteryMeterModeChanged(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 2945
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryView:Lcom/android/systemui/DockBatteryMeterView;
invoke-virtual {v0, v1}, Lcom/android/systemui/DockBatteryMeterView;->setShowPercent(Z)V
.line 2946
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryController:Lcom/android/systemui/statusbar/policy/DockBatteryController;
invoke-virtual {v0, v1}, Lcom/android/systemui/statusbar/policy/DockBatteryController;->onBatteryMeterShowPercent(Z)V
.line 2948
const-string v0, "status_bar_signal"
invoke-static {v3, v0, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
.line 2950
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSignalClusterView:Lcom/android/systemui/statusbar/SignalClusterView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/SignalClusterView;->setStyle(I)V
.line 2951
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSignalTextView:Lcom/android/systemui/statusbar/SignalClusterTextView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/SignalClusterTextView;->setStyle(I)V
.line 2952
return-void
:cond_0
move v0, v2
.line 2910
goto :goto_0
:cond_1
move v0, v2
.line 2913
goto :goto_1
.line 2920
:pswitch_1
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_CIRCLE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_2
.line 2924
:pswitch_2
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_GONE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_2
.line 2928
:pswitch_3
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_ICON_LANDSCAPE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_2
:pswitch_4
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_TEXT:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_2
:cond_2
move v1, v2
.line 2935
goto :goto_3
.line 2918
nop
:pswitch_data_0
.packed-switch 0x2
:pswitch_1
:pswitch_0
:pswitch_2
:pswitch_3
:pswitch_4
.end packed-switch
.end method
NEW CODE !! sync with latest CM11 source ,17 march 2014
do not delete this method
Code:
.method private updateClockVisibility()V
but change it to like this :
Code:
.method private updateClockVisibility()V
.locals 7
.prologue
const/16 v2, 0x8
const/4 v1, 0x0
.line 1860
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
if-nez v0, :cond_1
.line 1874
:cond_0
:goto_0
return-void
.line 1861
:cond_1
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
.line 1862
iget-object v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
[COLOR="Red"]const v4, 0x7f080035[/COLOR]
invoke-virtual {v3, v4}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v3
.line 1864
iget-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
[COLOR="Red"]const v5, 0x7f080097[/COLOR]
invoke-virtual {v4, v5}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
move-result-object v4
.line 1865
const-string v5, "statusbar_clock_style"
const/4 v6, -0x2
invoke-static {v0, v5, v1, v6}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v5
.line 1868
if-nez v5, :cond_2
if-eqz v3, :cond_2
.line 1869
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockEnabled:Z
if-eqz v0, :cond_3
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mShowClock:Z
if-eqz v0, :cond_3
move v0, v1
:goto_1
invoke-virtual {v3, v0}, Landroid/view/View;->setVisibility(I)V
.line 1871
:cond_2
const/4 v0, 0x1
if-ne v5, v0, :cond_0
if-eqz v4, :cond_0
.line 1872
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockEnabled:Z
if-eqz v0, :cond_4
iget-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mShowClock:Z
if-eqz v0, :cond_4
:goto_2
invoke-virtual {v4, v1}, Landroid/view/View;->setVisibility(I)V
goto :goto_0
:cond_3
move v0, v2
.line 1869
goto :goto_1
:cond_4
move v1, v2
.line 1872
goto :goto_2
.end method
const v4, 0x7f080035 <public type="id" name="clock" id="0x7f??????" />
const v5, 0x7f080097 <public type="id" name="center_clock" id="0x7f??????" />
keep this method stock
Code:
.method private updateSettings()V
.locals 6
.prologue
const/4 v1, 0x1
const/4 v2, 0x0
.line 3029
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 v4
.line 3030
const-string v0, "screen_brightness_mode"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
.line 3033
if-ne v0, v1, :cond_1
.line 3034
iput-boolean v2, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBrightnessControl:Z
.line 3040
:goto_0
const-string v0, "status_bar_battery"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v3
.line 3042
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_ICON_PORTRAIT:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
.line 3043
packed-switch v3, :pswitch_data_0
.line 3064
:goto_1
:pswitch_0
const-string v3, "status_bar_battery_show_percent"
iget v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v3, v2, v5}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v3
if-ne v3, v1, :cond_3
move v3, v1
.line 3067
:goto_2
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryView:Lcom/android/systemui/BatteryMeterView;
invoke-virtual {v5, v0}, Lcom/android/systemui/BatteryMeterView;->setMode(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 3068
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
invoke-virtual {v5, v0}, Lcom/android/systemui/statusbar/policy/BatteryController;->onBatteryMeterModeChanged(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 3069
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryView:Lcom/android/systemui/BatteryMeterView;
invoke-virtual {v5, v3}, Lcom/android/systemui/BatteryMeterView;->setShowPercent(Z)V
.line 3070
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
invoke-virtual {v5, v3}, Lcom/android/systemui/statusbar/policy/BatteryController;->onBatteryMeterShowPercent(Z)V
.line 3072
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryView:Lcom/android/systemui/DockBatteryMeterView;
invoke-virtual {v5, v0}, Lcom/android/systemui/DockBatteryMeterView;->setMode(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 3073
iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryController:Lcom/android/systemui/statusbar/policy/DockBatteryController;
invoke-virtual {v5, v0}, Lcom/android/systemui/statusbar/policy/DockBatteryController;->onBatteryMeterModeChanged(Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;)V
.line 3074
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryView:Lcom/android/systemui/DockBatteryMeterView;
invoke-virtual {v0, v3}, Lcom/android/systemui/DockBatteryMeterView;->setShowPercent(Z)V
.line 3075
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDockBatteryController:Lcom/android/systemui/statusbar/policy/DockBatteryController;
invoke-virtual {v0, v3}, Lcom/android/systemui/statusbar/policy/DockBatteryController;->onBatteryMeterShowPercent(Z)V
.line 3077
iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
if-eqz v0, :cond_0
.line 3078
const-string v0, "navigation_bar_left"
invoke-static {v4, v0, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v0
if-ne v0, v1, :cond_4
move v0, v1
.line 3080
:goto_3
iget-object v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
invoke-virtual {v3, v0}, Lcom/android/systemui/statusbar/phone/NavigationBarView;->setLeftInLandscape(Z)V
.line 3083
:cond_0
const-string v0, "status_bar_clock"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v1, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
if-eqz v0, :cond_5
:goto_4
iput-boolean v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClockEnabled:Z
.line 3085
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateClockVisibility()V
.line 3087
const-string v0, "status_bar_signal"
iget v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v1}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
.line 3090
invoke-static {}, Landroid/telephony/MSimTelephonyManager;->getDefault()Landroid/telephony/MSimTelephonyManager;
move-result-object v1
invoke-virtual {v1}, Landroid/telephony/MSimTelephonyManager;->isMultiSimEnabled()Z
move-result v1
if-eqz v1, :cond_6
.line 3091
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mMSimSignalClusterView:Lcom/android/systemui/statusbar/MSimSignalClusterView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/MSimSignalClusterView;->setStyle(I)V
.line 3096
:goto_5
return-void
.line 3036
:cond_1
const-string v0, "status_bar_brightness_control"
iget v3, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCurrentUserId:I
invoke-static {v4, v0, v2, v3}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v0
if-ne v0, v1, :cond_2
move v0, v1
:goto_6
iput-boolean v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBrightnessControl:Z
goto/16 :goto_0
:cond_2
move v0, v2
goto :goto_6
.line 3045
:pswitch_1
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_CIRCLE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto :goto_1
.line 3049
:pswitch_2
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_GONE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto/16 :goto_1
.line 3053
:pswitch_3
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_ICON_LANDSCAPE:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto/16 :goto_1
.line 3057
:pswitch_4
sget-object v0, Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;->BATTERY_METER_TEXT:Lcom/android/systemui/BatteryMeterView$BatteryMeterMode;
goto/16 :goto_1
:cond_3
move v3, v2
.line 3064
goto/16 :goto_2
:cond_4
move v0, v2
.line 3078
goto :goto_3
:cond_5
move v1, v2
.line 3083
goto :goto_4
.line 3093
:cond_6
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSignalClusterView:Lcom/android/systemui/statusbar/SignalClusterView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/SignalClusterView;->setStyle(I)V
.line 3094
iget-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSignalTextView:Lcom/android/systemui/statusbar/SignalClusterTextView;
invoke-virtual {v1, v0}, Lcom/android/systemui/statusbar/SignalClusterTextView;->setStyle(I)V
goto :goto_5
.line 3043
nop
:pswitch_data_0
.packed-switch 0x2
:pswitch_1
:pswitch_0
:pswitch_2
:pswitch_3
:pswitch_4
.end packed-switch
.end method
and also keep this method stock
Code:
.method public showClock(Z)V
.locals 0
.parameter "show"
.prologue
.line 1505
iput-boolean p1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mShowClock:Z
.line 1506
invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateClockVisibility()V
.line 1507
return-void
.end method
Done and recompile your SystemUI.apk ,
Next continue to STEP-2
STEP-2
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 on_the_fly_CM11_SystemUI.apk_public.xml
so now you have two public.xml which is opened in the Notepad++
1. your secondly decompiled SystemUI.apk public.xml and
2. on_the_fly_CM11_SystemUI.apk_public.xml
- Next go to all smalis you've merged to your SystemUI.apk
find all ids which is started with :
Code:
0x7f[COLOR="Red"]xxxxxx[/COLOR]
and search it in on_the_fly_CM11_SystemUI.apk_public.xml
change, match the ids in the smali with your own new secondly decompiled public.xml
don't forget to do it too, to Blue highlight IDs in PhoneStatusBar.smali
Done and recompile your SystemUI.apk
NAVIGATION BAR
STEP-1
Decompile framework-res.apk
framework-res.apk\res\values
bools.xml
change to "true"
Code:
<bool name="config_showNavigationBar">[COLOR="Red"]true[/COLOR]</bool>
STEP-2
Decompile android.policy.jar
1. com/android/internal/policy/impl/PhoneWindowManager$SettingsObserver.smali
add the blue code
Code:
const-string v1, "key_app_switch_long_press_action"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 661
const-string v1, "hardware_key_rebinding"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
[COLOR="Blue"]const-string v1, "navigation_bar_show"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 711
const-string v1, "navigation_bar_height"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
.line 714
const-string v1, "navigation_bar_width"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v3, p0, v2}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V[/COLOR]
.line 665
iget-object v1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager$SettingsObserver;->this$0:Lcom/android/internal/policy/impl/PhoneWindowManager;
invoke-virtual {v1}, Lcom/android/internal/policy/impl/PhoneWindowManager;->updateSettings()V
.line 666
return-void
.end method
.method public onChange(Z)V
.registers 4
.parameter "selfChange"
2. com/android/internal/policy/impl/PhoneWindowManager.smali
find this method and remove all line in the method
Code:
.method public setInitialDisplaySize(Landroid/view/Display;III)V
-
-
remove all
-
-
.end method
replaced with this
Code:
.method public setInitialDisplaySize(Landroid/view/Display;III)V
.registers 15
.parameter "display"
.parameter "width"
.parameter "height"
.parameter "density"
.prologue
.line 1399
iget-object v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
if-eqz v7, :cond_a
invoke-virtual {p1}, Landroid/view/Display;->getDisplayId()I
move-result v7
if-eqz v7, :cond_b
.line 1476
:cond_a
:goto_a
return-void
.line 1402
:cond_b
iput-object p1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mDisplay:Landroid/view/Display;
.line 1404
iget-object v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v7}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v3
.line 1406
.local v3, res:Landroid/content/res/Resources;
if-le p2, p3, :cond_c2
.line 1407
move v4, p3
.line 1408
.local v4, shortSize:I
move v0, p2
.line 1409
.local v0, longSize:I
const/4 v7, 0x0
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
.line 1410
const/4 v7, 0x2
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSeascapeRotation:I
.line 1411
const v7, 0x1110022
invoke-virtual {v3, v7}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v7
if-eqz v7, :cond_ba
.line 1412
const/4 v7, 0x1
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
.line 1413
const/4 v7, 0x3
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
.line 1432
:goto_2c
const v7, 0x105000c
invoke-virtual {v3, v7}, Landroid/content/res/Resources;->getDimensionPixelSize(I)I
move-result v7
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mStatusBarHeight:I
.line 1436
mul-int/lit16 v7, v4, 0xa0
div-int v5, v7, p4
.line 1437
.local v5, shortSizeDp:I
mul-int/lit16 v7, v0, 0xa0
div-int v1, v7, p4
.line 1440
.local v1, longSizeDp:I
const/16 v7, 0x258
if-ge v5, v7, :cond_e3
const/4 v7, 0x1
:goto_42
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarCanMove:Z
.line 1442
iget-object v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v7}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v7
const v8, 0x111004e
invoke-virtual {v7, v8}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v7
if-eqz v7, :cond_e6
const/4 v6, 0x1
.line 1444
.local v6, showByDefault:I
:goto_54
iget-object v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v7}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v7
const-string v8, "navigation_bar_show"
const/4 v9, -0x2
invoke-static {v7, v8, v6, v9}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v7
const/4 v8, 0x1
if-ne v7, v8, :cond_e9
const/4 v7, 0x1
:goto_65
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasNavigationBar:Z
.line 1450
const-string v7, "qemu.hw.mainkeys"
invoke-static {v7}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v2
.line 1451
.local v2, navBarOverride:Ljava/lang/String;
const-string v7, "1"
invoke-virtual {v7, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v7
if-eqz v7, :cond_ec
.line 1452
const/4 v7, 0x0
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasNavigationBar:Z
.line 1453
const/4 v7, 0x1
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mOverWriteHasNavigationBar:Z
.line 1461
:cond_7b
:goto_7b
const-string v7, "portrait"
const-string v8, "persist.demo.hdmirotation"
invoke-static {v8}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v8
invoke-virtual {v7, v8}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v7
if-eqz v7, :cond_fb
.line 1462
iget v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mDemoHdmiRotation:I
.line 1466
:goto_8d
const-string v7, "persist.demo.hdmirotationlock"
const/4 v8, 0x0
invoke-static {v7, v8}, Landroid/os/SystemProperties;->getBoolean(Ljava/lang/String;Z)Z
move-result v7
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mDemoHdmiRotationLock:Z
.line 1470
const/16 v7, 0x3c0
if-lt v1, v7, :cond_100
const/16 v7, 0x2d0
if-lt v5, v7, :cond_100
const v7, 0x1110061
invoke-virtual {v3, v7}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v7
if-eqz v7, :cond_100
const-string v7, "true"
const-string v8, "config.override_forced_orient"
invoke-static {v8}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;
move-result-object v8
invoke-virtual {v7, v8}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v7
if-nez v7, :cond_100
const/4 v7, 0x1
:goto_b6
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mForceDefaultOrientation:Z
goto/16 :goto_a
.line 1415
.end local v1 #longSizeDp:I
.end local v2 #navBarOverride:Ljava/lang/String;
.end local v5 #shortSizeDp:I
.end local v6 #showByDefault:I
:cond_ba
const/4 v7, 0x3
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
.line 1416
const/4 v7, 0x1
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
goto/16 :goto_2c
.line 1419
.end local v0 #longSize:I
.end local v4 #shortSize:I
:cond_c2
move v4, p2
.line 1420
.restart local v4 #shortSize:I
move v0, p3
.line 1421
.restart local v0 #longSize:I
const/4 v7, 0x0
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
.line 1422
const/4 v7, 0x2
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
.line 1423
const v7, 0x1110022
invoke-virtual {v3, v7}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v7
if-eqz v7, :cond_db
.line 1424
const/4 v7, 0x3
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
.line 1425
const/4 v7, 0x1
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSeascapeRotation:I
goto/16 :goto_2c
.line 1427
:cond_db
const/4 v7, 0x1
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
.line 1428
const/4 v7, 0x3
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSeascapeRotation:I
goto/16 :goto_2c
.line 1440
.restart local v1 #longSizeDp:I
.restart local v5 #shortSizeDp:I
:cond_e3
const/4 v7, 0x0
goto/16 :goto_42
.line 1442
:cond_e6
const/4 v6, 0x0
goto/16 :goto_54
.line 1444
.restart local v6 #showByDefault:I
:cond_e9
const/4 v7, 0x0
goto/16 :goto_65
.line 1454
.restart local v2 #navBarOverride:Ljava/lang/String;
:cond_ec
const-string v7, "0"
invoke-virtual {v7, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v7
if-eqz v7, :cond_7b
.line 1455
const/4 v7, 0x1
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasNavigationBar:Z
.line 1456
const/4 v7, 0x1
iput-boolean v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mOverWriteHasNavigationBar:Z
goto :goto_7b
.line 1464
:cond_fb
iget v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
iput v7, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mDemoHdmiRotation:I
goto :goto_8d
.line 1470
:cond_100
const/4 v7, 0x0
goto :goto_b6
.end method
next find this method
and re move all line in the method
Code:
.method public updateSettings()V
-
-
remove all
-
-
.end method
and replaced with this
Code:
.method public updateSettings()V
.registers 28
.prologue
.line 1502
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v9}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
.line 1503
.local v4, resolver:Landroid/content/ContentResolver;
const/4 v6, 0x0
.line 1504
.local v6, updateRotation:Z
move-object/from16 v0, p0
iget-object v10, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLock:Ljava/lang/Object;
monitor-enter v10
.line 1505
:try_start_e
const-string v9, "end_button_behavior"
const/4 v11, 0x2
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mEndcallBehavior:I
.line 1509
const-string v9, "incall_power_button_behavior"
const/4 v11, 0x1
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$Secure;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mIncallPowerBehavior:I
.line 1513
const-string v9, "ring_home_button_behavior"
const/4 v11, 0x1
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$Secure;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mRingHomeBehavior:I
.line 1517
const-string v9, "home_wake_screen"
const/4 v11, 0x1
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
const/4 v11, 0x1
if-ne v9, v11, :cond_1a5
const/4 v9, 0x1
:goto_3e
move-object/from16 v0, p0
iput-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHomeWakeScreen:Z
.line 1519
const-string v9, "volume_wake_screen"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
const/4 v11, 0x1
if-ne v9, v11, :cond_1a8
const/4 v9, 0x1
:goto_4e
move-object/from16 v0, p0
iput-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeWakeScreen:Z
.line 1521
const-string v9, "volbtn_music_controls"
const/4 v11, 0x1
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
const/4 v11, 0x1
if-ne v9, v11, :cond_1ab
const/4 v9, 0x1
:goto_5e
move-object/from16 v0, p0
iput-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnMusicControls:Z
.line 1524
const-string v9, "expanded_desktop_style"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mExpandedDesktopStyle:I
.line 1526
const-string v9, "expanded_desktop_state"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
if-nez v9, :cond_7d
.line 1528
const/4 v9, 0x0
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mExpandedDesktopStyle:I
.line 1531
:cond_7d
invoke-direct/range {p0 .. p0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->updateKeyAssignments()V
.line 1534
const-string v9, "user_rotation"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v7
.line 1538
.local v7, userRotation:I
move-object/from16 v0, p0
iget v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUserRotation:I
if-eq v9, v7, :cond_93
.line 1539
move-object/from16 v0, p0
iput v7, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUserRotation:I
.line 1540
const/4 v6, 0x1
.line 1542
:cond_93
const-string v9, "accelerometer_rotation"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
if-eqz v9, :cond_1ae
const/4 v8, 0x0
.line 1546
.local v8, userRotationMode:I
:goto_9e
move-object/from16 v0, p0
iget v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUserRotationMode:I
if-eq v9, v8, :cond_ac
.line 1547
move-object/from16 v0, p0
iput v8, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUserRotationMode:I
.line 1548
const/4 v6, 0x1
.line 1549
invoke-virtual/range {p0 .. p0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->updateOrientationListenerLp()V
.line 1552
:cond_ac
const-string v9, "accelerometer_rotation_angles"
const/4 v11, -0x1
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUserRotationAngles:I
.line 1556
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v9}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v9
const v11, 0x111004e
invoke-virtual {v9, v11}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result v9
if-eqz v9, :cond_1b1
const/4 v5, 0x1
.line 1558
.local v5, showByDefault:I
:goto_ca
const-string v9, "navigation_bar_show"
const/4 v11, -0x2
invoke-static {v4, v9, v5, v11}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
const/4 v11, 0x1
if-ne v9, v11, :cond_1b4
const/4 v9, 0x1
:goto_d5
move-object/from16 v0, p0
iput-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasNavigationBar:Z
.line 1562
move-object/from16 v0, p0
iget-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasNavigationBar:Z
if-nez v9, :cond_1b7
.line 1564
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v0, p0
iget v11, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
move-object/from16 v0, p0
iget-object v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v0, p0
iget v13, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
move-object/from16 v0, p0
iget-object v14, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v0, p0
iget v15, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v16, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSeascapeRotation:I
move/from16 v17, v0
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarHeightForRotation:[I
move-object/from16 v18, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
move/from16 v19, v0
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarHeightForRotation:[I
move-object/from16 v20, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
move/from16 v21, v0
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarHeightForRotation:[I
move-object/from16 v22, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
move/from16 v23, v0
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarHeightForRotation:[I
move-object/from16 v24, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSeascapeRotation:I
move/from16 v25, v0
const/16 v26, 0x0
aput v26, v24, v25
aput v26, v22, v23
aput v26, v20, v21
aput v26, v18, v19
aput v26, v16, v17
aput v26, v14, v15
aput v26, v12, v13
aput v26, v9, v11
.line 1598
:goto_145
move-object/from16 v0, p0
iget-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemReady:Z
if-eqz v9, :cond_167
.line 1599
const-string v9, "pointer_location"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v3
.line 1601
.local v3, pointerLocation:I
move-object/from16 v0, p0
iget v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPointerLocationMode:I
if-eq v9, v3, :cond_167
.line 1602
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPointerLocationMode:I
.line 1603
move-object/from16 v0, p0
iget-object v11, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
if-eqz v3, :cond_240
const/4 v9, 0x1
:goto_164
invoke-virtual {v11, v9}, Landroid/os/Handler;->sendEmptyMessage(I)Z
.line 1609
.end local v3 #pointerLocation:I
:cond_167
const-string v9, "screen_off_timeout"
const/4 v11, 0x0
const/4 v12, -0x2
invoke-static {v4, v9, v11, v12}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v9
move-object/from16 v0, p0
iput v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLockScreenTimeout:I
.line 1611
const-string v9, "default_input_method"
const/4 v11, -0x2
invoke-static {v4, v9, v11}, Landroid/provider/Settings$Secure;->getStringForUser(Landroid/content/ContentResolver;Ljava/lang/String;I)Ljava/lang/String;
move-result-object v2
.line 1613
.local v2, imId:Ljava/lang/String;
if-eqz v2, :cond_243
invoke-virtual {v2}, Ljava/lang/String;->length()I
move-result v9
if-lez v9, :cond_243
const/4 v1, 0x1
.line 1614
.local v1, hasSoftInput:Z
:goto_183
move-object/from16 v0, p0
iget-boolean v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasSoftInput:Z
if-eq v9, v1, :cond_18e
.line 1615
move-object/from16 v0, p0
iput-boolean v1, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHasSoftInput:Z
.line 1616
const/4 v6, 0x1
.line 1618
:cond_18e
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mImmersiveModeConfirmation:Lcom/android/internal/policy/impl/ImmersiveModeConfirmation;
if-eqz v9, :cond_19b
.line 1619
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mImmersiveModeConfirmation:Lcom/android/internal/policy/impl/ImmersiveModeConfirmation;
invoke-virtual {v9}, Lcom/android/internal/policy/impl/ImmersiveModeConfirmation;->loadSetting()V
.line 1621
:cond_19b
monitor-exit v10
:try_end_19c
.catchall {:try_start_e .. :try_end_19c} :catchall_23d
.line 1623
if-eqz v6, :cond_1a4
.line 1624
const/4 v9, 0x1
move-object/from16 v0, p0
invoke-virtual {v0, v9}, Lcom/android/internal/policy/impl/PhoneWindowManager;->updateRotation(Z)V
.line 1626
:cond_1a4
return-void
.line 1517
.end local v1 #hasSoftInput:Z
.end local v2 #imId:Ljava/lang/String;
.end local v5 #showByDefault:I
.end local v7 #userRotation:I
.end local v8 #userRotationMode:I
:cond_1a5
const/4 v9, 0x0
goto/16 :goto_3e
.line 1519
:cond_1a8
const/4 v9, 0x0
goto/16 :goto_4e
.line 1521
:cond_1ab
const/4 v9, 0x0
goto/16 :goto_5e
.line 1542
.restart local v7 #userRotation:I
:cond_1ae
const/4 v8, 0x1
goto/16 :goto_9e
.line 1556
.restart local v8 #userRotationMode:I
:cond_1b1
const/4 v5, 0x0
goto/16 :goto_ca
.line 1558
.restart local v5 #showByDefault:I
:cond_1b4
const/4 v9, 0x0
goto/16 :goto_d5
.line 1574
:cond_1b7
:try_start_1b7
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarHeightForRotation:[I
move-object/from16 v0, p0
iget v11, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
move-object/from16 v0, p0
iget-object v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarHeightForRotation:[I
move-object/from16 v0, p0
iget v13, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
move-object/from16 v0, p0
iget-object v14, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v14}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v14
const-string v15, "navigation_bar_height"
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
move-object/from16 v16, v0
invoke-virtual/range {v16 .. v16}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v16
const v17, 0x105000d
invoke-virtual/range {v16 .. v17}, Landroid/content/res/Resources;->getDimensionPixelSize(I)I
move-result v16
const/16 v17, -0x2
invoke-static/range {v14 .. v17}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v14
aput v14, v12, v13
aput v14, v9, v11
.line 1585
move-object/from16 v0, p0
iget-object v9, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v0, p0
iget v11, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mPortraitRotation:I
move-object/from16 v0, p0
iget-object v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v0, p0
iget v13, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mUpsideDownRotation:I
move-object/from16 v0, p0
iget-object v14, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v0, p0
iget v15, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLandscapeRotation:I
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mNavigationBarWidthForRotation:[I
move-object/from16 v16, v0
move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSeascapeRotation:I
move/from16 v17, v0
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
move-object/from16 v18, v0
invoke-virtual/range {v18 .. v18}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v18
const-string v19, "navigation_bar_width"
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
move-object/from16 v20, v0
invoke-virtual/range {v20 .. v20}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object v20
const v21, 0x105000f
invoke-virtual/range {v20 .. v21}, Landroid/content/res/Resources;->getDimensionPixelSize(I)I
move-result v20
const/16 v21, -0x2
invoke-static/range {v18 .. v21}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v18
aput v18, v16, v17
aput v18, v14, v15
aput v18, v12, v13
aput v18, v9, v11
goto/16 :goto_145
.line 1621
.end local v5 #showByDefault:I
.end local v7 #userRotation:I
.end local v8 #userRotationMode:I
:catchall_23d
move-exception v9
monitor-exit v10
:try_end_23f
.catchall {:try_start_1b7 .. :try_end_23f} :catchall_23d
throw v9
.line 1603
.restart local v3 #pointerLocation:I
.restart local v5 #showByDefault:I
.restart local v7 #userRotation:I
.restart local v8 #userRotationMode:I
:cond_240
const/4 v9, 0x2
goto/16 :goto_164
.line 1613
.end local v3 #pointerLocation:I
.restart local v2 #imId:Ljava/lang/String;
:cond_243
const/4 v1, 0x0
goto/16 :goto_183
.end method
Done , Enjoy !
proof & screenshot http://forum.xda-developers.com/showthread.php?t=2557122
Credit & Thanks :
- Recognized developer Arco
- Recognized developer Educk
- Paranoid Android
- Cristiano Matos
- crDroid team
- CyanogenMod team
- AOKP team
- Carbon rom team
- Chameleon OS team
- Slimbean team
pertamax save :laugh:
nice guide :fingers-crossed:
eddy_nugroz said:
pertamax save :laugh:
nice guide :fingers-crossed:
Click to expand...
Click to collapse
ok, ok, ok .. hahaha :good::laugh:
Updated
I added wrong smali for PhoneStatusBar$MyTicker.smali
so there is new code for that smali
thanks
Will this guide work on JB 4.2/CM10.1?
sir @Adi Aisiteru Reborn, will this guide work on JB 4.2/CM10.1? I mean only to enable the navigation bar button? i have follow a guide from another thread to show the navigation bar but it's not work on mine. Since i have edit the framework-res.apk bool.xml, the navigation bar doesn't showed.
Btw, you're Rock Sir...keep it up with other nicely guide
blu3m4n said:
sir @Adi Aisiteru Reborn, will this guide work on JB 4.2/CM10.1? I mean only to enable the navigation bar button? i have follow a guide from another thread to show the navigation bar but it's not work on mine. Since i have edit the framework-res.apk bool.xml, the navigation bar doesn't showed.
Btw, you're Rock Sir...keep it up with other nicely guide
Click to expand...
Click to collapse
I think you can try to start it from here, http://forum.xda-developers.com/showthread.php?t=2499075
Compare my CM10.1 mod with your stock file.
Remember per OP said that this thread is for CM11, don't take any risk
Sent from my GT-I8150 using xda app-developers app
Yeah, success with this guide
Big thanks sir
nice guide
work at GT-I9082, tanks
error
i get errors recompiling. which tool should i use? what do you mean by going to the smalis and doing the oxf stuff?
GHE_1908 said:
i get errors recompiling. which tool should i use? what do you mean by going to the smalis and doing the oxf stuff?
Click to expand...
Click to collapse
and what tool u usually use for compile/decompile CM11 ?,
I have enough giving information in the guide.
search all ids number which is started with 0x7fxxxxxx in all smalis I gave, and find that in my public xml what is for.
can be layout of what, strings of what, id of what, xml of what, drawable of what, etc..
next if you find it already then search it in your own public.xml, and change the number in the smali according to your own public.xml
Adi Aisiteru Reborn said:
and what tool u usually use for compile/decompile CM11 ?,
I have enough giving information in the guide.
search all ids number which is started with 0x7fxxxxxx in all smalis I gave, and find that in my public xml what is for.
can be layout of what, strings of what, id of what, xml of what, drawable of what, etc..
next if you find it already then search it in your own public.xml, and change the number in the smali according to your own public.xml
Click to expand...
Click to collapse
apktool beta by ibanez7 for kitkat
GHE_1908 said:
apktool beta by ibanez7 for kitkat
Click to expand...
Click to collapse
don't care what tool u ussualy use, so what is the error ?.
have u tried decompile and recompile apk back without change anythng yet ?
[Guide How-to] KitKat 4.4.2/Android L Music Control - Volume Music Skip
UPDATED FOR ANDROID L
This guide requires knowledge of decompiling and compiling apk and smali files.
It is only a guide.
I do not take requests. If you want this mod for your rom, get with a dev with the knowledge to get it done.
I have attached android.policy files for diffing in case you get stuck on a section.
SecSettings.apk
In SecSettings.apk we setup the Music Control menu items & toggles.
(This edit does not work on Android L)
*** Add the two new files from the SecSettings_new_files.zip attached at the bottom of this post.
res/values/strings.xml edit:
Add new lines
Code:
<string name="volbtn_toggle_title">Music Control</string>
<string name="volbtn_timeout_title">Button Delay</string>
<string name="volbtn_timeout_summary">%s</string>
<string name="volbtn_vol_up_title">Volume Up Action</string>
<string name="volbtn_vol_up_summary">%s</string>
<string name="volbtn_vol_down_title">Volume Down Action</string>
<string name="volbtn_vol_down_summary">%s</string>
res/values/arrays.xml edit:
Add new lines
Code:
<string-array name="volbtn_action_entries">
<item>Next</item>
<item>Pause</item>
<item>Play</item>
<item>Play/Pause</item>
<item>Previous</item>
<item>Stop</item>
</string-array>
<string-array name="volbtn_action_values">
<item>87</item>
<item>127</item>
<item>126</item>
<item>85</item>
<item>88</item>
<item>86</item>
</string-array>
<string-array name="volbtn_timeout_entries">
<item>100ms</item>
<item>150ms</item>
<item>200ms</item>
<item>250ms</item>
<item>300ms</item>
<item>350ms</item>
<item>400ms</item>
<item>450ms</item>
<item>500ms</item>
</string-array>
<string-array name="volbtn_timeout_values">
<item>100</item>
<item>150</item>
<item>200</item>
<item>250</item>
<item>300</item>
<item>350</item>
<item>400</item>
<item>450</item>
<item>500</item>
</string-array>
res/xml/sound_settings.xml edit:
Add new line where you want the menu item to appear in the Sound settings menu.
Code:
<SwitchPreferenceScreen android:title="@string/volbtn_toggle_title" android:key="volbtn_music_controls" android:fragment="com.android.settings.VolBtnSettings" />
Smali Edit:
smali/com/android/settings/SoundSettings.smali
Add new line in BLUE
Code:
.field private mVibrateWhenRinging:Landroid/preference/CheckBoxPreference;
[COLOR="Blue"].field private mVolBtnMusicCtrl:Landroid/preference/SwitchPreferenceScreen;
[/COLOR]
.field private mVolume:Lcom/android/settings/RingerVolumePreference;
Increase locals value by 1 indicated in GREEN
Note:
When the change to .locals is increased by one, both of the V7 values in the new lines should be one LESS than the .locals value.
(New .locals value in our example is 8. 8-1=7, so we use V7)
Add new lines indicated in BLUE
Code:
.method private updateState(Z)V
[COLOR="Green"].locals 8
[/COLOR]
const/4 v2, 0x1
const/4 v4, 0x0
invoke-virtual {p0}, Landroid/app/Fragment;->getActivity()Landroid/app/Activity;
move-result-object v0
if-nez v0, :cond_1
:cond_0
:goto_0
return-void
:cond_1
iget-object v0, p0, Lcom/android/settings/SoundSettings;->mAudioManager:Landroid/media/AudioManager;
invoke-virtual {v0}, Landroid/media/AudioManager;->getRingerMode()I
move-result v6
[COLOR="Blue"] iget-object v1, p0, Lcom/android/settings/SoundSettings;->mVolBtnMusicCtrl:Landroid/preference/SwitchPreferenceScreen;
if-eqz v1, :cond_td
iget-object v3, p0, Lcom/android/settings/SoundSettings;->mVolBtnMusicCtrl:Landroid/preference/SwitchPreferenceScreen;
invoke-virtual {p0}, Lcom/android/settings/SoundSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v1
const-string v7, "volbtn_music_controls"
invoke-static {v1, v7, v4}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v1
if-eqz v1, :cond_vol
move v1, v2
:goto_vol
invoke-virtual {v3, v1}, Landroid/preference/SwitchPreferenceScreen;->setChecked(Z)V
:cond_td
[/COLOR] const-string v0, "CTC"
New lines at the end of the same method.
Add lines indicated in BLUE
Code:
.method private updateState(Z)V
.
.
.
goto/16 :goto_1
[COLOR="Blue"] :cond_vol
move v1, v4
goto/16 :goto_vol
[/COLOR].end method
Search for the string "phone_vibration" in SoundSettings.smali and add the new lines indicated in BLUE right above it.
Code:
[COLOR="Blue"]const-string v32, "volbtn_music_controls"
move-object/from16 v0, p0
move-object/from16 v1, v32
invoke-virtual {v0, v1}, Lcom/android/settings/SoundSettings;->findPreference(Ljava/lang/CharSequence;)Landroid/preference/Preference;
move-result-object v32
check-cast v32, Landroid/preference/SwitchPreferenceScreen;
move-object/from16 v0, v32
move-object/from16 v1, p0
iput-object v0, v1, Lcom/android/settings/SoundSettings;->mVolBtnMusicCtrl:Landroid/preference/SwitchPreferenceScreen;
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/settings/SoundSettings;->mVolBtnMusicCtrl:Landroid/preference/SwitchPreferenceScreen;
move-object/from16 v32, v0
move-object/from16 v0, v32
move-object/from16 v1, p0
invoke-virtual {v0, v1}, Landroid/preference/Preference;->setOnPreferenceChangeListener(Landroid/preference/Preference$OnPreferenceChangeListener;)V
[/COLOR]
const-string v32, "phone_vibration"
Add new lines indicated in BLUE
Make sure values v2, v3 & v4 values match surrounding code.
Code:
.method public onPreferenceChange(Landroid/preference/Preference;Ljava/lang/Object;)Z
.locals 6
const/4 v0, 0x0
const/4 v1, 0x1
invoke-virtual {p1}, Landroid/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v2
const-string v3, "SoundSettings"
new-instance v4, Ljava/lang/StringBuilder;
invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V
const-string v5, "onPreferenceChange : "
invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v4
invoke-virtual {v4, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
move-result-object v4
invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v4
invoke-static {v3, v4}, Landroid/util/secutil/Log;->secV(Ljava/lang/String;Ljava/lang/String;)I
[COLOR="Blue"]const-string v3, "volbtn_music_controls"
invoke-virtual {v3, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-eqz v3, :cond_td3
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result v3
if-eqz v3, :cond_td4
const/4 v0, 0x1
:goto_td5
invoke-virtual {p0}, Lcom/android/settings/SoundSettings;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v4
const-string v3, "volbtn_music_controls"
invoke-static {v4, v3, v0}, Landroid/provider/Settings$System;->putInt(Landroid/content/ContentResolver;Ljava/lang/String;I)Z
goto :goto_0
:cond_td4
const/4 v0, 0x0
goto :goto_td5
:cond_td3[/COLOR]
const-string v3, "emergency_tone"
We need to change three public value so compile the changed SecSettings.apk, then decompile it. Open res/values/public.xml and search for the string these strings and write down the public values:
"action_bar_switch_padding"
"volbtn_toggle_title"
"volbtn_settings"
Now in the original SecSettings, open the smali file we added
smali/com/android/settings/VolBtnSettings.smali, search for each of the strings and change your public value to match as indicated in BLUE.
Code:
const v4, 0x[COLOR="Blue"]7f0f0045[/COLOR] # type="dimen" name="action_bar_switch_padding"
const v4, 0x[COLOR="Blue"]7f091a29[/COLOR] # type="string" name="volbtn_toggle_title"
const v0, 0x[COLOR="Blue"]7f0700fe[/COLOR] # type="xml" name="volbtn_settings"
That should be it for SecSettings.apk. Compile after making these last value changes and make sure the Music Control menu functions before continuing with android.policy.jar.
android.policy.jar
(also see additional changes for Android L linked at the bottom of this post)
*** Add the two new files from the android.policy.new_files.zip attached at the bottom of this post.
Smali Edits
smali/com/android/internal/policy/impl/PhoneWindowManager.smali
Add new line in BLUE
Code:
.field private mKeyEventInjectionThread:Ljava/lang/Thread;
[COLOR="Blue"].field mIsVolLongPressed:Z
[/COLOR]
.field mKeyboardTapVibePattern:[J
Add new lines in BLUE
Code:
.field mVirtualKeyVibePattern:[J
[COLOR="Blue"].field mVolBtnMusicControls:I
.field mVolBtnTimeout:I
.field mVolBtnVolDown:I
.field mVolBtnVolUp:I
[/COLOR].field private mVolumeDownKeyConsumedByScreenshotChord:Z
.field private mVolumeDownKeyTime:J
.field private mVolumeDownKeyTriggered:Z
[COLOR="Blue"].field final mVolumeDownLongPress:Ljava/lang/Runnable;
[/COLOR]
.field private mVolumeUpKeyConsumedByScreenshotChord:Z
.field private mVolumeUpKeyTime:J
.field private mVolumeUpKeyTriggered:Z
[COLOR="Blue"].field final mVolumeUpLongPress:Ljava/lang/Runnable;
[/COLOR]
.field mWifiDisplayConnected:Z
Add new lines in BLUE near end of method BEFORE the return-void.
Code:
.method public constructor <init>()V
.
.
.
[COLOR="Blue"] new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$MusicNext;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$MusicNext;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeUpLongPress:Ljava/lang/Runnable;
new-instance v0, Lcom/android/internal/policy/impl/PhoneWindowManager$MusicPrev;
invoke-direct {v0, p0}, Lcom/android/internal/policy/impl/PhoneWindowManager$MusicPrev;-><init>(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
iput-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeDownLongPress:Ljava/lang/Runnable;
[/COLOR]
return-void
.end method
.method static synthetic access$000(Lcom/android/internal/policy/impl/PhoneWindowManager;)V
Add new methods ABOVE
.method public hasNavigationBar()Z
Code:
.method handleVolumeLongPress(I)V
.locals 4
const/16 v1, 0x18
if-ne p1, v1, :cond_0
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeUpLongPress:Ljava/lang/Runnable;
:goto_0
iget-object v1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
iget v2, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnTimeout:I
int-to-long v2, v2
invoke-virtual {v1, v0, v2, v3}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z
return-void
:cond_0
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeDownLongPress:Ljava/lang/Runnable;
goto :goto_0
.end method
.method handleVolumeLongPressAbort()V
.locals 2
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
iget-object v1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeUpLongPress:Ljava/lang/Runnable;
invoke-virtual {v0, v1}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mHandler:Landroid/os/Handler;
iget-object v1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolumeDownLongPress:Ljava/lang/Runnable;
invoke-virtual {v0, v1}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V
return-void
.end method
The next section may be a little difficult to find.
Search for the string: "interceptKeyBeforeQueueing: VOLUME key-down while ringing: Silence ringer!", scroll up a few lines and place the new lines indicated in BLUE, right below the :sswitch_1 statement.
Important Note:
(AFTER adding the new section below, come back here)
The v12 value may need to be changed to match surrounding code. The next occurrence in our code is this statement:
Code:
invoke-virtual {v0, v12, v6, v5}, Lcom/android/internal/policy/impl/sec/SamsungPhoneWindowManager;->handleSamsungVolumeControl(IZZ)V
Search for the next occurrence of handleSamsungVolumeControl(IZZ)V and if your second values of v12 & v6 match, then you are good to go. If it is NOT, then the v12 & v6 in the new code below needs to be changed to match that value.
Code:
:sswitch_1
[COLOR="Blue"] move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnMusicControls:I
if-eqz v0, :cond_td
invoke-virtual/range {p0 .. p0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->isMusicActive()Z
move-result v0
if-eqz v0, :cond_td
move-object/from16 v0, p0
iget-boolean v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mScreenOnEarly:Z
if-nez v0, :cond_td
if-eqz v6, :cond_td2
move-object/from16 v0, p0
move/from16 v1, v12
invoke-virtual {v0, v1}, Lcom/android/internal/policy/impl/PhoneWindowManager;->handleVolumeLongPress(I)V
const/4 v15, 0x0
goto/16 :goto_0
:cond_td2
move-object/from16 v0, p0
invoke-virtual {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->handleVolumeLongPressAbort()V
iget-boolean v1, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mIsVolLongPressed:Z
if-nez v1, :cond_td3
move/from16 v1, v12
const/4 v3, 0x3
invoke-virtual {v0, v3, v1}, Lcom/android/internal/policy/impl/PhoneWindowManager;->handleVolumeKey(II)V
:cond_td3
const/4 v1, 0x0
iput-boolean v1, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mIsVolLongPressed:Z
:cond_td
[/COLOR]
if-eqz v6, :cond_19
invoke-static {}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getTelephonyService()Lcom/android/internal/telephony/ITelephony;
move-result-object v17
if-eqz v17, :cond_19
:try_start_0
invoke-interface/range {v17 .. v17}, Lcom/android/internal/telephony/ITelephony;->isRinging()Z
move-result v21
if-eqz v21, :cond_19
const-string v21, "WindowManager"
const-string v22, "interceptKeyBeforeQueueing: VOLUME key-down while ringing: Silence ringer!"
invoke-static/range {v21 .. v22}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I
invoke-interface/range {v17 .. v17}, Lcom/android/internal/telephony/ITelephony;->silenceRinger()V
:try_end_0
.catch Landroid/os/RemoteException; {:try_start_0 .. :try_end_0} :catch_0
and-int/lit8 v15, v15, -0x2
Android L version of previous section:
New code is BLUE, make sure the code in GREEN match original
Code:
:sswitch_0
[COLOR="Blue"] move-object/from16 v0, p0
iget v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnMusicControls:I
if-eqz v0, :cond_td
invoke-virtual/range {p0 .. p0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->isMusicActive()Z
move-result v0
if-eqz v0, :cond_td
move-object/from16 v0, p0
iget-boolean v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mScreenOnEarly:Z
if-nez v0, :cond_td
if-eqz v5, :cond_td2
move-object/from16 v0, p0
move/from16 v1, v11
invoke-virtual {v0, v1}, Lcom/android/internal/policy/impl/PhoneWindowManager;->handleVolumeLongPress(I)V
const/16 v16, 0x0
goto/16[/COLOR] [COLOR="Green"]:goto_8[/COLOR]
[COLOR="Blue"]:cond_td2
move-object/from16 v0, p0
invoke-virtual {v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->handleVolumeLongPressAbort()V
iget-boolean v1, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mIsVolLongPressed:Z
if-nez v1, :cond_td3
move/from16 v1, v11
const/4 v3, 0x3
invoke-virtual {v0, v3, v1}, Lcom/android/internal/policy/impl/PhoneWindowManager;->handleVolumeKey(II)V
:cond_td3
const/4 v1, 0x0
iput-boolean v1, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mIsVolLongPressed:Z
:cond_td[/COLOR]
invoke-virtual/range {p0 .. p0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->getTelecommService()Landroid/telecom/TelecomManager;
move-result-object v17
if-eqz v17, :cond_19
if-eqz v5, :cond_18
invoke-virtual/range {v17 .. v17}, Landroid/telecom/TelecomManager;->isRinging()Z
move-result v21
if-eqz v21, :cond_18
const-string v21, "WindowManager"
const-string v22, "interceptKeyBeforeQueueing: VOLUME key-down while ringing: Silence ringer!"
invoke-static/range {v21 .. v22}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I
invoke-virtual/range {v17 .. v17}, Landroid/telecom/TelecomManager;->silenceRinger()V
and-int/lit8 v16, v16, -0x2
goto/16 [COLOR="Green"]:goto_8[/COLOR]
Add new method indicated in BLUE:
Code:
.method public isMetaKeyEventRequested(Landroid/content/ComponentName;)Z
.locals 1
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemKeyManager:Lcom/android/internal/policy/impl/sec/SystemKeyManager;
invoke-virtual {v0, p1}, Lcom/android/internal/policy/impl/sec/SystemKeyManager;->isMetaKeyEventRequested(Landroid/content/ComponentName;)Z
move-result v0
return v0
.end method
[COLOR="Blue"].method isMusicActive()Z
.locals 3
iget-object v1, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
const-string v2, "audio"
invoke-virtual {v1, v2}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/media/AudioManager;
if-nez v0, :cond_0
const-string v1, "WindowManager"
const-string v2, "isMusicActive: couldn\'t get AudioManager reference"
invoke-static {v1, v2}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;)I
const/4 v1, 0x0
:goto_0
return v1
:cond_0
invoke-virtual {v0}, Landroid/media/AudioManager;->isLocalOrRemoteMusicActive()Z
move-result v1
goto :goto_0
.end method[/COLOR]
Add new method indicated in BLUE:
Code:
.method sendCloseSystemWindows(Ljava/lang/String;)V
.locals 1
iget-object v0, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-static {v0, p1}, Lcom/android/internal/policy/impl/PhoneWindowManager;->sendCloseSystemWindows(Landroid/content/Context;Ljava/lang/String;)V
return-void
.end method
[COLOR="Blue"].method protected sendMediaButtonEvent(I)V
.locals 13
invoke-static {}, Landroid/os/SystemClock;->uptimeMillis()J
move-result-wide v1
new-instance v11, Landroid/content/Intent;
const-string v4, "android.intent.action.MEDIA_BUTTON"
const/4 v5, 0x0
invoke-direct {v11, v4, v5}, Landroid/content/Intent;-><init>(Ljava/lang/String;Landroid/net/Uri;)V
new-instance v0, Landroid/view/KeyEvent;
const/4 v5, 0x0
const/4 v7, 0x0
move-wide v3, v1
move v6, p1
invoke-direct/range {v0 .. v7}, Landroid/view/KeyEvent;-><init>(JJIII)V
invoke-virtual {p0, v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->dispatchMediaKeyWithWakeLockToAudioService(Landroid/view/KeyEvent;)V
const/16 v2, 0x1
invoke-static {v0, v2}, Landroid/view/KeyEvent;->changeAction(Landroid/view/KeyEvent;I)Landroid/view/KeyEvent;
move-result-object v0
invoke-virtual {p0, v0}, Lcom/android/internal/policy/impl/PhoneWindowManager;->dispatchMediaKeyWithWakeLockToAudioService(Landroid/view/KeyEvent;)V
return-void
const-string v4, "android.intent.extra.KEY_EVENT"
invoke-virtual {v11, v4, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Landroid/os/Parcelable;)Landroid/content/Intent;
iget-object v4, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
const/4 v5, 0x0
invoke-virtual {v4, v11, v5}, Landroid/content/Context;->sendOrderedBroadcast(Landroid/content/Intent;Ljava/lang/String;)V
new-instance v12, Landroid/content/Intent;
const-string v4, "android.intent.action.MEDIA_BUTTON"
const/4 v5, 0x0
invoke-direct {v12, v4, v5}, Landroid/content/Intent;-><init>(Ljava/lang/String;Landroid/net/Uri;)V
new-instance v3, Landroid/view/KeyEvent;
const/4 v8, 0x1
const/4 v10, 0x0
move-wide v4, v1
move-wide v6, v1
move v9, p1
invoke-direct/range {v3 .. v10}, Landroid/view/KeyEvent;-><init>(JJIII)V
const-string v4, "android.intent.extra.KEY_EVENT"
invoke-virtual {v12, v4, v3}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Landroid/os/Parcelable;)Landroid/content/Intent;
iget-object v4, p0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
const/4 v5, 0x0
invoke-virtual {v4, v12, v5}, Landroid/content/Context;->sendOrderedBroadcast(Landroid/content/Intent;Ljava/lang/String;)V
return-void
.end method[/COLOR]
Add new lines indicated in BLUE
NOTE:
Make note of the value of the line in GREEN.
If your value is different, the 4 occurrences of v13 in our new code must also be changed to match.
Example:
If your line before the new code is:
move-result-object v8
You would change the 4 values of v13 to v8.
Code:
.method public updateSettings()V
.locals 23
move-object/from16 v0, p0
iget-object v0, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
move-object/from16 v18, v0
invoke-virtual/range {v18 .. v18}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
[COLOR="Green"]move-result-object v13
[/COLOR]
[COLOR="Blue"]const-string v7, "volbtn_music_controls"
const/4 v9, 0x0
invoke-static {v13, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnMusicControls:I
const-string v7, "volbtn_timeout"
const/16 v9, 0x190
invoke-static {v13, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnTimeout:I
const-string v7, "volbtn_vol_up"
const/16 v9, 0x57
invoke-static {v13, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnVolUp:I
const-string v7, "volbtn_vol_down"
const/16 v9, 0x58
invoke-static {v13, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnVolDown:I[/COLOR]
Android L Version of previous section:
New code is in BLUE
Code:
.method public updateSettings()V
.locals 19
move-object/from16 v0, p0
iget-object v15, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v15}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v9
[COLOR="Blue"]const-string v7, "volbtn_music_controls"
const/4 v10, 0x0
invoke-static {v9, v7, v10}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnMusicControls:I
const-string v7, "volbtn_timeout"
const/16 v10, 0x190
invoke-static {v9, v7, v10}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnTimeout:I
const-string v7, "volbtn_vol_up"
const/16 v10, 0x57
invoke-static {v9, v7, v10}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnVolUp:I
const-string v7, "volbtn_vol_down"
const/16 v10, 0x58
invoke-static {v9, v7, v10}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnVolDown:I[/COLOR]
Smali edit
\com\android\internal\policy\impl\PhoneWindowManager$SettingsObserver.smali
Search for string "immersive_mode_confirmations" and add new section in BLUE right above that line.
Make sure the values above in GREEN match the new code.
Code:
const-string v1, "default_input_method"
invoke-static {v1}, Landroid/provider/Settings$Secure;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {[COLOR="Green"]v0, v1, v4, p0, v5[/COLOR]}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
[COLOR="Blue"] const-string v1, "volbtn_music_controls"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v4, p0, v5}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
const-string v1, "volbtn_timeout"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v4, p0, v5}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
const-string v1, "volbtn_vol_up"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v4, p0, v5}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
const-string v1, "volbtn_vol_down"
invoke-static {v1}, Landroid/provider/Settings$System;->getUriFor(Ljava/lang/String;)Landroid/net/Uri;
move-result-object v1
invoke-virtual {v0, v1, v4, p0, v5}, Landroid/content/ContentResolver;->registerContentObserver(Landroid/net/Uri;ZLandroid/database/ContentObserver;I)V
[/COLOR]
const-string v1, "immersive_mode_confirmations"
Android L UPDATE:
Additional Android L Changes
Additional changes for Android L are here --->> Android L amended guide
Credits: @loserskater for the orginal mod HERE ; @jeboo for his GitHub HERE @sac23 for the tremendous help getting framework.jar changes
tdunham said:
[Guide How-to] KitKat 4.4.2 Music Control - Volume Music Skip and More
This guide requires knowledge of decompiling and compiling apk and smali files.
It is only a guide.
I do not take requests. If you want this mod for your rom, get with a dev with the knowledge to get it done.
I have attached android.policy files for diffing in case you get stuck on a section.
Click to expand...
Click to collapse
Thank you, thank. You are a god...
Sent from my SM-T320 using Xparent BlueTapatalk 2
Gotta agree with the above post... You are awesome dude...
Are you about to ask a question? Hold up. Before you do that, did you check HERE? or HERE? :good:
FOR ANY ND8 RELATED QUESTIONS PLEASE VISIT THIS THREAD ----> TouchWiz 4.4 KitKat ND8 myth busters
My KITKAT 4.4.2 Touchwiz, Blue PCB Theme
TOUCHWIZ KITKAT ANIMATED PULLDOWN BAR AND ANIMATED PULLDOWN BACKGROUND MOD
Another awesome guide TD! Thank you for sharing your knowledge with the community!
Sent from my SM-G900P using Tapatalk
@tdunham, you point to the VolBtnSettings in the settings.apk, but you didn't attach the files. Just giving you a heads up. Glad to see my work lives on! Thanks for updating this :good:
loserskater said:
@tdunham, you point to the VolBtnSettings in the settings.apk, but you didn't attach the files. Just giving you a heads up. Glad to see my work lives on! Thanks for updating this :good:
Click to expand...
Click to collapse
Thanks. I'm glad someone's looking out for me.
Thanks a ton for sharing your knowledge. You're a real class act man!
Appreciate you sharing the knowledge, thank you sir.
Delete
tdunham said:
Thanks. I'm glad someone's looking out for me.
Click to expand...
Click to collapse
Hey @tdunham...this is the first time for me using <SwitchPreferenceScreen in any mod...there shouldn't be a problem with me adding an icon to line should there?
<SwitchPreferenceScreen android:icon="@drawable/xxxxxxxx" android:title="@string/volbtn_toggle_title" android:key="volbtn_music_controls" android:fragment="com.android.settings.VolBtnSettings" />
Edit: I'll post pics when I'm done
deuce_biggins said:
Hey @tdunham...this is the first time for me using <SwitchPreferenceScreen in any mod...there shouldn't be a problem with me adding an icon to line should there?
<SwitchPreferenceScreen android:icon="@drawable/xxxxxxxx android:title="@string/volbtn_toggle_title" android:key="volbtn_music_controls" android:fragment="com.android.settings.VolBtnSettings" />
Click to expand...
Click to collapse
I don't see why not.
The good thing about SecSettings is that modifying it won't cause a bootloop, just a force close when you try to access the part of it that isn't coded properly.
However, why set an icon? This is a submenu of sounds and not a single item has an icon, stock Touchwiz of course. I just checked on my Galaxy SIII KitKat and the same goes there.
My SS is attached (without this menu item, we use CustomSettings.apk for toggles, colorizers & scripts).
Anyone get the android.policy edits right on the Sprint Note 3?
If someone with the know-how could take a look at my PhoneWindowsManager I'd sure be greatful. I'll leave it here......PhoneWindowsManager.smali
This is an error I'm getting when I...1 2 3 4 screenshot!
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Thank you
Once again my Sammy tablet is a bit diff...
Code:
.method public updateSettings()V
.locals 17
.prologue
.line 1714
move-object/from16 v0, p0
iget-object v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v12}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v8
.line 1715
.local v8, resolver:Landroid/content/ContentResolver;
const/4 v9, 0x0
.line 1722
.local v9, updateRotation:Z
const-string v12, "multi_window_enabled"
const/4 v13, 0x0
const/4 v14, -0x2
invoke-static {v8, v12, v13, v14}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v1
.line 1726
.local v1, enableMultiWindowUISetting:I
move-object/from16 v0, p0
iget-object v13, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mLock:Ljava/lang/Object;
monitor-enter v13
.line 1728
:try_start_0
move-object/from16 v0, p0
iget-boolean v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mIsMultiWindowEnabled:Z
if-eqz v12, :cond_1
.line 1729
move-object/from16 v0, p0
iget-boolean v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mSystemReady:Z
if-eqz v12, :cond_1
.line 1730
move-object/from16 v0, p0
iget v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mEnableMultiWindowUISetting:I
const/4 v14, -0x1
if-ne v12, v14, :cond_c
.line 1731
move-object/from16 v0, p0
iget-object v12, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mContext:Landroid/content/Context;
invoke-virtual {v12}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;
move-result-object v12
const-string v14, "multi_window_flashbar_shown"
const/4 v15, -0x1
const/16 v16, -0x2
move/from16 v0, v16
invoke-static {v12, v14, v15, v0}, Landroid/provider/Settings$System;->getIntForUser(Landroid/content/ContentResolver;Ljava/lang/String;II)I
move-result v6
.line 1734
.local v6, lastFlashBarVisibility:I
if-nez v6, :cond_b
Where and how to put this last piece of code. in. I have tried several times, but all I get is Sammy Logo. No boot...
Code:
#Music Mod
const-string v7, "volbtn_music_controls"
const/4 v9, 0x0
invoke-static {v12, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnMusicControls:I
const-string v7, "volbtn_timeout"
const/16 v9, 0x190
invoke-static {v12, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnTimeout:I
const-string v7, "volbtn_vol_up"
const/16 v9, 0x57
invoke-static {v12, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnVolUp:I
const-string v7, "volbtn_vol_down"
const/16 v9, 0x58
invoke-static {v12, v7, v9}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
move-result v3
move-object/from16 v0, p0
iput v3, v0, Lcom/android/internal/policy/impl/PhoneWindowManager;->mVolBtnVolDown:I
#End of Add - Music Mod
1brainsurgeon said:
If someone with the know-how could take a look at my PhoneWindowsManager I'd sure be greatful. I'll leave it here......PhoneWindowsManager.smali
This is an error I'm getting when I...1 2 3 4 screenshot!
Thank you
Click to expand...
Click to collapse
The error is somewhere on or around line 16553 is what the baksmali is reporting there.
Gunthermic said:
Once again my Sammy tablet is a bit diff...
Click to expand...
Click to collapse
Line right before adding the new section:
Code:
move-result-object v8
You didn't use v8 in the 4 places like I recommended in the guide to replace v13 in the new code.
tdunham said:
Line right before adding the new section:
Code:
move-result-object v8
You didn't use v8 in the 4 places like I recommended in the guide to replace v13 in the new code.
Click to expand...
Click to collapse
Will try again. I actually tried be and v12.. but maybe the placement is the screwy part... will try and see.
Thank you for helping tdun
Sent from my SM-T320 using Xparent BlueTapatalk 2
Gunthermic said:
Will try again. I actually tried be and v12.. but maybe the placement is the screwy part... will try and see.
Click to expand...
Click to collapse
It HAS to be v8 in those 4 places but maybe we need to change some other values too. Let me know how you make out.
tdunham said:
It HAS to be v8 in those 4 places but maybe we need to change some other values too. Let me know how you make out.
Click to expand...
Click to collapse
I will try v8... I think that is the area that can cause a big issue... I will report back....
Sent from my SM-T320 using Xparent BlueTapatalk 2
Question. I haven't had time to try the android policy edits yet but finished settings.... I tried to click the menu in settings to see if it works.... But get an fc in tap, menu won't even open..... Is this due to not doing the policy edits yet.... Or should it at least open anyways? Curious if I should go back thru settings or not.
Thanks.