安卓是否有什么方法来检测的CyanogenMod及其版本? [英] Does Android have any way to detect cyanogenmod and its version?

查看:115
本文介绍了安卓是否有什么方法来检测的CyanogenMod及其版本?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的工作,需要均衡器是Android的媒体播放器。然而,均衡器仅适用于姜饼及以上,但的CyanogenMod 6已经修改audioflinger充当均衡器,所以我想检测操作系统版本。

I'm working on an android media player which needs equalizer. However, equalizer is only available on Gingerbread and above, but cyanogenmod 6 has modified audioflinger to act as equalizer, so I want to detect OS version.

推荐答案

您可以阅读 os.version 财产和对阵是:

You can read the os.version property and match against that:

String version = System.getProperty("os.version");
if (version.contains("cyanogenmod")) {
    isCyanogenMode = true;
}

在我的设备, os.version 2.6.37.6-的CyanogenMod-01509-g8913be8

这篇关于安卓是否有什么方法来检测的CyanogenMod及其版本?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆