zoukankan      html  css  js  c++  java
  • 查询SystemFeature的方法

       查询SystemFeature的方法可以在adb shell下敲如下的命令:

    dumpsys package

    然后搜feature关键字。

     

    例如,我的平台的SystemFeature,如下所示:

    Features:
      android.hardware.faketouch
      android.hardware.wifi
      android.hardware.camera
      android.hardware.wifi.direct
      android.hardware.usb.accessory
      android.hardware.microphone
      android.hardware.usb.host
      android.hardware.camera.autofocus
      android.software.live_wallpaper
      android.hardware.touchscreen
      android.hardware.screen.portrait
      android.hardware.camera.flash

     

    没有mHasDistinctMultitouch=context.getPackageManager().hasSystemFeature(PackageManager.FEATURE_TOUCHSCREEN_MULTITOUCH_DISTINCT);

    ”android.hardware.touchscreen.multitouch.distinct”这一项。


    如果有这一项的会导致如下的判断不执行:

      public void onCodeInput(intprimaryCode, int[] keyCodes, int x, int y) {

            caseKeyboard.CODE_SWITCH_ALPHA_SYMBOL:

                // Symbol key is handled in onPress()when device has distinct multi-touch panel.

                Log.v("onKeyDown","---------changeKeyboardMode-------11------------"+distinctMultiTouch);

               if (!distinctMultiTouch) {

           Log.v("onKeyDown","---------changeKeyboardMode-------12------------");

                    switcher.changeKeyboardMode();

                }

    这样就会导致遥控器去操控的时候,出现很多的问题。




  • 相关阅读:
    log4j/log4e的使用
    数据库主键不应该具有任何业务意义
    孔雀森林,何时开屏
    spring + hibernate
    JAVA的运行时类型识别(RTTI)
    开年感想,2005年总结
    iphone真机(越狱)通讯录导入进模拟器
    xcode中工程引用设置
    UIButton setImage 图片大小选择
    加密技术资源
  • 原文地址:https://www.cnblogs.com/javawebsoa/p/3199023.html
Copyright © 2011-2022 走看看