当前位置: 首页 > news >正文

高端装饰公司网站设计果洛电子商务网站建设

高端装饰公司网站设计,果洛电子商务网站建设,仙居做网站公司,软件定制合同模板环境 aosp: android-14.0.0_r1 真机#xff1a;Pixel5 目标 我想把usb连接的两个系统通知屏蔽掉 “正在通过 USB 为此设备充电”“已连接到 USB 调试” 步骤 首先找到这两句内容出现的位置在 frameworks/base/core/res/res/values-zh-rCN/strings.xml string namePixel5 目标 我想把usb连接的两个系统通知屏蔽掉 “正在通过 USB 为此设备充电”“已连接到 USB 调试” 步骤 首先找到这两句内容出现的位置在 frameworks/base/core/res/res/values-zh-rCN/strings.xml string nameusb_charging_notification_title msgid1674124518282666955正在通过 USB 为此设备充电/stringstring nameadb_active_notification_title msgid408390247354560331已连接到 USB 调试/string string nameadb_active_notification_message msgid5617264033476778211点按即可关闭 USB 调试/string然后找到代码实现的位置 分别是 frameworks/base/core/java/android/debug/AdbNotifications.java frameworks/base/services/usb/java/com/android/server/usb/UsbDeviceManager.java Notification.Builder builder new Notification.Builder(mContext, channel).setSmallIcon(com.android.internal.R.drawable.stat_sys_adb).setWhen(0).setOngoing(true).setTicker(title).setDefaults(0) // please be quiet.setColor(mContext.getColor(com.android.internal.R.color.system_notification_accent_color)).setContentTitle(title).setContentText(message).setContentIntent(pi).setVisibility(Notification.VISIBILITY_PUBLIC);if (titleRes com.android.internal.R.string.usb_unsupported_audio_accessory_title) {builder.setStyle(new Notification.BigTextStyle().bigText(message));}Notification notification builder.build();mNotificationManager.notifyAsUser(null, id, notification,UserHandle.ALL);Slog.d(TAG, push notification: title);Log.w(TAG, push notification:title title ;message message);mUsbNotificationId id;if (!mAdbNotificationShown) {Notification notification AdbNotifications.createNotification(mContext,AdbTransportType.USB);mAdbNotificationShown true;Log.w(TAG, updateAdbNotification:id id);mNotificationManager.notifyAsUser(null, id, notification, UserHandle.ALL); }主要是mNotificationManager.notifyAsUser()这个方法它会把内容都通知出去。所以处理它就行如果不想要所有的系统通知屏蔽掉它就行。但我只是不想要两个内容。 修改如下 Notification notification builder.build(); if(message ! null !message.equals(r.getText(com.android.internal.R.string.usb_notification_message))) {mNotificationManager.notifyAsUser(null, id, notification,UserHandle.ALL); }if (!mAdbNotificationShown) {Notification notification AdbNotifications.createNotification(mContext, AdbTransportType.USB);mAdbNotificationShown true;//mNotificationManager.notifyAsUser(null, id, notification, UserHandle.ALL); }很简单吧最后测试通过
http://www.w-s-a.com/news/347370/

相关文章:

  • 个人网站能备案吗酱香拿铁采取了哪些网络营销方式
  • 网站建设及推广好做吗自己做的网站加入购物车价格
  • 涡阳在北京做网站的名人注册一个免费的网站
  • 三门峡建设环境局网站公司注册网上核名通道
  • 叶县建设局网站要看网海外域名是多少
  • 网站运行环境配置Wordpress支付时效
  • logo设计网站知乎港北网站建设
  • 北京市保障性住房建设投资中心官方网站有限责任公司的特点
  • 做网站卖互联网营销怎么做
  • 晋州市建设局网站建站网站系统
  • 专业网站优化方案广东微信网站制作报价表
  • 北京网站建设公司分形科技简述营销网站建设策略
  • 汉中网站建设有限公司vue网站开发
  • 网站备案背景幕布阳江东莞网站建设
  • 北京网站建设要多少钱html网站标签
  • 做兼职做网站的是什么公司网站怎么修改
  • 舆情监控都有哪些内容西安seo网站公司
  • 网站有域名没备案天津网络营销
  • 哈巴狗模式网站开发电子商务平台建设与运营技术
  • 摄影网站源码wordpress内涵段子
  • 实验一 电子商务网站建设与维护图片做网站
  • 网站策划书模板大全中国建设部官方网站资格证查询
  • vps绑定多个网站创意咨询策划公司
  • 做qq图片的网站网页制作与网站建设江西
  • 做爰全过程的视频网站网络文化经营许可证怎么办
  • 常德市网站建设网站开发用哪个软件好
  • 网站文章怎么更新时间重庆勘察设计网
  • 外卖网站设计企业网站优化做法
  • 专业的营销型网站制作wordpress版权年份
  • 程序员会搭建非法网站吗怎么把wordpress字去掉