edit_note帖子
189
stars积分
850
event加入
2013-07-17
安卓交流
安卓状态栏全局透明,时间居中教程!
schedule发表于 2013-09-29 00:23:00
visibility查看 2,270
chat_bubble回复 270
#1 楼主
时间居中教程
1.首先你的电脑里要搭建JAVA环境~
2.在你手机已经Root的情况下~打开Re管理器,
找到System文件夹下App文件夹里的systemUI.apk
把systemUI.apk复制黏贴到你SD卡里能找到的位置!
3.把SD卡的systemUI.apk拽到桌面上,
开始反编译systemUI.apk
4.找到res\layout\status_bar.xml
5.打开status_bar.xml(内容会有些不同哦,我手机就是这个,但安卓通用)
6.找到以下代码:
<com.android.systemui.statusbar.Clockandroid:textAppearance=“@android:style/TextAppearance.StatusBar.Icon“android:gravity=“left|center“android:paddingRight=“4.0dip“android:layout_width=“wrap_*“android:layout_height=“fill_parent“android:singleLine=“true“/>
并把上述代码全部删除,注意不要删错了喔!!!
8.在这句的下面添加如下代码:
<com.android.systemui.statusbar.Clockandroid:layout_gravity=“center_horizontal“android:paddingTop=“4.0dip“android:textAppearance=“@android:style/TextAppearance.StatusBar.Icon“android:layout_width=“wrap_*“android:layout_height=“fill_parent“android:singleLine=“true“/>
复制嘛,自己打很麻烦
9.最后完成后重编译,替换status_bar.xml后再替换到手机,重启!ok,这样个就可以时间居中了!(记得在Re里替换的时候修改权限!!!)
10.替换后时间没有垂直居中的话请调整这句:android:paddingTop=“4.0dip“
离顶部的距离
全局透明
一、反编译framework_res.apk
二、找到res/value/styles.xml
搜索
<itemname=“colorBackground“>@color/background_dark</item>
改为
<itemname=“colorBackground“>@color/transparent</item>
第二处搜索
<itemname=“windowBackground“>@drawable/screen_background_dark</item>
改为
<itemname=“windowBackground“>@drawable/screen_background_fly</item>
第三处搜索
<itemname=“windowShowWallpaper“>false</item>
改为
<itemname=“windowShowWallpaper“>true</item>
三、搜索<stylename=“Theme.Black“parent=“@style/Theme“>
将齐下两行改成
<itemname=“colorBackground“>@color/transparent</item>
<itemname=“windowShowWallpaper“>false</item>
<itemname=“windowBackground“>@drawable/screen_background_fly</item>
四、依次搜索
<stylename=“Theme.Dialog“parent=“@style/Theme“>
<stylename=“Theme.Light“parent=“@style/Theme“>
<stylename=“Theme.Translucent“parent=“@style/Theme“>
<stylename=“Theme.No*“parent=“@style/Theme“>
<stylename=“Theme.Panel“parent=“@style/Theme“>
在其下分别添加
<itemname=“windowShowWallpaper“>false</item>
也就是第四步要在各个主题下添加5个上述代码
五、
搜索
<stylename=“Theme.NoTitleBar“parent=“@style/Theme“>
在这个主题下添加代码
<itemname=“windowShowWallpaper“>true</item>
六、做一张名字为screen_background_fly.png的透明图片,放入drawable-mdpi文件夹里
七、回编,将resources.arsc和你刚才加的透明图片一起放进原来的APK里面。
八、安装,这里就不多说了
1.首先你的电脑里要搭建JAVA环境~
2.在你手机已经Root的情况下~打开Re管理器,
找到System文件夹下App文件夹里的systemUI.apk
把systemUI.apk复制黏贴到你SD卡里能找到的位置!
3.把SD卡的systemUI.apk拽到桌面上,
开始反编译systemUI.apk
4.找到res\layout\status_bar.xml
5.打开status_bar.xml(内容会有些不同哦,我手机就是这个,但安卓通用)
6.找到以下代码:
<com.android.systemui.statusbar.Clockandroid:textAppearance=“@android:style/TextAppearance.StatusBar.Icon“android:gravity=“left|center“android:paddingRight=“4.0dip“android:layout_width=“wrap_*“android:layout_height=“fill_parent“android:singleLine=“true“/>
并把上述代码全部删除,注意不要删错了喔!!!
8.在这句的下面添加如下代码:
<com.android.systemui.statusbar.Clockandroid:layout_gravity=“center_horizontal“android:paddingTop=“4.0dip“android:textAppearance=“@android:style/TextAppearance.StatusBar.Icon“android:layout_width=“wrap_*“android:layout_height=“fill_parent“android:singleLine=“true“/>
复制嘛,自己打很麻烦
9.最后完成后重编译,替换status_bar.xml后再替换到手机,重启!ok,这样个就可以时间居中了!(记得在Re里替换的时候修改权限!!!)
10.替换后时间没有垂直居中的话请调整这句:android:paddingTop=“4.0dip“
离顶部的距离
全局透明
一、反编译framework_res.apk
二、找到res/value/styles.xml
搜索
<itemname=“colorBackground“>@color/background_dark</item>
改为
<itemname=“colorBackground“>@color/transparent</item>
第二处搜索
<itemname=“windowBackground“>@drawable/screen_background_dark</item>
改为
<itemname=“windowBackground“>@drawable/screen_background_fly</item>
第三处搜索
<itemname=“windowShowWallpaper“>false</item>
改为
<itemname=“windowShowWallpaper“>true</item>
三、搜索<stylename=“Theme.Black“parent=“@style/Theme“>
将齐下两行改成
<itemname=“colorBackground“>@color/transparent</item>
<itemname=“windowShowWallpaper“>false</item>
<itemname=“windowBackground“>@drawable/screen_background_fly</item>
四、依次搜索
<stylename=“Theme.Dialog“parent=“@style/Theme“>
<stylename=“Theme.Light“parent=“@style/Theme“>
<stylename=“Theme.Translucent“parent=“@style/Theme“>
<stylename=“Theme.No*“parent=“@style/Theme“>
<stylename=“Theme.Panel“parent=“@style/Theme“>
在其下分别添加
<itemname=“windowShowWallpaper“>false</item>
也就是第四步要在各个主题下添加5个上述代码
五、
搜索
<stylename=“Theme.NoTitleBar“parent=“@style/Theme“>
在这个主题下添加代码
<itemname=“windowShowWallpaper“>true</item>
六、做一张名字为screen_background_fly.png的透明图片,放入drawable-mdpi文件夹里
七、回编,将resources.arsc和你刚才加的透明图片一起放进原来的APK里面。
八、安装,这里就不多说了
全部回复 (270)
2014-12-09 10:29:00
#262
好好,
2014-12-11 21:06:00
#263
哈哈哈哈哈
2014-12-12 20:47:00
#264
哈肉路体力活
2014-12-12 21:56:00
#265
85872
2014-12-13 22:09:00
#266
好
2015-04-04 21:54:00
#267
!?
2015-04-05 01:06:00
#268
好
2015-04-05 09:32:00
#269
vhf
2015-07-17 00:19:00
#270
头像咯弄
登录 后才能回复
flag举报帖子