iphone

Creating my own bundle in xCode, for iPhone application

Hello everyone! I am having some difficulty creating a bundle for my application, and placing files in the bundle. For example, Facebook has developed a bundle for iPhone applications using their framework. In the same way, I also want to create a bundle which can be reused for many applications. My questions are: what steps should ...

UITableView crashes when trying to scroll

Hi, I have a problem with data in UITableView. I have UIViewController, that contains UITableView outlet and few more things I am using and ... It works :) ... it works lovely, but ... I've created an RSS reader class that is using delegates to deploy the data to the table ... and once again, If I'll just create dummy data in the main ...

Determining credit/debit card type

Hi, I'm writing a POS application for the iPhone/iPod combination, using the same exact hardware used in Apple Stores:: EasyPay. Ok, my hurdle is this: how do I identify which credit card type is being used as text is entered in the uitextfield? I assume I've to use textField:shouldChangeCharactersInRange:replacementString:? However, I...

Transparent Background with a Modal UIViewController

I have a dilema, I want to present to the user a semi-transparent view. I found out by experimenting that if I simply pushed the transparent view to the top of my NavigationController's stack, that it would not render the transparency level I wanted. So I decided to simply add the view as a subview of the current view at the top of the ...

How to Display GIF Image on iPhone UIIMageView

i have found some ways but they are actually reading frames and applying transition which reduces the quality of animation.. is there any way to display GIF on iPHone application as it is..? Thanks in Advance.. ...

My presentation layer does not match my model layer even though I have no animations

On iPhone I have a CALayer that I animate via Core Animation. Then at some point I change view controllers. I then return to the view controller with the CALayer and in viewWillAppear: I set the frame and position properties on my layer to move it back to its starting point. Setting these properties changes the model layer but the pre...

Shake Gesture detection in UIWindow subclass

I setup a UIWindow subclass as detailed in an answer from this post: http://stackoverflow.com/questions/150446/how-do-i-detect-when-someone-shakes-an-iphone/1351486#1351486 I am running into an issue where only the methods motionBegan: and motionCancelled: will fire. I need to detect the motionEnded: method, and whatever I do it simply ...

Which way to store this data is effective?

I am writing a game, which need a map, and I want to store the map. The first thing I can think of, is using a 2D-array. But the problem is what data should I store in the 2D-array. The player can tap different place to have different reaction. So, I am thinking store a 2D-array with objects, when player click some position, and I find i...

Rotate image in Quartz? Image is upside down! (iPhone)

I don't want to transform the ENTIRE context. I'm making a game with Quartz, and I'm drawing my player with lines, rects and ellipses. And then I have diamong.png which I rendered at 0,0 in the top left of the screen. Problem is... It renders upside down! How would I rotate it 180 degrees? Here's some of my code: CGImageRef diam...

How do I make a UIAlertView happen only on the first start-up of an iPhone app?

I'm using the UIAlertView to make a pop-up happen once the app has started up. It works fine but I only want the pop up to happen on the first start-up of the app. At the moment I've got the UIAlertView in the AppDelegate class, after the application didFinishLaunching. Here is my code at the moment. - (BOOL)application:(UIApplication *...

Safari-style UIPopoverController from Toolbar

I'm creating an iPad application which needs a UIPopoverController like this one (I mean, with buttons): I tried using a UIViewController but it gives me an enormous popup with a white background. Can anyone explain me how to make one? I cannot find any documentation or example code. Thanks. ...

Conflit between AVAudioRecorder and AVAudioPlayer

Hi, here is my problem : The code (FooController) : NSString *path = [[NSBundle mainBundle] pathForResource:@"mySound" ofType:@"m4v"]; soundEffect = [[AVAudioPlayer alloc] initWithContentsOfURL:[NSURL fileURLWithPath:path] error:NULL]; [soundEffect play]; // MicBlow micBlow = [[MicBlowController alloc]init]; And MicB...

Using kAudioSessionProperty_OtherMixableAudioShouldDuck on iPhone

Hello, I'm trying to get consistant behavior out of the kAudioSessionProperty_OtherMixableAudioShouldDuck property on the iPhone to allow iPod music blending and I'm having trouble. At the start of my app I set an Ambient category like so: -(void) initialize { [[AVAudioSession sharedInstance] setCategory: AVAudioSessionCategoryAmbient...

iphone Json POST request to Django server creates QueryDict within QueryDict

I'm creating a JSON POST request from Objective C using the JSON library like so: NSMutableURLRequest *request; request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@/%@/", host, action]]]; [request setHTTPMethod:@"POST"]; [request setValue:@"application/json-rpc" forHTTPHeaderField:@"Content...

Re-ordering a collection of UIView's based on their CGPoint

Hi all, I have a NSMutableArray that holds a collection of UIViewControllers Amongst other properties and methods an instance of each of the viewControllers are placed in a parent view The user will place these objects individually when desired to. So essentially I use - (void)addSubview:(UIView *)view when a new view is added to th...

Adjusting table cells for navigation prompt

I have a tableview with a navigation bar at the top. I've added text to the prompt property of the navigation bar. This cuts the top half of the first tableview cell. Is there a way to tell the tableview that the prompt is present or do I need to roll something custom? ...

Editable table view cell

I am creating an application. I have to implement a bookmark feature, and adding one should be similar to this: I want editable UITableViewCells for text input. I was wondering if there is an easier way then embedding a UITextField into a UITableViewCell. And if not, can someone explain how I can use the UITextField inside it? Thanks ...

Can I avoid explicitly casting objects with a common subclass?

I have an iPodLibraryGroup object and Artist and Album both inherit from it. When it comes to my view controllers though I find that I'm duplicating lots of code, for example I have an ArtistListViewController and and AlbumListViewController even though they're both doing basically the same thing. The reason I've ended up duplicating t...

How to Create a use defined Event and send it ?

Hi, flocks, Is there anyone could help me ? i want to send a use defined event and get it in iphone. how to create a use defined event in iphone development? ...

Iphone SDK - tap to undo a zoom inside of a scroll view

Hi, I was just wondering how I can get a single tap to undo the zoom inside of a scroll view? I cant seem to figure it out. I was also wondering how do you know what size to set your scroll view contentSize, as I find this issue a little confusing at the moment I have it set at 460x320. Thanks ...