如果要去掉手电筒等菜单,可以参考下面的方法。当然也不是唯一的方法。
1 找到通知栏对应的包名
包名为 com.android.systemui
在源码frameworks\base\中搜索”手电筒“,发现文件在frameworks\base\packages\SystemUI\res中
2 找到包名对应的java源码
在frameworks\base\packages\SystemUI\src\com\android\systemui\statusbar\phone\QSTileHost.java
找到以下函数
private QSTile<?> createTile(String tileSpec) {
...
3 注释以下部分
分别是自动旋转、手电筒、HotKnot、情景模式
// else if (tileSpec.equals("rotation")) return new RotationLockTile(this);
// else if (tileSpec.equals("flashlight")) return new FlashlightTile(this);
// else if (tileSpec.equals("hotspot")) retu