Search Results

Search found 8409 results on 337 pages for 'itunes sdk'.

Page 156/337 | < Previous Page | 152 153 154 155 156 157 158 159 160 161 162 163  | Next Page >

  • uniimageview not updating after views tranistion

    - by Fabio Ricci
    Hi I have one main view where I display an image, in the method viewDidLoad: ballRect = CGRectMake(posBallX, 144, 32.0f, 32.0f); theBall = [[UIImageView alloc] initWithFrame:ballRect]; [theBall setImage:[UIImage imageNamed:@"ball.png"]]; [self.view addSubview:theBall]; [laPalla release]; Obviously, the value of posBallX is defined and then update via a custom method call many times in the same class. theBall.frame = CGRectMake(posBallX, 144, 32, 32); Everything works, but when I go to another view with [self presentModalViewController:viewTwo animated:YES]; and come back with [self presentModalViewController:viewOne animated:YES]; the image is displayed correctly after the method viewDidLoad is called (I retrieve the values with NSUserDefaults) but no more in the second method. In the NSLog I can even see the new posBallX updating correctly, but the Image is simply no more shown... The same happens with a Label as well, which should print the value of posBallX. So, things are just not working if I come back to the viewOne from the viewTwo... Any idea??????? Thanks so much!

    Read the article

  • Automatically determining the size of a UITableViewCell

    - by hanno
    I am trying to determine the size of a UITableCellView. The reason being that I am using one class for different orientations and devices. The cell contains one subview that is supposed to fill the entire cell. Right know I'm doing this in the UITableViewCell's init method: if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad){ //iPad subv = [[OrbitView alloc] initWithFrame:CGRectMake(52, 5, 660, 420) ]; }else{ //iPhone subv = [[OrbitView alloc] initWithFrame:CGRectMake(15, 5, 290, 200) ]; } Clearly, there must be a better way of doing this, without the magic numbers. How/Where should I set the frame of the subview in the UITableViewCell so that it fills the entire UITableViewCell?

    Read the article

  • How simplify iPhone localization?

    - by mamcx
    I need to localiza a in development app for English & Spanish. Despite the fact I follow the Apple way of use NSLocalizedString & create nibs for both, I already lost the track of the new string that need to get localized and found with surprise that I need to redo the nibs in spanish when I change the master. (Just like this http://www.gigliwood.com/weblog/Cocoa/A_Great_Need_for_Be.html) I wonder if exist a better/alternative/more automated way. I know the use of gettext & poedit and wonder if something like that can be used. Or if exist some script or tool for this.

    Read the article

  • Best point to overwrite the navigationBar property of navigationController

    - by flohei
    Hi there, I'm overwriting UINavigationController to replace the default navigationBar property with an instance of my own subclass of UINavigationBar. So I tried something like _navigationBar = [[SBNavigationBar alloc] init]; in my -initWithRootViewController:. But that didn't work out as I expected it. There's still the default navigationBar being displayed. So what's the best point to overwrite the navigationBar? Thanks in advance –f

    Read the article

  • How to add a leftBarButtonItem to ABPeoplePickerNavigationController?

    - by al_lea
    Tried this, but doesn't work: ABPeoplePickerNavigationController * people_picker = [[ABPeoplePickerNavigationController alloc] init]; people_picker.peoplePickerDelegate = self; self.navigationController.navigationItem.leftBarButtonItem = [[[UIBarButtonItem alloc] initWithTitle: @"send" style: self.navigationController.navigationItem.rightBarButtonItem.style target: self action: @selector(cancelAddressBook)] autorelease]; [self.navigationController presentModalViewController: people_picker animated: YES];

    Read the article

  • Application crashing in the iPad but working fine in iPad simulator.

    - by srikanth rongali
    Hi, I am writing a game in cocos2d. In the iPad Simulator the application is running good. While I am running the application in the iPad. But it was crashing by giving the following message in terminal. I am using 2048x2048 CCSpriteSheets in my code. I used instruments tool there is sudden increase in memory to 32MB before crashing. It is crashing at CCSpriteFrameCache . Program loaded. target remote-mobile /tmp/.XcodeGDBRemote-6258-64 Switching to remote-macosx protocol mem 0x1000 0x3fffffff cache mem 0x40000000 0xffffffff none mem 0x00000000 0x0fff none continue The program is not being run. The program is not being run. Thank you.

    Read the article

  • hiding network activity indicator

    - by iSharreth
    - (void)viewWillAppear:(BOOL)animated { app = [UIApplication sharedApplication]; app.networkActivityIndicatorVisible = YES; NSURL *url = [NSURL URLWithString:@"http://www.google.com"]; NSURLRequest *request = [NSURLRequest requestWithURL:url]; [webView loadRequest:request]; } -(void)webViewDidFinishLoad { app.networkActivityIndicatorVisible = NO; } I want to hide the network activity indicator after webpage is loaded. I had written the above code. But the indicator is not hiding after the webpage is fully loaded. Anyone please help.

    Read the article

  • Parsing mutiple xml files in android

    - by cppdev
    Hi, I ma writing an application where I have to parse multiple xml files as a response from a server. Till now, I have written different xml parser classes for each xml depepending on the tags present in different xmls ? Can I combine all xml parser classes and write a single xml parser that handles all different tags in different xmls ? Will it work ? Will combining xml parser classes add an overhead because xml parser will check for every tag irrespective of whether that is part of file or not ? Please help.

    Read the article

  • Out-Of-Memory while doing Core Data migration

    - by Kamchatka
    Hello, I'm migrating a CoreData model between two versions of an application. I was storing binary data as blobs in the previous version and I want to take them out of the blobs for performance. My issue is that during the migration it seems that Core Data loads everything into memory which leads to Low Memory Warnings and then to my app being killed. Apple documentation suggests the following : http://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/CoreDataVersioning/Articles/vmCustomizingTheProcess.html#//apple_ref/doc/uid/TP40005510-SW9 However, it seems to rely on the fact that the large objects are applied different mapping. In my case, all the objects are basically the same and the same mapping has to be applied to each of them. I don't see in this case how I could apply their technique. How should I handle a migration with very large objects ?

    Read the article

  • Retrieving NSDate from NSString

    - by Olivier de Jonge
    I have an iPhone app. that is receiving data with IRFC 3339 timestamp format (e.g. @"2010-01-29T11:30:00.000+01:00"), as in GData. I want to convert the data to an NSDate NSDateFormatter *inputFormatter = [[[NSDateFormatter alloc] init] autorelease]; [inputFormatter setDateFormat:@"yyyy-MM-dd'T'HH:mm:ss.SSS"]; [currentEntry setStartTime:[inputFormatter dateFromString: ][currentEntry startTimeString]]]; But I'm missing out how to convert the last part of the string @"2010-01-29T11:30:00.000+01:00": the time offset. Anyone knows what I have to add to this String to take the time offset in account too?

    Read the article

  • Playing video and audio in iPhone not working...

    - by Scott
    So we have buttons linked up to display images/videos/audio on click depending on a check we do earlier. That part works fine. It knows which one to play, however, when we click the buttons for video and audio, nothing happens. The image one works fine. The video and audio are being taken for a URL online, they are not local, but everywhere said this was still possible. Here is a little snippet of the code where we play the two files: if ( [fName hasSuffix:@".png"]) { NSLog(@"PICTURE"); NSURL *url = [NSURL URLWithString: fName]; UIImage *image = [UIImage imageWithData: [NSData dataWithContentsOfURL:url]]; self.view = [[UIView alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]]; // self.view.backgroundColor = [[UIColor alloc] initWithPatternImage:[UIImage imageNamed:@"MainBG.jpg"]]; [self.view addSubview:[[UIImageView alloc] initWithImage:image]]; } if ( [fName hasSuffix:@".mp4"]) { NSLog(@"VIDEO"); //NSString *path = [[NSBundle mainBundle] pathForResource:fName ofType:@"mp4"]; //NSLog(path); NSURL *url = [NSURL fileURLWithPath:fName]; MPMoviePlayerController *player = [[MPMoviePlayerController alloc] initWithContentURL:url]; [player play]; } if ( [fName hasSuffix:@".mp3"]) { NSLog(@"AUDIO"); NSURL *url = [NSURL fileURLWithPath:fName]; NSData *soundData = [NSData dataWithContentsOfURL:url]; AVAudioPlayer *avPlayer = [[AVAudioPlayer alloc] initWithData:soundData error: nil]; [avPlayer play]; } See anything wrong? By the way it compiles and runs, but nothing happens when we hit the button that executes that code.

    Read the article

  • How to avoid piracy in iPhone apps by server side validation?

    - by prathumca
    As par my app requirement, there is a couple of scenarios that I need to handle. Scenario 1: To avoid piracy, I want to include some piece of code, whose job is sending both IMEI and Serial number of IPhone. Scenario 2: At server side, I've a database, which has a list of both IMEI and Serial No info. Here I wanna validate both IMEI and Serial numbers. If both are not matched then I can make sure that the app is pirated. Idea seems good. But I don't know how to handle these two scenarios in my app. Any help is greatly appreciated.

    Read the article

  • how to add svn repository for an iphone application

    - by ratnasomu
    hellow all i am using svn for version control for an iphone application . i have created it from xcode repositories by giving url ,user name and password its authenticated .After that i have created a directory from there itself and have imported my project there. Then i have checked out to the local directory and have updated something in it. Click on commit changes. It done. After that i came to terminal to commit the project first time from terminal .There i have removed the build of the project then gave a command like "svn update". here i am getting error like svn: PROPFIND request failed on '/svn/pacman/GameDevelopment/Game'and 403 Forbidden error whts going wrong here? could any one help me in this ? Thanks..

    Read the article

  • iPhone: Error when using -(id)initWithNibName

    - by Nic Hubbard
    I am trying to use the following code, but I always get an error that I can find little information about: - (id)initWithNibName:@"MyRidesListView" bundle:nil { if ((self = [super initWithNibName:@"MyRidesListView" bundle:nil])) { // Custom initialization } return self; } Error: expected identifier before 'OBJC_STRING' token This seems like a simple method to be calling. This is for a UINavigationController. Ideas?

    Read the article

  • facebook .net and mvc - Unrecognized attribute 'ApiKey'. Note that attribute names are case-sensitive

    - by vondip
    Hi all, I'm trying to build a small fb application using asp.net mvc 2, and facebook C# .net From some reason, the code from the sample application doesn't seem to work for me. Here's the exception I am receiving from my web.config file. Unrecognized attribute 'apiKey'. Note that attribute names are case-sensitive. Source Error: <facebookSettings apiKey="XXXX" apiSecret="XXXX" appId="XXXX" /> Any ideas?

    Read the article

  • Using the contents of an array to set individual pixels in a Quartz bitmap context

    - by Magic Bullet Dave
    I have an array that contains the RGB colour values for each pixel in a 320 x 180 display. I would like to be able to set individual pixel values in the a bitmap context of the same size offscreen then display the bitmap context in a view. It appears that I have to create 1x1 rects and either put a stroke on them or a line of length 1 at the point in question. Is that correct? I'm looking for a very efficient way of getting the array data onto the graphics context as you can imagine this is going to be an image buffer that cycles at 25 frames per second and drawing in this way seems inefficient. I guess the other question is should I use OPENGL ES instead? Thoughts/best practice would be much appreciated. Regards Dave OK, have come a short way, but can't make the final hurdle and I am not sure why this isn't working: - (void) displayContentsOfArray1UsingBitmap: (CGContextRef)context { long bitmapData[WIDTH * HEIGHT]; // Build bitmap int i, j, h; for (i = 0; i < WIDTH; i++) { for (j = 0; j < HEIGHT; j++) { h = frameBuffer01[i][j]; bitmapData[i * j] = h; } } // Blit the bitmap to the context CGDataProviderRef providerRef = CGDataProviderCreateWithData(NULL, bitmapData,4 * WIDTH * HEIGHT, NULL); CGColorSpaceRef colorSpaceRef = CGColorSpaceCreateDeviceRGB(); CGImageRef imageRef = CGImageCreate(WIDTH, HEIGHT, 8, 32, WIDTH * 4, colorSpaceRef, kCGImageAlphaFirst, providerRef, NULL, YES, kCGRenderingIntentDefault); CGContextDrawImage(context, CGRectMake(0.0, HEIGHT, WIDTH, HEIGHT), imageRef); CGImageRelease(imageRef); CGColorSpaceRelease(colorSpaceRef); CGDataProviderRelease(providerRef); }

    Read the article

  • Android WVGA800 and 854

    - by Droidy
    Although my relativelayout looks very similar on WVGA800 and WVGA854 on the emulator, theres different spacing on some of the objects because I'm going off of marginleft or marginright. Since the 854 is a greater width, its pushing some objects differently. Is there any way I could target either one to adjust for the different margins?

    Read the article

  • Good way to cache data during Android application lifecycle?

    - by sniurkst
    Hello, keeping my question short, I have creating application with 3 activities, where A - list of categories, B - list of items, C - single item. Data displayed in B and C is parsed from online XML. But, if I go trough A - B1 - C, then back to A and then back to B1 I would like to have it's data cached somewhere so I wouldn't have to request XML again. I'm new to Android and Java programming, I've googled a lot and still can't find (or simply do not have an idea where to look) a way to do what I want. Would storing all received data in main activity A (HashMaps? ContentProviders?) and then passing to B and C (if they get same request that was before) be a good idea?

    Read the article

< Previous Page | 152 153 154 155 156 157 158 159 160 161 162 163  | Next Page >