随笔分类 - macos/objective-c
摘要:想写这东西很久了,之前因为真的事很多,几乎没有办法去思考问题,工作也不顺。 不顺的原因是,总觉得自己和这个team不合。 前几天CEO和每个IOS的engineer都说了话(感觉好阴险的样子),然后我也有一句说一句。但是,还是没有放开来说,我把这个归咎为中国式教育的恶果:不敢发表自己的意见(or总是埋藏自己的意见)。 在谈话结束后我就有点不甘了,因为这么好的机会,可以充分表达自己意见的机会,就这样放弃了。真心觉得机会是“稍纵即逝”的,也对自己说了,以后在合适的场合一定要展现自己! 好了,说完这些,其实,我感受最深的是在这个team中的冲突太多了。我之前有工作经验,所以接触过的软件组...
阅读全文
摘要:iphone4火了之后,我一个冲动,买了个air,就想写ios 的app了。 结果可想而知。 然后,我还是能进到一个创业型公司。我把能找到工作的原因归咎在两点:一、市场对ios程序员需求很刚性。二、我不是毕业生。 第一点是至关重要的。然后我在公司的经历,让我觉得有点意外。 1、公司重视“用户体验”。 我接到的第一个任务就是写一个Twitter消息的个人展示,业务就是:如果你在我们的app上绑定了twitter账号,就可以在一个view上展示某个人的最新10条twitter,以及自己的一些可以公开的个人信息。 这次的开发我觉得难点就在UITableViewCell的动态高度上。但...
阅读全文
摘要:http://cocoamanifest.net/articles/2011/12/running-your-ios-app-in-the-simulator-from-the-command-line.htmlabove is for debugupdate:here is for archiveuse xcrun and xcodebuild to package *ipa(show me the introdution) http://miraclei.net/?p=551(show me the app file path:build/.........)http://www.cnbl
阅读全文
摘要:-(CGSize)dynamicHeightForTextViewWithFont:(UIFont*)s_fontConstrainSize:(CGSize)s_size{//UItextView会有一个padding,为8//详情:http://www.1mima.com/uitextview使用-sizewithfontconstrainedtosizelinebreakmode计算高度不准确的解决方案///维护bmleung@weiwo.comCGSizeadapter_size=CGSizeMake(s_size.width-16,s_size.height);//宽度减去paddin
阅读全文
摘要:source:http://www.cocoanetics.com/2011/12/sub-projects-in-xcode/translation:http://www.xiaojiayi.com/2012/08/15/xcode中的子项目(译文)/is work!
阅读全文
摘要:link: http://www.appledoes.com/usb-zte-modem-will-crash-your-snow-leopard-here-is-how-to-fix-it.htmlcontent:Today, we have a customer who have installed the ZTE Modem 626 on her brand new Macbook.The thing is, when she installed it, everything went smooth and no problem found. But, after you reboot
阅读全文
摘要:http://www.cnblogs.com/speeding/archive/2012/07/01/2571706.html
阅读全文
摘要:i use this solution :After finding this StackOverflow article:http://stackoverflow.com/questions/5543854/xcode-4-cant-locate-public-header-files-from-static-library-dependancyTurned out that setting my headers path to: "$(PROJECT_TEMP_DIR)/../UninstalledProducts/include" made it finally pr
阅读全文
摘要:solution:After further investigation we found that if you import a header file that in turn imports the same framework header file than the .pch already does, then CodeSense will break.link on stack overflow:http://stackoverflow.com/questions/2138047/xcode-code-loses-syntax-coloring
阅读全文
摘要:see:http://stackoverflow.com/questions/50467/how-do-i-size-a-uitextview-to-its-contentcode:CGRectframe=_textView.frame;frame.size.height=_textView.contentSize.height;_textView.frame=frame;note this line:One thing to note is that the correct contentSize is only availableafterthe UITextView has been a
阅读全文
摘要:apple developer library(chinese):http://www.apple.com.cn/developer/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/WindowsandViews/WindowsandViews.html#//apple_ref/doc/uid/TP40007072-CH8-SW4apple developer library(english,just property):http://developer.apple.com/library/ios/
阅读全文
摘要:[self.navigationBarsetBackgroundImage:[UIImageimageNamed:@"yourpngfile.png"]forBarMetrics:UIBarMetricsDefault];use this method;carefully : self.navigationBar may use in Subclass of UINavigationController,not self.navigationController.navigationBar
阅读全文
摘要:see this:http://c.gzl.name/archives/tag/uitableview
阅读全文
摘要:In UINavigation,back button is left-point shape style button.if you want to change the text and keep the style ,you can do this :use the navigation property : backBarButtonItemsee this (apple doc):https://developer.apple.com/library/ios/#documentation/UIKit/Reference/UINavigationItem_Class/Reference
阅读全文
摘要:copy "Reachability.h","Reachability.m" in your project directory. add "SystemConfiguration.farmework" in your build target. if you get some build error,read this link:http://stackoverflow.com/questions/10119239/adding-reachability-class-fails-when-i-am-trying-to-build
阅读全文
摘要:it takes me many time in this:when i use TTListDataSource for TTTableViewController ,i update the TTListDataSource and the TTTableViewController can't reload data,as that,you may use TTModel for dataSource(demo in three20,TTCatalog project)but the point is when you update reflesh the TTModel sub
阅读全文
摘要:#import "yourview.m";if you use this import operation,you will get this error:clang: error: linker command failed with exit code 1 (use -v to see invocation)use #import "yourview.h"; to fix it!
阅读全文
摘要:1.do this like this post:http://blog.csdn.net/i3039/article/details/69437922.if you are xcode4.3 and lion,you will get this error:"Error: No developer directory found at /Developer. Run /usr/bin/xcode-select to update the developer directory path."don't worry about this,go to this link
阅读全文
摘要:不知道是不是不用xib比较爽,但是,要记得的东西非常多,因为每个对象的方法为了可以自描述都非常长,在emacs上写实在锻炼大脑。极速写了一个navigationController的Demo先上地址.https://github.com/snowleung/navigation_ios然后是思路:声明一个UINavigationController1、在appDelegate这些文件中,会创建一个window这个window之上,可以写界面,window继承自view。2、-(BOOL)application:(UIApplication*)applicationdidFinishLaunch
阅读全文
摘要:job:挖坑。1、一个人挖一个坑要2hours.2、我要挖两个坑。从这里引出并行。objc中有dispatch object 来做多线程的事。这样,又可以看看关于dispatch的那些事。比如我要下载两个图片,就好像是上面的挖两个坑!代码如下 :dispatch_queue_tmyQueue=dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT,0);dispatch_async(myQueue,^{__blockUIImage*img=nil;dispatch_async(myQueue,^{NSLog(@"testin
阅读全文