随笔分类 - Android
摘要:链接:http://www.zhihu.com/question/19788650/answer/60771437来源:知乎Google 官方[Android Developers Blog](Android Developers Blog) [Android Official Blog](Offi
阅读全文
摘要:Manifest.permission 官方API说明: http://developer.android.com/reference/android/Manifest.permission.html http://developer.android.com/guide/topics/manifes
阅读全文
摘要:在实际开发中LayoutInflater这个类还是非常有用的,它的作用类似于findViewById()。不同点是LayoutInflater是用来找res/layout/下的xml布局文件,并且实例化;而findViewById()是找xml布局文件下的具体widget控件(如Button、Tex
阅读全文
摘要:Toast在手机屏幕上向用户显示一条信息,一段时间后信息会自动消失。 1.默认用法 [html] view plain copy print?Toast.makeText(getApplicationContext(), "默认Toast样式",Toast.LENGTH_SHORT).show();
阅读全文
摘要:APKtool 用途:获取mainifest.xml res等资源文件 下载:http://ibotpeaches.github.io/Apktool/install/ 使用:apktool d test.apk dex2jar 用途:获取项目源码的jar包 下载:https://github.co
阅读全文
摘要:一,Bug出现了, 需要“干掉”它 bug一听挺吓人的,但是只要你懂了,android里的bug是很好解决的,因为android里提供了LOG机制,具体的底层代码,以后在来分析,只要你会看bug, android里应用开发也就很简单了。 那我们先来看看android里的ANR,怎么出现ANR呢,很简
阅读全文
摘要:1、 精确获取屏幕尺寸(例如:3.5、4.0、5.0寸屏幕) 123456public static double getScreenPhysicalSize(Activity ctx) { DisplayMetrics dm = new DisplayMetrics(); ctx.getWindo
阅读全文
摘要:ADB很强大,记住一些ADB命令有助于提高工作效率。 获取序列号: 查看连接计算机的设备: 重启机器: 重启到bootloader,即刷机模式: 重启到recovery,即恢复模式: 查看log: 终止adb服务进程: 重启adb服务进程: 获取机器MAC地址: 获取CPU序列号: 安装APK: 保
阅读全文