iphone

UIWebView: Absolute path for images in app documents folder

I have a UIWebView that loads up some html. In it is an img tag, I am saving an image in the app documents folder and I want to display that image within the html, I do so like this NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory , NSUserDomainMask, YES); NSString *documentsDir = [paths objectAtIndex:0];...

does animateWithDuration:animations: block main thread?

I have connected the two methods below to separate buttons in my UI but have noticed that after pressing the "VERSION 1" button that I could not press the button again until the animation duration within the method had ended. My understanding was that the animation uses its own thread so as not to block the main application. // VERSION ...

Setting up itunes connect for indie developers

When filling in the info for the itunes connect for paid apps there are number of things they want filled in. contact info (which has a lot of different roles. e.g.finance, technical, legal) How should those be filled out for the individual? Are they all necessary or not? ...

how can I put all fetch requests in a Core Data DAL?

Totally new to Objective-C and Core Data, coming from a .net background I really want to put all of my fetch requests into some sort of class that I can call, preferably statically to get my objects, something like: ObjectType *myObject = [CoreDataDAL GetObject:ID]; Anyone have a pattern to implement this? I am hacking my way through ...

What are your CoreLocation best practices?

I am working on a CoreLocation based application wich should show the position of the user on a map. My current problem is, that the precision of CL is not very good. I am testing the app in an urban environment, so i am walking through a the streets around our office and see how precise it is. The horizontalAccuracy is usually around ...

app buttons fail on device

Egads, I'm completely perplexed! I have an iPhone app with keyboard input for a couple of fields. I've created a "giant invisible button" in the XIB to hide the keyboard after the user enters the data as well as a custom "done" button added to the numeric keyboard. If I "Build and Run" to the iPhone device in either debug or release c...

Core Data memory management

Just want to make sure I'm doing right things with memory management of Core Data. In my view controller's (which is tab bar view) viewDidLoad I use NSFetchRequest to retrieve the rows I need. Then I retain returned NSArray object, since I need to wait for user interaction to show the part of this data. In viewDidUnload I release that a...

Property Declaration and Automatic Backing Storage Allocation

I'm trying to understand Objective-C properties and I have some lingering questions about their syntax. What is the difference between explicitly declaring an ivar for a property like this: @interface myObject1 : NSObject { NSString *title; } @property (copy) NSString *title; @end and this: @interface myObject2 : NSObject { } @pro...

Fast undo facility for bitmap editor application

I'm trying to make a bitmap editor app for the iphone which would be similar to Brushes or Layers or a cut-down version of Photoshop. I'd like to be able to support 1000x1000 resolution images with about 4 layers if possible. I'm trying to design my undo/redo system before I write too much code and I'm having real issues coming up with ...

iPhone Grouped table end caps.

I'm currently working on an application in which I'm using grouped UITableViews. The design calls for a gradient background when the cells are in a selected state. I've achieved this by using an image that was created with the proper gradient. This works perfectly when it's in the middle cells however, when it's the top and bottom cel...

building and installing ipad/iphone app privately (dev license question)

I am creating an iPad app. I do not yet have the $99 dev license but I understand I will need this to actually put my app on the device rather than just the sim. I want to install the app on a bunch of devices but I do not want to put it in the app store or go through the approval process(which I am assuming is in order to submit for the...

The correct file location to store a plist on device.

What is the correct filepath to store a plist on the device. I read this in a tutorial which will work for the computer, would like to know the file location for the device. // write xml representation of dictionary to a file [dictionary writeToFile:@"/Users/henrik/Sites/foo.plist" atomically:NO]; I currently try to write to the f...

IPHONE - groups and folders

I have a folder structure that I would like to have in my bundle. If I create groups on Xcode and drag files to them, these groups are not real folders and the files will be all placed at the same place. Then I tried dragging the folders from finder directly to the project on Xcode. This time, folders were created inside the project s...

CGImageRef to UIImage rotates my photos debugging on a iOS 4 in simulator or device.

I have a problem with some simple code. The photo's, either picked or taken with the camera, are rotated. At first I thought it was a setting in the UIView but it happens when I copy the passed in UIImage to another UIImage using CGImageRef. I did it this way as it was the easiest way to ensure I was using a copy. Correct this code i...

run https request in phone gap

Hi folks, i am developing phone-gap app in iphone and i want to access https (json)request using JQuery.getJSON(url,function),but only in application it does not return any thing but in normal mobile safari it works fine ,though it is working fine as http request in phone-gap app,but i want to work it as https for security reason,please ...

iPhone (iOS): copying files from main bundle to documents folder causes crash

Hi, I am trying to set up my application so that on first launch, a series of files located in the "Populator" folder in the main bundle are copied into the documents directory. My current implementation is as follows: - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { NSS...

How do I implement a login screen that uses TableView for an iphone application

Hi, I want to use a TableView for representing a Username/Password textfields dialog in a nice and grouped view. I figured the best case is to use the TableView and two cells for this. I kind of got lost in the implementation... Is there any built in cells for this that I am missing? ...

iPhone in app purchase to credits to real life prize?

I want to make an app that is free to play but you would be able to purchase "credits" through apples in app purchase. When you use these "credits" and if you successfully complete a task you will then be able to get a prize mailed to you. Is this allowed by apple? ...

Core Text - CFAttributedStringRef - increasing font size

How can i make a new CFAttributedStringRef with increased font-size based on a CFAttributedStringRef i got? In my specific project i would like to dynamically increase the size. If i call CFAttributedStringSetAttribute(...) on the whole string using CTFontRef the string will lose it's formatting and the new will replace all the others ...

UISearchResultsController crashing on device (index beyond bounds for empty array)

I'm using UISearchResultsController to filter data from a fetchedResultsController. Here is the relevant code: In RootVieweController.h: @interface RootViewController : UITableViewController <NSFetchedResultsControllerDelegate, AdditionViewControllerDelegate, UISearchBarDelegate, UISearchDisplayDelegate> { NSArray *filteredListCo...