iPhone - How to use #define in Universal app

Posted by Satyam svv on Stack Overflow See other posts from Stack Overflow or by Satyam svv
Published on 2010-12-27T16:52:28Z Indexed on 2010/12/27 17:53 UTC
Read the original article Hit count: 172

Filed under:
|

I'm creating universal app that runs oniphone and ipad. I'm using #define to create CGRect. And I want to use two different #define - one for iPhone and one for iPad. How can I declare them so that correct one will be picked by universal app..........

I think I've to update little more description to avoid confusion. I've a WPConstants.h file where I'm declaring all the #define as below

#define PUZZLE_TOPVIEW_RECT CGRectMake(0, 0, 480, 100)
#define PUZZLE_MIDDLEVIEW_RECT CGRectMake(0, 100, 480, 100)
#define PUZZLE_BOTTOMVIEW_RECT CGRectMake(0, 200, 480, 100)

The above ones are for iphone. Similarly for iPad I want to have different #define How can I proceed further?

© Stack Overflow or respective owner

Related posts about iphone

Related posts about universal-binary