摘要:原文地址:https://developer.apple.com/library/prerelease/ios/#releasenotes/General/WhatsNewIniPhoneOS/Articles/iOS5.htmliCloud Storage APIsThe iCloud storage APIs let your application write user documents and data to a central location and access those items from all of a user’s computers and iOS devices
阅读全文
摘要:这几天通过iTunes看了斯坦福大学的视频教程,学到了不少东西,给大家推荐一下:斯坦福iPhone编程课程收看次数破百万http://zx.sj.91.com/content/2009-05-18/20090518175143833.shtmlhttp://itunes.stanford.edu/其他iPhone资料:10家不错的iPhone编程资源网站http://news.weiphone.com/news/2008-12-12/10jiabucuodeiPhonebianchengziyuanwangzhan_171541.shtmliphone遊戲編程教材網站推薦今天無意中找到這個叫
阅读全文
摘要:来自http://blog.csdn.net/omgle/archive/2011/06/29/6574313.aspx第一部分:Push原理(以下绝大多数内容参考自、图片来自iPhone OS Reference Library)机制简介Push的工作机制可以简单的概括为下图图中,Provider是指某个iPhone软件的Push服务器。APNS是Apple Push Notification Service(Apple Push服务器)的缩写,下文统一使用该缩写。因此,整个过程可以分为三个阶段,下面用大家常用的聊天客户端BeejiveIM来说明。(BeejiveIM是一款支持多账户登录的支
阅读全文
摘要:Bells And WhistlesThe iPhone has a set of nice transition animations which makes the experience using it very pleasant. But after a while one get so used of them that one stop noticing that they are even there. But this is not necessary a bad thing. Often I think thatreallygood things doesn’t show a
阅读全文
摘要:Search and highlight text in UIWebViewSeveral iPhone Apps (like my “iCab Mobile” or “NewsTap” Apps) provide a search feature which allows to search for text in the content that is currently displayed within a UIWebView. The found occurrences of the searched text are highlighted with a yellow backgro
阅读全文
摘要:WebKit on the iPhone (Part 1)If you develop an application which should display a web page or HTML file,you can use the WebKit framework, which is part of the MacOS and also of theiPhone OS.But while on the Mac, the WebKit framework provides almost 160 public headerfiles which define even more publi
阅读全文
摘要:在info.plist文件里看看有没有“Application does not run in background”这一个key,如果没有,点最后一行,然后点这行右边的加号,你会看见最底下又变出来一行,在里面选择“Application does not run in background”,然后把钩打上
阅读全文
摘要:UIDevice *device = [UIDevice currentDevice]; return [device uniqueIdentifier];
阅读全文
摘要:NSDecimalNumber 是NSNumber的子类。
使用 [NSNumber numberWithDouble:]方法来格式我的NSNumber,但是,由于一些值比较大,我想要用科学计数法来表示。
NSDecimalNumber就提供了科学计数法的表示方法。
什么是科学计数法? 将一个数字表示成 (a×10的n次幂的形式),其中1≤a<10,n表示整数,这种记数方法叫科学记数法。 用幂的形式,有时可以方便的表示日常生活中遇到的一些较大的数,如:光的速度大约是300 000 000米/秒;全世界人口数大约是:6 100 000 000 这样的大数,读、写都很不方便,考虑到10的
阅读全文
摘要:接前一篇博文《开源框架Core Plot的使用》。 如果使用了Core Plot标准Mac安装包进行安装,使用起来有一些变化。其实,如果你注意到安装器的最后一个界面,这里已经有一个如何使用的介绍了: To add the Core Plot SDKs to an iOS Project: 1. Add to your project's .PCH file: #import 3. Open Project -> Edit Project Settings and for All Configurations : 3a. Add to Additional SDKS : (Syst
阅读全文
摘要:在多线程操作中,有一个著名的错误,叫做“Tried to obtain the web lock from a thread other than the main thread or the web thread. This may be a result of calling to UIKit from a secondary thread”,一旦出现这个错误,程序会立即crashed。
这是由于,apple不允许程序员在主线程以外的线程中对ui进行操作(Bug?)
而笔者在一次http异步操作中也出现过这个错误。当时使用了NSOperation进行了http异步请求,然后使用kvo模式注
阅读全文
摘要:由于iPhone控件的极度匮乏和自定义组件在重用上的限制,在过去的项目中我们积累了大量的“纯代码”组件——因为IB本身的限制,我们无法把这些组件封装为IB组件库(本来我们想通过分发xib文件的方式重用这些组件,但最终发现这根本不可能,苹果的Plug-in编程不支持iPhone)。 最终我们想到了静态库。虽然这仍然还是一种比较原始的复用方式,但起码我们可以隐藏组件的源代码。 下面, 我们使用iPhone静态库把自定义组件CheckButton 进行进一步的封装。(组件的实现参考前一篇博文《自定义控件复选框和单选框的实现》) 一、实现静态库 新建工程, 选择 Library 下的 “ Cocoa
阅读全文
摘要:(转)multipart form-data boundary 说明收藏原文链接:http://yefeng.javaeye.com/blog/315847含义 ENCTYPE="multipart/form-data" 说明:通过 http 协议上传文件 rfc1867协议概述,jsp 应用举例,客户端发送内容构造1、概述在最初的 http 协议中,没有上传文件方面的功能。 rfc1867 (http://www.ietf.org/rfc/rfc1867.txt) 为 http 协议添加了这个功能。客户端的浏览器,如 Microsoft IE, Mozila, Opera
阅读全文
摘要:iOS 4.3 to iOS 5.0 API Differences Added frameworks: Accounts CoreBluetooth CoreImage GLKit GSS NewsstandKit Twitter Accelerate Alpha.h Added #def VIMAGE_ALPHA_H Added vImageAlphaBlend_ARGB8888() Added vImageAlphaBlend_ARGBFFFF() Added vImageAlphaBlend_NonpremultipliedToPremultiplied_ARGB8888() Add.
阅读全文
摘要:NSDateFormatter setDateFormat 自定義日期/時間格式 參考: http://unicode.org/reports/tr35/tr35-6.html#Date_Format_Patterns
阅读全文
摘要:http://blog.carbonfive.com/2011/04/04/using-open-source-static-libraries-in-xcode-4/
阅读全文
摘要:为了代码保密或者代码重用等等原因需要把现有的代码打包放入静态库中,这也是静态库的好处,所以今天一天都在研究如何用xcode 4创建静态库,也是为了我们的项目需要。QQ发布的微博SDK会报错,也是因为没有把静态库打包为unniver static libraries的原因,至于是什么是unniver static libraries,大家可以google一下。(http://blog.boreal-kiss.net/2011/03/15/how-to-create-universal-static-libraries-on-xcode-4/)下面是创建静态库的方法1.xcode-create p
阅读全文
摘要:http://developer.apple.com/library/prerelease/ios/#releasenotes/General/WhatsNewIniPhoneOS/Articles/iPhoneOS4.html#//apple_ref/doc/uid/TP40009559-SW5
阅读全文
摘要:Sizes of iPhone UI Elements Element Size (in points) Window (including status bar) 320 x 480 pts Status Bar (How to hide the status bar) 20 pts View inside window (visible status bar) 320 x 460 Navigation Bar 44 pts Nav Bar Image / Toolbar Image up to 20 x 20 pts (transparent PNG) Tab Bar 49 pts Ta.
阅读全文
摘要:Technical Q&A QA1686
引用网址:http://developer.apple.com/library/ios/#qa/qa1686/_index.html
App Icons on iPad and iPhone
Q: How are the icon files in my application bundle used on iPad and iPhone?
A: How are the icon files in my application bundle used on iPad and iPhone?
Below are guidelines for ha
阅读全文