我有一直扎根并试图运行它具有代码隐藏系统栏中的应用程序在Android果冻豆平板电脑,但它没有得到隐藏任何一个可以帮助我在这。
获得输出在终端: Result Parcel(00000000 '....')
public class MainActivity extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
Button hide=(Button)findViewById(R.id.button1);
Button show=(Button)findViewById(R.id.button2);
hide.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
// TODO Auto-generated method stub
Log.v("ds", "hideSystembar");
try {
Process proc = Runtime.getRuntime().exec(new String[]{
"su","-c","service call activity 79 s16 com.android.systemui"});
proc.waitFor();
} catch (Exception e) {
e.printStackTrace();
}
}
});
show.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
// TODO Auto-generated method stub
Log.v("f", "showSystembar");
try {
Process proc = Runtime.getRuntime().exec(new String[]{
"am","startservice","-n","com.android.systemui/.SystemUIService"});
proc.waitFor();
} catch (Exception e) {
e.printStackTrace();
}
}
});
}
}
虽然我得到获准的敬酒:
超级用户登录屏幕截图: