最重要的事情,我想知道的是设备类型,操作系统版本,如果它有一个硬件键盘,也许是屏幕分辨率。但如果你知道其他有用的调试信息,请添加它们:)
The most important things i want to know are the device type, the os version, if it has a hardware keyboard and maybe the screen resolution. but if you know other useful debug information please add them :)
我发现本作的操作系统版本:
i found this for the os version:
string+="OS Version: "+System.getProperty("os.version");
我如何获得其他属性?
how do i get the other properties?
编辑:获得有用的属性,一个完整的概述,我在我的ErrorHandler活动结合它们放在一起(开始读取行559):https://github.com/bitstars/SimpleUi/blob/master/SimpleUI/src/tools/ErrorHandler.java#L559
edit: to get a complete overview of useful attributes, I combined them all together in my ErrorHandler activity (start to read at line 559): https://github.com/bitstars/SimpleUi/blob/master/SimpleUI/src/tools/ErrorHandler.java#L559
Windowsize和键盘presence是一个不错的主意,我增加了一些更相关信息用于调试的目的:
Windowsize and keyboard presence were a good idea, i added some more infos for debug purpose:
String s="Debug-infos:";
s += "\n OS Version: " + System.getProperty("os.version") + "(" + android.os.Build.VERSION.INCREMENTAL + ")";
s += "\n OS API Level: " + android.os.Build.VERSION.SDK_INT;
s += "\n Device: " + android.os.Build.DEVICE;
s += "\n Model (and Product): " + android.os.Build.MODEL + " ("+ android.os.Build.PRODUCT + ")";