hi, im developing a 2d game on iphone in which i want to maginify the views on the screen to give the effect that the user is looking through the sniper whenever the user taps the screen..
i am required to show that the objects which the player wants to shoot should be moving...so im incremeting their position as well as increasing their...
All of the examples I've seen on here and other sites involved creating a UIActivityIndicatorView and loading it with something like:
self.navigationItem.rightBarButtonItem = [[[UIBarButtonItem alloc]
initWithCustomView:myActivityIndicatorView
target:nil
action:nil]
autorelease];
However, tha...
I'm developing for the iPhone and am looking for a good Cocoa/Objective-C library for working with SQLite. I don't want to use the standard procedural SQLite C API. I see options at sqlite.org under the Objective-C section, but am not sure which is the best in terms of library API design, stability, and functionality. I'd like to use ...
I am trying to work my way through basic iPhone programming and I have a good basic understanding of how Interface Builder works, so I decided to try my hand at doing the views programmatically. I have gone through the ViewController Apple guide and searched everywhere and I cannot seem to find a solution to my problem. This leads me t...
Hi,
I have been programming with the iPhone SDK for some time now.
I have not been using Interface Builder. This scares me a little. I know that in effect I may be 'fighting the framework' but I do not see it that way.
I find it very easy to just instantiate my UITabBarController in my app delegate, instantiate a UINavigationControl...
I'm doing this in dealloc of a view
[baseTable release];
In the header file, I declare it like this:
IBOutlet UITableView *baseTable;
....
@property(nonatomic, retain) UITableView *baseTable;
For some reason, I get a "EXC_BAD _ACCESS" in the dealloc. When I comment out the above line, all is well. How can I determine what specifi...
I've developed an iPhone application that plays Sound.
However, when I play a sound in the simulator, the console shows the lines below (also shown in this screenshot).
[12:07:07.505 <0xb0185000>] could not find audio decoder component 64766938 for registration
[12:07:07.506 <0xb0185000>] could not find audio decoder component 6D7300...
I've got a simple "model" class like so (complete with constructor of course)
@implementation Widget
@synthesize name;
@synthesize color;
- (id) init
{
if (self = [super init])
{
self.name = @"Default Name";
self.color = @"brown";
}
return self;
}
@end
I've declared it as an internal member to my controlle...
This seems like a basic question.. but my array size is 64 and I am replacing an object at index 63. Like this:
[myMutableArray replaceObjectAtIndex:myIndex withObject:myObj];
So I have no idea why gdb is telling me this:
*** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[NSCFArray objectAtIndex:]: index...
I'm getting a EXC_BAD _ACCESS after leaving the method below. At that point htmlDocument becomes invalid, which it should since it falls out of scope. But is that why I'm getting the error? By the time the contentView (UIWebView) loads, htmlDocument is gone. But doesn't contentView already have what it needs from loadHTMLString?
- (...
We're writing an application that's in landscape mode exclusively. We use a transform on a root view to rotate it to LandscapeRight, then every view that gets loaded by that view shares the coordinate system. That's all fine and dandy, except one of our views has a UIWebView object that's being loaded by a view controller. The site that ...
Hello.
I'm basically trying to duplicate the behavior of the iPod app on the iPhone, where when you select a song, the music player view slides in, and the navigation bar transitions to a new color.
My app is set up as a tabbed based application, with UITabBarController and a nested UINavigationController in each tab. Inside each UINav...
I need to know about the usage of delegate methods in objective c...
Can anyone point me to the correct source...
...
I have 2 UIImageViews, IMG1 and IMG2 . Somesomes I want IMG1 to appear above IMG2 , and at other times I want IMG2 to appear above IMG1. How do I do this ?
...
I have some calculation that involves negative values:
row = (stagePosition - col) / PHNumRow;
Say stagePosition is -7 and col is 1. They are both NSInteger, including row.
PHNumRow is 8.
If PHNumRow is NSInteger, I get the result I expect: -1.
But if PHNumRow is NSUInteger, the result is garbage.
Why should it matter if the divisor...
I have a custom UIViewController and custom UIView. I'd like to override the viewcontroller.view property to return MyCustomUIView.
Right now I have:
@interface MyViewController : UIViewController {
IBOutlet MyView* view;
}
@property (nonatomic, retain) IBOutlet MyView* view;
This compiles but I get a warning: property 'vi...
I'm building a table with some text that is HTML, so I am using a UIWebView as a subview of my custom table cells. I already ran into one problem - as I scrolled down in the table, it would take the UIWebViews a second to update. For example, I'd be viewing Cells at rows numbered 1, 2, and 3. I'd scroll down to say 8, 9, and 10. For a mo...
I'm trying to get multiple levels of hierarchy working
with Navigation Controllers. I have 3 levels of hierarchy and
I can move down through the levels of hierarchy, but I can
only go back one level and not two levels, back to the starting
view.
I start by creating a navigation controller for View #1 and push the next
view, View #2, o...
I have a date string (well, NSData, but that's easy to convert to a string) that's in what I believe is the format the HTTP standard uses:
Mon Apr 17 19:34:46 UTC 2006
Is there any better (i.e. less error-prone) way to parse that than specifying the format string by hand in an NSDateFormatter?
(My application is an iPhone app, but I ...
I am simply loading a plist into a temporary dictionary for initializing my data model. Unfortunately this single line of code below results in consistent leak throughout the app life cycle as per Instruments. The leaked objects being NSCFString and GeneralBlock on a Malloc and the responsible library being Foundations.
My two questions...