I'm sure this is an easy one, yet I need some pointing in the right direction. I have a rather complicated NIB that I would like to have only one view in that nib to listen for touch & multi-touch events. What is the best way of doing so using IBOutlets?
Thanks
...
I have a Core Animation running and want to pause it when a button is pressed. So there is a method -pauseAnimation. When the animation is paused, I want the animated view to stay in the state as it currently was while animating. i.e. if a view moves from top left to bottom right, and somewhere in the middle the animation is paused, the ...
i.e. %@ for strings, %f for doubles... I don't know the word for these placeholders but it would be great to have list for how to print booleans and other values.
...
Hi there,
I'm using Cocoa Touch to build an iPhone app.
I have an NSMutableArray called stories, that on printing to the console displays something like this:
2009-07-20 12:38:30.541 testapp[4797:20b] (
{
link = "http://www.testing.com";
message = "testing";
username = "test";
},
{
link = "http://www.testing2.c...
When you launch a video and IMMEDIATELY press "Done" the MPMoviePlayerController will exit, however the video still plays in the background (you can hear the audio). It works fine if you allow the video to begin playing before you hit the "Done" button.
Does anybody know a workaround for this?
...
This is for learning:
I have an UIView which is transparent and covers almost the whole screen. I left 50 pixels at the top. It is a child of the View Controller's view.
Underneeth the UIView there's MyView that inherits from UIView, which matches the screen size. And inside this MyView class, I ask for a touch on it very simple with...
I have never done any iPhone or iPod Touch development, much due to the additional need for a Mac to develop on, plus needing to learn Objective-C. With the announcement of MonoTouch now I can use .NET languages I am already familiar with, and develop on my Windows PC.
However I am curious if I will still need a Mac to deploy and test ...
I am currently using the following code in the AppDelegate to make a UIBarButtonItem act as a switch and adjusts a BOOL variable in the RootViewController Class:
- (void)applicationDidFinishLaunching:(UIApplication *)application {
...
toggleSwitch = [[UIBarButtonItem alloc] initWithTitle:@"English" style:UIBarButtonItemStylePlain ta...
Alright, I have a UIView which displays a CGPath which is rather wide. It can be scrolled within a UIScrollView horizontally. Right now, I have the view using a CATiledLayer, because it's more than 1024 pixels wide.
So my question is: is this efficient?
- (void) drawRect:(CGRect)rect {
CGContextRef g = UIGraphicsGetCurrentContext(...
Hi,
I'd like to capture user's swipe event for my iPhone application.
as per apple, It can be easily get it from touchesMoved:withEvent:.
I have UIView which contains navigationbar on the top, toolbar at bottom, in between it has uiwebView.
Now when user swipes i want to capture this event, but i am not able to get user's touch event...
Imagine an iPhone app, which starts with an standard UIView showing some buttons and stuff. Then there is a stats button, you tap it, and the UIView slides away. Instead an OpenGL ES view comes in, and shows a nice statistics curve.
I know you can mix OpenGL ES with UIView somehow but people say it's a bad idea. Does this also apply if...
For some reason Xcode tells me that it doesn't find symbols as soon as I use something like kCAFillModeForwards. There must be a library or class that I have to include...but which one? The normal Core Animation stuff works fine like [myView beginAnimations...]. What's the trick to get the more sophisticated animation stuff to work?
I'v...
Hi there,
I'm currently building an iPhone app that will display data from an NSMutableArray called "stories". The array structure looks like so (via NSLog):
2009-07-20 12:38:30.541 testapp[4797:20b] (
{
link = "http://www.testing.com";
message = "testing";
username = "test";
},
{
link = "http://www.testing...
Example:
1) fade an uiview from alpha 0.0 to 0.2
2) fade back to 0.15
3) fade to 0.25
4) fade to 0.2
5) fade to 0.35
6) fade to 0.3
7) fade to 0.45
8) fade to 0.4
... and so on. each with a duration of 0.05 sec. The effect is a flashy appearing view. Just for fun.
Previously I did this with simple UIView animation blocks, where every n...
I've seen this in a snippet:
animation.repeatCount = 1e100f;
my math classes are long time ago. So 1e100f would be a number with 100 zeros? So in this case the programer wanted to have infinite repeatCount?
...
what are the differences between implementating a @property with @dynamic or @synthesize??
thanks.
...
In my program I'm moving things based on rotation, but I'm not rotating the entire view. I'm Using :
static UIDeviceOrientation previousOrientation = UIDeviceOrientationPortrait;
- (void)applicationDidFinishLaunching:(UIApplication *)application {
[window addSubview:viewController.view];
[window makeKeyAndVisible];
[...
I'm currently enumerating through NSMutableArray (or NSMutableSet) elements to find duplicates and remove them.
For example, if array/set has values [@"a", @"b", @"b", @"c"], the end result should be [@"a", @"b", @"c"].
Since I'm comparing NSStrings, I'm using isEqualTo: method to check if strings are equal.
Is there a more efficient...
I have a simple iphone application that paints blocks using a subclass of CALayer and am trying to find the best way to save state or persist the currently created layers.
I tried using Brad Larson's answer from this previous question on storing custom objects in the NSUserDefaults, which worked for persisting my subclass of CALayer, bu...
I'm my program i'm loading a fairly large MutableDictionray and I would like to use a UIProgressBar. Does anyone have a suggestion of how to determine the loading time to make this work?
Thanks
...