Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -(void)viewDidLoad
- {
- if (SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"7.0"))
- {
- [[UIApplication sharedApplication] setStatusBarStyle: UIStatusBarStyleDefault];
- // proven Predicitons Button Creation
- provenPredictButton=[UIButton buttonWithType:UIButtonTypeCustom];
- [provenPredictButton addTarget:self action:@selector(provenPredict) forControlEvents:UIControlEventTouchUpInside];
- [provenPredictButton setTitle:@"PROVEN PREDICTIONS" forState:UIControlStateNormal];
- provenPredictButton.titleLabel.textAlignment = NSLineBreakByWordWrapping;
- provenPredictButton.titleLabel.numberOfLines = 2;
- [provenPredictButton.titleLabel setTextAlignment: NSTextAlignmentCenter];
- [provenPredictButton setTitleEdgeInsets:UIEdgeInsetsMake(60, 10, 10, 10)];
- [provenPredictButton.titleLabel setFont:[UIFont systemFontOfSize:14.0]];
- provenPredictButton.frame=CGRectMake(10, 380, 140, 120);
- provenPredictButton.layer.cornerRadius=5;
- provenPredictButton.backgroundColor=[UIColor colorWithRed:246.0f/255.0f green:83.0f/255.0f blue:50.0f/255.0f alpha:1.0];
- [self.view addSubview:provenPredictButton];
- provenPredictImage=[[UIImageView alloc]initWithFrame:CGRectMake(45, 10, 48, 48)];
- provenPredictImage.image=[UIImage imageNamed:@"48*48.png"];
- [provenPredictButton addSubview:provenPredictImage];
- provenPredictButton.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin |UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin;
- // Future Predictions
- futurePredictionsButton=[UIButton buttonWithType:UIButtonTypeCustom];
- [futurePredictionsButton addTarget:self action:@selector(futurePredictions) forControlEvents:UIControlEventTouchUpInside];
- [futurePredictionsButton setTitle:@"FUTURE PREDICTIONS" forState:UIControlStateNormal];
- futurePredictionsButton.titleLabel.textAlignment = NSLineBreakByWordWrapping;
- futurePredictionsButton.titleLabel.numberOfLines = 2;
- [futurePredictionsButton.titleLabel setTextAlignment: NSTextAlignmentCenter];
- [futurePredictionsButton.titleLabel setTextAlignment: NSTextAlignmentCenter];
- [futurePredictionsButton setTitleEdgeInsets:UIEdgeInsetsMake(60, 10, 10, 10)];
- [futurePredictionsButton.titleLabel setFont:[UIFont systemFontOfSize:14.0]];
- futurePredictionsButton.frame=CGRectMake(160, 380, 140, 120);
- futurePredictionsButton.layer.cornerRadius=5;
- futurePredictionsButton.backgroundColor=[UIColor colorWithRed:114.0f/255.0f green:188.0f/255.0f blue:7.0f/255.0f alpha:1.0];
- [self.view addSubview:futurePredictionsButton];
- futurePredictionsImage=[[UIImageView alloc]initWithFrame:CGRectMake(45, 10, 48, 48)];
- futurePredictionsImage.image=[UIImage imageNamed:@"futureicon48.png"];
- [futurePredictionsButton addSubview:futurePredictionsImage];
- futurePredictionsImage.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin |UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin;
- ADBannerView *adView = [[ADBannerView alloc] initWithFrame:CGRectZero];
- // adView.currentContentSizeIdentifier = ADBannerContentSizeIdentifierPortrait;
- adView.frame=CGRectMake(0, 580, 320, 40);
- adView.delegate=self;
- // adView.backgroundColor=[UIColor brownColor];
- adView.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin |UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin;
- }
- else
- {
- // create Panchamgam patanam
- provenPredictButton=[UIButton buttonWithType:UIButtonTypeCustom];
- [provenPredictButton addTarget:self action:@selector(provenPredict) forControlEvents:UIControlEventTouchUpInside];
- [provenPredictButton setTitle:@"PROVEN PREDICTIONS" forState:UIControlStateNormal];
- provenPredictButton.titleLabel.textAlignment = NSLineBreakByWordWrapping;
- provenPredictButton.titleLabel.numberOfLines = 2;
- [provenPredictButton.titleLabel setTextAlignment: NSTextAlignmentCenter];
- [provenPredictButton setTitleEdgeInsets:UIEdgeInsetsMake(60, 10, 10, 10)];
- [provenPredictButton.titleLabel setFont:[UIFont systemFontOfSize:14.0]];
- provenPredictButton.frame=CGRectMake(10, 290, 140, 110);
- provenPredictButton.layer.cornerRadius=5;
- provenPredictButton.backgroundColor=[UIColor colorWithRed:246.0f/255.0f green:83.0f/255.0f blue:50.0f/255.0f alpha:1.0];
- [self.view addSubview:provenPredictButton];
- provenPredictImage=[[UIImageView alloc]initWithFrame:CGRectMake(45, 10, 48, 48)];
- provenPredictImage.image=[UIImage imageNamed:@"48*48.png"];
- [provenPredictButton addSubview:provenPredictImage];
- provenPredictButton.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin |UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin;
- // Future Predictions
- futurePredictionsButton=[UIButton buttonWithType:UIButtonTypeCustom];
- [futurePredictionsButton addTarget:self action:@selector(futurePredictions) forControlEvents:UIControlEventTouchUpInside];
- [futurePredictionsButton setTitle:@"FUTURE PREDICTIONS" forState:UIControlStateNormal];
- futurePredictionsButton.titleLabel.textAlignment = NSLineBreakByWordWrapping;
- futurePredictionsButton.titleLabel.numberOfLines = 2;
- [futurePredictionsButton.titleLabel setTextAlignment: NSTextAlignmentCenter];
- [futurePredictionsButton.titleLabel setTextAlignment: NSTextAlignmentCenter];
- [futurePredictionsButton setTitleEdgeInsets:UIEdgeInsetsMake(60, 10, 10, 10)];
- [futurePredictionsButton.titleLabel setFont:[UIFont systemFontOfSize:14.0]];
- futurePredictionsButton.frame=CGRectMake(160, 290, 140, 110);
- futurePredictionsButton.layer.cornerRadius=5;
- futurePredictionsButton.backgroundColor=[UIColor colorWithRed:114.0f/255.0f green:188.0f/255.0f blue:7.0f/255.0f alpha:1.0];
- [self.view addSubview:futurePredictionsButton];
- futurePredictionsImage=[[UIImageView alloc]initWithFrame:CGRectMake(45, 10, 48, 48)];
- futurePredictionsImage.image=[UIImage imageNamed:@"futureicon48.png"];
- [futurePredictionsButton addSubview:futurePredictionsImage];
- futurePredictionsImage.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin |UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin;
- ADBannerView *adView = [[ADBannerView alloc] initWithFrame:CGRectZero];
- adView.frame=CGRectMake(0, 410, 320, 40);
- adView.delegate=self;
- [self.view addSubview:adView];
- adView.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin |UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement