亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

IOS代碼筆記之下拉選項(xiàng)cell

 更新時(shí)間:2016年07月06日 09:38:58   作者:情深雨蒙  
這篇文章主要為大家詳細(xì)介紹了IOS代碼筆記之下拉選項(xiàng)cell的相關(guān)資料,需要的朋友可以參考下

本文介紹了IOS下拉選項(xiàng)cell的使用方法,供大家參考,具體內(nèi)容如下

一、效果圖

 

二、工程圖

 

三、代碼
RootViewController.h

#import <UIKit/UIKit.h>
//加入頭文件
#import "ComboBoxView.h"

@interface RootViewController : UIViewController
{
  ComboBoxView    *_comboBox;
}

@end 

RootViewController.m

#import "RootViewController.h"

@interface RootViewController ()

@end

@implementation RootViewController

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
  self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
  if (self) {
    // Custom initialization
  }
  return self;
}

- (void)viewDidLoad
{
  [super viewDidLoad];
  // Do any additional setup after loading the view.
  
  self.navigationController.navigationBarHidden=YES;
  
  
  NSArray *comboBoxDatasource = [[NSArray alloc] initWithObjects:@"one", @"two", @"three", @"four", @"five", @"six", @"seven", @"eight", nil];
  _comboBox = [[ComboBoxView alloc] initWithFrame:CGRectMake(20, 20, 280, 140)];
  _comboBox.comboBoxDatasource = comboBoxDatasource;
  _comboBox.backgroundColor = [UIColor clearColor];
  [_comboBox setContent:[comboBoxDatasource objectAtIndex:0]];
  [self.view addSubview:_comboBox];
  
  
}

以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持腳本之家。

相關(guān)文章

最新評論