iphone-sdk-3.2

Load PDF into UIImage or UIImageView?

一曲冷凌霜 提交于 2020-06-12 03:33:36
问题 This is my first ever question on stackoverflow. I'm trying to load a PDF file stored in Resources into a UIImage/UIImageView object in the iPhone SDK. Is this at all possible without converting the PDF to an image? If not, what are the member functions for converting a PDF into a PNG? I would really prefer to preserve the PDF if at all pssoible. Thanks so much for the help! 回答1: PDFs can be loaded by UIWebView. If you need more control you can use Quartz 2D to render PDFs: Quartz2D 回答2: Now

Setting The Wallpaper On An IPad

可紊 提交于 2020-01-09 12:03:28
问题 I think there is no way to set the lock screen wallpaper on the iPhone programmatically (with ref to this question), but with the 3.2 SDK and the ability to set the wallpaper on the home screen on the iPad, does the SDK allow this to be done via APIs now? I looked up the developer reference, but i could not find anything useful. 回答1: I don't think there's a method for that. The user can change it in the settings. But if you could change it progmatically, I'm sure there would be a lot of

UIKeyboardBoundsUserInfoKey is deprecated, what to use instead?

点点圈 提交于 2019-12-28 03:17:26
问题 I'm working on an iPad app using 3.2 sdk. I'm dealing with obtaining the keyboard size to prevent my textfields from hidding behind it. I'm getting a Warning in Xcode -> UIKeyboardBoundsUserInfoKey is deprecated what should I use instead not to get this warning? 回答1: I played with the previously offered solution but still had issues. Here's what I came up with instead: - (void)keyboardWillShow:(NSNotification *)aNotification { [self moveTextViewForKeyboard:aNotification up:YES]; } - (void

isEqual doesn't always work for NSIndexPath? What can I use in its place?

梦想与她 提交于 2019-12-20 09:48:09
问题 I've got some code that relies on comparing two NSIndexPaths and executing different code based on their equality or lack thereof (using -isEqual). Most of the time it works properly, but sometimes it doesn't. I've used the debugger console to test the two indexpaths during code execution, and they look identical to me. Here's the code: - (BOOL)selectedStreetIsSameAsLastSelectedStreet { return [self.indexPathOfSelectedStreet isEqual:self.previousObject.indexPathOfSelectedStreet]; } Here's the

Adding video to an iPhone application

非 Y 不嫁゛ 提交于 2019-12-19 12:21:35
问题 How do I add a video to an iPhone app. using iPhone SDK 3.2.5? I dont see the actual video but I can hear it playing. Here is the code: -(void) viewDidLoad{ NSBundle *bundle=[NSBundle mainBundle]; NSString *moviePath = [bundle pathForResource:@"Facebook" ofType:@"mp4"]; NSURL *movieURL=[[NSURL fileURLWithPath:moviePath] retain]; MPMoviePlayerController *theMovie = [[MPMoviePlayerController alloc] initWithContentURL:movieURL]; theMovie.scalingMode = MPMovieScalingModeAspectFill; [theMovie play

Receive message “A signed resource has been added, modified, or deleted” when trying to debug an App on iPhone

微笑、不失礼 提交于 2019-12-17 09:08:31
问题 While attempting to debug a build created using the 3.2 SDK on an iPhone device I receive the message "A signed resource has been added, modified, or deleted.". I can clean, rebuild, then install with no error, but if I try to install without cleaning the error shows. Anyone have an idea as to what might be causing this? 回答1: I found a workaround for the bug. If you delete the .app file in build/Debug-iphoneos/ before building for the device, the app gets installed without errors. And there

ASIHttpRequest problems. “unrecognized selector sent to instance”

南楼画角 提交于 2019-12-11 15:29:50
问题 I am experiencing problems using ASIHttpRequst. This is the error I get: 2010-04-11 20:47:08.176 citybikesPlus[5885:207] *** -[CALayer rackDone:]: unrecognized selector sent to instance 0x464a890 2010-04-11 20:47:08.176 citybikesPlus[5885:207] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[CALayer rackDone:]: unrecognized selector sent to instance 0x464a890' 2010-04-11 20:47:08.176 citybikesPlus[5885:207] Stack: ( 33936475, 2546353417, 34318395,

Use twitter ios sdk oAuth

微笑、不失礼 提交于 2019-12-11 07:08:48
问题 I try to use MGTwitterEngine for twitter Iphone integration, this is supporting both xAuth and oAuth as per its documentation and firstly I try it using xAuth as which function I am calling named getXAuthAccessTokenForUsername But my application is in developing stage .. and twitter not approving it .. they will approve it after release... I am not able to use oAuth using MGTwitterEngine Can anybody help me... Even I am not able to use oAuth version from source http://mobile.tutsplus.com

Tapku calendar Add Events

可紊 提交于 2019-12-10 23:29:09
问题 I am using Tapku library in my app. It works fine for me.. but my point is How can I add different Images on different Events on Calendar. Thanks In Advance 回答1: You can open the bundle of tapku library which contains images and you can replace the images. 回答2: The images are found at: " TapkuLibrary.bundle/Images/calendar/Month Calendar Today " or you could make the path point to one of your own images. self.selectedImageView.image = [UIImage imageWithContentsOfFile:TKBUNDLE(@"TapkuLibrary

iPhone development: what will [[UIDevice currentDevice] model] return for “iPad”? [closed]

ε祈祈猫儿з 提交于 2019-12-09 13:54:15
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 5 years ago . What will [[UIDevice currentDevice] model] return for "iPad"? 回答1: You can use UI_USER_INTERFACE_IDIOM() , which will either return UIUserInterfaceIdiomPhone or UIUserInterfaceIdiomPad . Bear in mind that on any device < 3.2, this is unavailable, so first check to see whether the property can be retrieved - in