Results 1 to 3 of 3
Discuss SDK Issues at the iPhone Developer Exchange - Hackint0sh.org; hello everyone. i am having some issues but i want to check they are coding ...
  1. #1
    Newbie Array

    Join Date
    Mar 2008
    Posts
    6
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default SDK Issues

    hello everyone.
    i am having some issues but i want to check they are coding issues by me and not SDK issues..
    fist i have a 2.0 i phone
    using the toolchain as described for 1.2/2.0

    i am getting a huge build issue

    code follows:

    // Set up the window and content view
    CGRect screenRect = [[UIScreen mainScreen] bounds];
    self.window = [[[UIWindow alloc] initWithFrame:screenRect] autorelease];

    // Add the image as the background view
    UIImageView *anImageView = [[UIImageView alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]];
    anImageView.image = [UIImage imageNamed:@"MyBackground.png"];
    self.contentView = anImageView;
    [anImageView release];
    [self.window addSubview: self.contentView];

    // Show the window
    [self.window makeKeyAndVisible];

    im getting errors for UIScreen and a few other is this because they are not supported or what?
    Last edited by cbecking; 04-22-2008 at 07:18 PM.



  2. #2
    Developer Array javacom's Avatar

    Join Date
    Mar 2008
    Posts
    304
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    28

    Default

    There is no UIScreen in open tool chain
    use this instead

    Code:
    CGRect screenRect =  [ UIHardware fullScreenApplicationContentRect ];

  3. #3
    Newbie Array

    Join Date
    Mar 2008
    Posts
    6
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    so the code would be

    //new code
    CGRect screenRect = [ UIHardware fullScreenApplicationContentRect ];
    self.window = [[[UIWindow alloc] initWithFrame:screenRect] autorelease];

    // Add the image as the background view
    UIImageView *anImageView = [[UIImageView alloc] initWithFrame:[[UIHardware mainScreen] applicationFrame]];
    anImageView.image = [UIImage imageNamed:@"MyBackground.png"];
    self.contentView = anImageView;
    [anImageView release];
    [self.window addSubview: self.contentView];

    // Show the window
    [self.window makeKeyAndVisible];

    correct?

 

 

Similar Threads

  1. Replies: 0
    Last Post: 02-11-2011, 02:20 AM
  2. Replies: 0
    Last Post: 12-15-2010, 02:00 AM
  3. Replies: 0
    Last Post: 07-01-2010, 10:00 AM
  4. Replies: 0
    Last Post: 02-02-2010, 03:50 AM
  5. issues with 1.1.4
    By krayzie303 in forum General
    Replies: 0
    Last Post: 03-31-2008, 05:22 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Powered by vBulletin®
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
Search Engine Friendly URLs by vBSEO
(c) 2006-2012 Hackint0sh.org
All times are GMT +2. The time now is 06:53 AM.
twitter, follow us!