当前位置:网站首页>cocoscreator 显示刘海内容
cocoscreator 显示刘海内容
2022-07-31 05:15:00 【xuyid】
修改libcocos2dx的Utils文件
注释掉SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN和SYSTEM_UI_FLAG_FULLSCREEN
public static void hideVirtualButton() { if (Build.VERSION.SDK_INT >= 19 && null != Utils.sActivity) { // use reflection to remove dependence of API level Class viewClass = View.class; final int SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION = Cocos2dxReflectionHelper.<Integer>getConstantValue(viewClass, "SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION"); final int SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN = Cocos2dxReflectionHelper.<Integer>getConstantValue(viewClass, "SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN"); final int SYSTEM_UI_FLAG_HIDE_NAVIGATION = Cocos2dxReflectionHelper.<Integer>getConstantValue(viewClass, "SYSTEM_UI_FLAG_HIDE_NAVIGATION"); final int SYSTEM_UI_FLAG_FULLSCREEN = Cocos2dxReflectionHelper.<Integer>getConstantValue(viewClass, "SYSTEM_UI_FLAG_FULLSCREEN"); final int SYSTEM_UI_FLAG_IMMERSIVE_STICKY = Cocos2dxReflectionHelper.<Integer>getConstantValue(viewClass, "SYSTEM_UI_FLAG_IMMERSIVE_STICKY"); final int SYSTEM_UI_FLAG_LAYOUT_STABLE = Cocos2dxReflectionHelper.<Integer>getConstantValue(viewClass, "SYSTEM_UI_FLAG_LAYOUT_STABLE"); // getWindow().getDecorView().setSystemUiVisibility(); final Object[] parameters = new Object[]{SYSTEM_UI_FLAG_LAYOUT_STABLE | SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION // | SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN | SYSTEM_UI_FLAG_HIDE_NAVIGATION // hide nav bar // | SYSTEM_UI_FLAG_FULLSCREEN // hide status bar | SYSTEM_UI_FLAG_IMMERSIVE_STICKY}; Cocos2dxReflectionHelper.<Void>invokeInstanceMethod(Utils.sActivity.getWindow().getDecorView(), "setSystemUiVisibility", new Class[]{Integer.TYPE}, parameters); } }
边栏推荐
- C language tutorial (2) - printf and data types that come with c
- Build vulhub vulnerability shooting range on kali
- Linux中mysql密码修改方法(亲测可用)
- [Elastic-Job] Overview of Distributed Scheduling Tasks
- vulhub靶场学习日记SickOs1.2
- File operations in C language (1)
- Regular Expression Basics
- [Cloud native] Open source data analysis SPL easily copes with T+0
- js中的this指向与原型对象
- [Cloud native] Ribbon is no longer used at the bottom layer of OpenFeign starting from the 2020.0.X version
猜你喜欢
永恒之蓝漏洞复现
GUCCI, LV and other luxury giant universe how to layout yuan, other brands should keep up with?
[Ubuntu20.04 installs MySQL and MySQL-workbench visualization tool]
[swagger close] The production environment closes the swagger method
最新MySql安装教学,非常详细
元宇宙的前景及四大赛道
For penetration testing methods where the output point is a timestamp (take Oracle database as an example)
Common JVM interview questions and answers
mysql password modification method in Linux (pro-test available)
Access database query
随机推荐
理解js运算符
sqlmap injection tutorial common commands
Build vulhub vulnerability shooting range on kali
js中的break与continue退出
工件SSMwar exploded 部署工件时出错。请参阅服务器日志了解详细信息
Error: Cannot find module 'D:\Application\nodejs\node_modules\npm\bin\npm-cli.js'
初识正则表达式
Build DVWA with phpstudy
Why is the redis single-threaded also so fast?
"limit" query in Oracle database
【云原生】原来2020.0.X版本开始的OpenFeign底层不再使用Ribbon了
leetcode-每日一题873. 最长的斐波那契子序列的长度(哈希和二分)
一文速学-玩转MySQL获取时间、格式转换各类操作方法详解
5 methods of MySQL paging query
Error: Cannot find module ‘D:\Application\nodejs\node_modules\npm\bin\npm-cli.js‘
Install mysqldb in mac10.14
vulhub靶场学习日记hackme1
[Elastic-Job] Overview of Distributed Scheduling Tasks
2021美赛C题M奖思路
腾讯云轻量服务器删除所有防火墙规则