码迷,mamicode.com
首页 > 移动开发
Android中Activity中使用ListView与ListActivity中使用ListView的区别与联系
Android中Activity与ListActivity使用ListView的区别与联系:1. Activity的使用: (1).概念: 每一个activity对应于一个显示界面,每一个activity都是独占整个屏幕的. (2).步骤: A:xml布局中,ListView标签id可以任意取值如:<ListView an...
分类:移动开发   时间:2015-05-03 12:02:36    阅读次数:182
AndroidStudio项目移植到Eclipse
原文件结构:在AndroidStudio中 main目录对应eclipse中的src目录可以看看每个文件夹下的目录 没有src或者main这些文件夹的都可以删掉我这里只有app下的东西是需要留着的:将src中main下的东西全都拷出来放到app文件夹下 其他文件和文件夹都可以删掉然后就可以impor...
分类:移动开发   时间:2015-05-03 11:59:34    阅读次数:166
iOS-获取当前时间的年、月、日、时、分、秒
//获取当前时间02 NSDate *now = [NSDate date];03 NSLog(@”now date is: %@”, now);0405 NSCalendar *calendar = [NSCalendar currentCalendar];06 NSUInteger unitFl...
分类:移动开发   时间:2015-05-03 11:59:15    阅读次数:125
OC开发_Storyboard——UIApplication和网络活动指示器
一、UIApplication 只有一个实例: UIApplication *myApplication = [UIApplication sharedApplication]; 属性如果设置为YES的话,状态栏上的小转轮就会转,NO则不会[网络活动的表示,正在进行网络活动]@property (n...
分类:移动开发   时间:2015-05-03 11:56:26    阅读次数:165
iOS CoreData relationship 中的inverse
官方文档建议为每一个可以设置inverse的relationship设置一个inverse。目的是保持数据库的正确性。但是没有具体的说明。我在stackoverflow中找到了一个是分好的答案,http://stackoverflow.com/questions/764125/does-every-...
分类:移动开发   时间:2015-05-03 11:52:18    阅读次数:165
认识安卓
等级划分API等级1: Android 1.0API等级2: Android 1.1 Petit Four 花式小蛋糕API等级3: Android 1.5 Cupcake 纸杯蛋糕API等级4: Android 1.6 Donut 甜甜圈API等级5: Android 2.0 éclair 松饼A...
分类:移动开发   时间:2015-05-03 11:51:39    阅读次数:143
IOS中UIActionSheet使用详解
IOS中UIActionSheet使用方法详解 一、初始化方法 - (instancetype)initWithTitle:(NSString *)title delegate:(id<UIActionSheetDelegate>)delegate cancelButtonTitle:(NSString *)cancelButtonTitle destructi...
分类:移动开发   时间:2015-05-03 10:46:38    阅读次数:132
Google推荐的命名规则——Android图片资源
1.译 资产类型 前缀 例子 图标 ic_ ic_star.png 启动图标 ic_launcher ic_launcher_calendar.png 菜单图标和操作栏图标 ic_menu ic_menu_archive.png 状态栏图标 ic_stat_notify ic_stat_notify_msg.png 标签(选项卡)的图标...
分类:移动开发   时间:2015-05-03 10:44:59    阅读次数:204
IOS --- NSFetchResultsController
NSFetchedResultsController和UITableView集成起来处理数据具有强大的灵活性。首先得到的好处是不需要将数据记录进行分页,不然,按照传统的做法,需要先查询出总的记录,然后再从纪录里面过滤,这样会进行两次操作,对内存消耗很大,处理不好,程序甚至可能崩溃。使用NSFetchedResultsController类不仅简单,还具有更高的性能,这个类自动帮助你记录分页的事情,得...
分类:移动开发   时间:2015-05-03 10:43:30    阅读次数:119
使用android真机测试http网络连接异常解决办法
最近在学校android网络编程之json解析时遇到不少问题,其中之一是在使用http协议连接网络时总是出错,捣鼓了将近两天,终于略有所悟,现记录如下。 一 、问题描述 首先我是在本地tomcat服务器上部署一个web项目,通过web项目的servlet完成对客户端连接请求的操作。其他都很顺利,在电脑浏览器上输入URL访问正常,在eclipse上创建Java项目也能正常访问。但是一旦放在a...
分类:移动开发   时间:2015-05-03 10:42:41    阅读次数:795
202. Happy Number Leetcode Python
Write an algorithm to determine if a number is "happy". A happy number is a number defined by the following process: Starting with any positive integer, replace the number by the sum of the squares...
分类:移动开发   时间:2015-05-03 10:43:52    阅读次数:145
兔子--android开发中 java.lang.IllegalThreadStateException: Thread already started
原因:thread的没有停止,就又去启动这个线程了, 解决办法:我只列出了关键代码:  btnStart.setOnClickListener(new View.OnClickListener() {             @Override             public void onClick(View v) {                 new Thread...
分类:移动开发   时间:2015-05-03 10:43:15    阅读次数:309
POJ 3321 Apple Tree(树状数组)
Apple Tree Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 20671   Accepted: 6257 Description There is an apple tree outside of kaka's house. Every autumn,...
分类:移动开发   时间:2015-05-03 10:39:40    阅读次数:164
Android开源框架Universal-Image-Loader学习四——LimitedMemoryCache的一些子集
LRULimitedMemoryCache源码: /** * (cache size limited)Size of all stored bitmaps will not to exceed size limit. * (删除策略LRU)When cache reaches limit size then the least recently used bitmap is delete...
分类:移动开发   时间:2015-05-03 10:39:25    阅读次数:186
【转】Any way to implement BLE notifications in Android-L preview----不错
原文网址:http://stackoverflow.com/questions/24865120/any-way-to-implement-ble-notifications-in-android-l-previewThis question is not about Android notific...
分类:移动开发   时间:2015-05-03 10:35:32    阅读次数:224
android softinput 相关
getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN | WindowManager.LayoutParams.SOFT_INPUT_ADJUST_UNSPECIF...
分类:移动开发   时间:2015-05-03 10:34:27    阅读次数:218
OpenWrt挂载移动硬盘实现脱机下载
一、编译选项选好好usb存储驱动,参考http://www.cnblogs.com/smbx-ztbz/p/4418245.html并且选上kmod-usb-hid,用于usbhub。二、编译选项选aria2、luci-app-aria2、webui-aria2、yaaw参考 http://www....
分类:移动开发   时间:2015-05-03 10:31:45    阅读次数:226
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!