摘要: 官网镇楼: http://www.cocos2d-x.org/ cocos命令位置: /Users/wutianlong/Utility-Script/cocos2d-x-3.15.1/tools/cocos2d-console/bin cocos new Demo -p com.fhj.demo 阅读全文
posted @ 2017-06-06 17:16 吴添龙 阅读(275) 评论(0) 推荐(0) 编辑
摘要: public class PostTextView extends TextView { private Handler handler = new Handler(Looper.getMainLooper()); public PostTextView(Context context) { sup 阅读全文
posted @ 2017-06-05 11:23 吴添龙 阅读(1484) 评论(0) 推荐(0) 编辑
摘要: penaltyDeath(): Crash the whole process on violation. penaltyDeathOnNetwork(): Crash the whole process on any network usage. penaltyDialog(): Show an 阅读全文
posted @ 2017-05-31 16:04 吴添龙 阅读(257) 评论(0) 推荐(0) 编辑
摘要: private void setLinearLayoutParams(View imageView) { if (mScreenSize == 0 ) mScreenSize = getScreenSize(); int width = ViewGroup.LayoutParams.MATCH_PA 阅读全文
posted @ 2017-05-25 16:17 吴添龙 阅读(194) 评论(0) 推荐(0) 编辑
摘要: adb shell top -m 5 阅读全文
posted @ 2017-05-24 18:29 吴添龙 阅读(958) 评论(1) 推荐(0) 编辑
摘要: /** * 获取屏幕物理尺寸 * @return */private double getScreenSize(){ DisplayMetrics dm = new DisplayMetrics(); ((Activity)getContext()).getWindowManager().getDe 阅读全文
posted @ 2017-05-24 17:35 吴添龙 阅读(209) 评论(0) 推荐(0) 编辑
摘要: 1. Recording Settings中 include 添加 host , port端口为443 2. SSL Proxying Settings 选中 Enable SSL Proxying , 并且添加 host port 3. 从Charles中导出来本地certificate,用于导入 阅读全文
posted @ 2017-05-03 17:49 吴添龙 阅读(209) 评论(0) 推荐(0) 编辑
摘要: Recommended data-structures: ArrayMap<K,V> in place of HashMap<K,V> ArraySet<K,V> in place of HashSet<K,V> SparseArray<V> in place of HashMap<Integer, 阅读全文
posted @ 2017-05-03 10:34 吴添龙 阅读(118) 评论(0) 推荐(0) 编辑
摘要: Compile 默认的依赖方式,任何情况下都会依赖。 Provided 只提供编译时依赖,打包时不会添加进去。 Apk 只在打包Apk包时依赖,这个应该是比较少用到的。 TestCompile 只在测试时依赖 DebugCompile 只在Debug构建时依赖 ReleaseCompile 只在Re 阅读全文
posted @ 2017-05-02 10:31 吴添龙 阅读(288) 评论(0) 推荐(0) 编辑
摘要: 1. HashMap计算hash对key的hashcode进行了二次hash,以获得更好的散列值 2. 底层实现都是数组+链表结构实现! 3. HashMap会对null值key进行特殊处理,总是放到table[0]位置,数组初始长度为16 4.put过程是先计算hash然后通过hash与table 阅读全文
posted @ 2017-03-02 16:32 吴添龙 阅读(128) 评论(0) 推荐(0) 编辑