Two parts to this question
1) Is this understanding of what's going on correct?
"if (obj)" is testing to see if the pointer is not 0x0, aka set to an integer memory address
"if (obj != nil)" is comparing the memory address of the object to the memory address of the universal nil object
2)
So in a situation where I don't know if a varia...
Hi All,
Programmatically I am creating buttons and keeping some background image using setBackgroundImage. I want to remove the set background image in the button after some time interval. I have timer code, which will call after particular interval. At this time, i want to remove the button background image in my program. I'm done with...
I've been working pretty extensively the last couple months with UIImagePickerController, particularly with the new capabilities in OS3.1 and newer to overlay views on-top of the camera view. This has worked just fine.
However, I am currently working on a project where I'd like to be able to display the camera view of the UIImagePickerC...
I am a bit confused about the objects which are initialized by type-casting. Like
UITextField *txtFld = (UITextField *)[self.view viewWithTag:someTag];
//
//
//some code here for this text field usage
//
//
now when I am finished using this text field should I set it to nil or leave it as it is for the system to take care of it.
Now ...
Hi all,
I often see when we release ab object we immediately set it to nil. I know that release and nil both free the old value associated with object but in case of release it leaves the object as a dangling pointer so we have to set it to nil.
So my question is if nil frees the old value of the object and set the object to nil why sh...
Hi,
I have taken this code from
http://stackoverflow.com/questions/883208/how-to-change-background-color-of-uialertview
UIAlertView *theAlert = [[[UIAlertView alloc] initWithTitle:@"Atention"
message: @"YOUR MESSAGE HERE", nil)
delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil] autorelease];
[theAlert show];
UI...
Hi!
I am about to publish my first free app on the appstore. Following the instruction on the developer portal, I have added an "Entitlements.plist" file, and referenced this file in the "code signing entitlements" project setting. After I did this I can no longer test the app on my Ipod, with this error message "Executable was signed w...
hi,
I want to have an image on left side of the cell.
A text also in same cell.
I should have a number of cells in a table.
Where should i store the images ? And how should I place in the table ?
Thank You.
...
We're creating an immersive app that needs to have something that acts rather similar to a UIAlertView, but we don't want it to look like a system dialog, we want to use our own graphics. I've got a big chunk of the work done, but there are a few snags I've hit:
How do I make the UIView show up above the status bar (so that I can dark...
I'm having some problems getting CoreAnimation to perform multiple animations in succession on the iPhone simulator. I have many layers in my application that I animate – these layers are all sublayers of the layer associated with a UIView in my application. After I animate the first sublayer's position (using explicit animation - CAKeyF...
I have an IBOutlet assigned in my header file named *myButton and is type UIButton class.
the purpose of myButton is to programmatically assign the alpha to multiple buttons.
it seems as if you can only assign myButton to one button in IB.
is there a way to assign an alpha value to multiple buttons at the same time or am i going to ha...
I'd like to know if it is possible to hide library implementation from consumers of a static library.
This great thread spawned a few questions in regards to a licensing system for static libraries: http://stackoverflow.com/questions/1739373/licensing-system-for-static-library. The scheme I'd like to use is:
Give consumer a license ...
How can I enable/disable navigationItem.rightBarButton item? I am calling the following code at -viewDidLoad but it does nothing.
self.navigationItem.rightBarButtonItem =
[[[UIBarButtonItem alloc]
initWithTitle:@"Flow"
style:UIBarButtonItemStyleDone
target:self action:@selector(flowWithMe:)] a...
Hello folks,
I approaching core animation and drawing empirically.
I am trying to animate a simple shape; the shape in question is formed by 3 lines plus a bezier curve. A red line is also drawn, to show the curve control points.
My main controller simply adds this subview and calls the adjustWave method whenever touchesEnd.
Here is t...
I have a query about the use of viewDidUnload and dealloc in a simple implementation of UITableViewController.
Essentially I'd like to know more about weather or not both viewDidUnload and dealloc are always called in succession in the tear down process. Is it possible that dealloc could be called on the controller without viewDidUnloa...
Hi,
I want to save the state of my view controller. I searched and found that I should save the state by saving state variables.
But I am interested in saving the view controller object itself. Is there any way to save the view controller object itself so that when I restart the application I see the same view state too on which I was ...
Objective-C: how do I convert NSMutableArray to NSArray?
...
Hello,
I have an application which uploads file from iPhone to web server.
Problem is that I want to give users a control like from which they can select the file / photo from the device and which is than uploaded on server.
Can anyone help me
...
Is it possible to display nearby businesses in mapkit? If not, how else can that be done?
Is there a way to display by category - restaurant, retail, museums?
Also, I don't think displaying traffic flow is available. Can anyone confirm?
...
Hi all
In IB, I set a view MyView with an UIToolBar and I drop an UISlider on it. IB automatically embeds it in an UIBarButtonItem and sets its view with the UISlider.
I display this MyView in a navigation controller with animation.
UIViewController *myVC = [[UIViewController alloc] initWithNibName:@"MyView" bundle:nil];
[self.navigat...