理解を深めるために、質問をすべての詳細で完全に再更新します。
写真は言葉よりも多くを語ると言われているように、すべてを詳細に説明するために小さなモックアップを作りました!
まずは文章で説明します。
私はこれを持っています:
- 1 MasterViewController = (RootViewController)
- 1 FirstView = UITableView (データを含む多数のカスタム セルが表示されます)
- 2 SecondView = UIView
- 3 ThirdView = UIView
現在の画像/モックアップ:
私のMasterViewController.h(コードの一部)
@property (strong, nonatomic) FirstView *firstView;
@property (strong, nonatomic) SecondView *secondView;
@property (strong, nonatomic) ThirdView *thirdView;
私のMasterViewController.m(コードの一部)
firstView = [[LastSalesView alloc] initWithFrame:CGRectMake(0.0, 0.0, result.width, result.height)];
firstView.backgroundColor = [UIColor clearColor];
firstView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
[bottomContainerView addSubview:firstView];
[firstView setHidden:NO];
secondView = [[LastSalesView alloc] initWithFrame:CGRectMake(0.0, 0.0, result.width, result.height)];
secondView.backgroundColor = [UIColor clearColor];
secondView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
[bottomContainerView addSubview:secondView];
[secondView setHidden:NO];
thirdView = [[LastSalesView alloc] initWithFrame:CGRectMake(0.0, 0.0, result.width, result.height)];
thirdView.backgroundColor = [UIColor clearColor];
thirdView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
[bottomContainerView addSubview:thirdView];
[thirdView setHidden:NO];
-(void)viewFirstPage:(id)sender {
NSLog(@"button first pushed");
[firstView setHidden:NO];
[secondView setHidden:YES];
[thirdView setHidden:YES];
}
-(void)viewSecondPage:(id)sender {
NSLog(@"button second pushed");
[firstView setHidden:YES];
[secondView setHidden:NO];
[thirdView setHidden:YES];
}
-(void)viewThirdPage:(id)sender {
NSLog(@"button third pushed");
[firstView setHidden:YES];
[secondView setHidden:YES];
[thirdView setHidden:NO];
}