Quantcast
Channel: xda-developers - Android Themes
Viewing all articles
Browse latest Browse all 4090

[Q] Change Order of Status Bar Icons

$
0
0
Evening all,

I'm not sure if this is the right place to post this but I couldn't see any more obvious place to put it.

Basically, the "Vibrate" status bar icon annoys me to the point I want to throw my phone out of the window (really!).

So I went to my SystemUI.apk and replaced all files named "stat_sys_ringer_vibrate.png" with blank png files of the same height but 1px wide.

Attachment 3120145

The removal of the icon worked great, but I am left with a big blank space where it used to be that's equally as annoying! Does anyone know how I can change the space allocated to this specific icon or change the order of those icons so my bluetooth (and up/down traffic indicators which aren't visible in the screenshot) appear after the blank icon?

Thanks.

EDIT: For anyone who finds this post via a search I solved this issue by decompiling my SystemUI.apk and editing the following file;

Code:

smali/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.smali
The change I made is probably rom specific but just for reference I changed;

Code:

const-string v7, "volume"

    invoke-virtual {v6, v7, v2, v5, v1}, Landroid/app/StatusBarManager;->setIcon(Ljava/lang/String;IILjava/lang/String;)V

    :cond_1
    iget-boolean v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;->mVolumeVisible:Z

    if-eq v4, v5, :cond_2

    iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;->mService:Landroid/app/StatusBarManager;

    const-string v6, "volume"

    invoke-virtual {v5, v6, v4}, Landroid/app/StatusBarManager;->setIconVisibility(Ljava/lang/String;Z)V

    iput-boolean v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;->mVolumeVisible:Z

    :cond_2
    return-void

to this;

Code:

  goto :goto_bb
    const-string v7, "volume"

    invoke-virtual {v6, v7, v2, v5, v1}, Landroid/app/StatusBarManager;->setIcon(Ljava/lang/String;IILjava/lang/String;)V

    :cond_1
    iget-boolean v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;->mVolumeVisible:Z

    if-eq v4, v5, :cond_2

    iget-object v5, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;->mService:Landroid/app/StatusBarManager;

    const-string v6, "volume"

    invoke-virtual {v5, v6, v4}, Landroid/app/StatusBarManager;->setIconVisibility(Ljava/lang/String;Z)V

    iput-boolean v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBarPolicy;->mVolumeVisible:Z

    :goto_bb
    :cond_2
    return-void


Attached Thumbnails
Click image for larger version

Name:	Screenshot_2015-01-17-19-49-01.jpg
Views:	N/A
Size:	165.9 KB
ID:	3120145  

Viewing all articles
Browse latest Browse all 4090

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>