开发者

Add TTThumbsViewController to a ViewController

I tried to use the codes below to add a TTThumbsViewController to a ViewController

#import <Three20/Three20.h>

@interface PhotoTestController : TTThumbsViewController {
}

@end

@implementation PhotoTestController

- (void)viewDidLoad {

 }

@开发者_StackOverflow中文版end

//---------------------------------------------------------------

//in my ViewController.m

- (void)viewDidLoad
 {

   PhotoTestController *vPhotoTestController=[[PhotoTest2Controller alloc] init  ];
   [vPhotoTest2Controller setDelegate:self];
   [self.view addSubview:vPhotoTestController.view ];
 }

on the view of ViewController, there is no UI for TTThumbsViewController/PhotoTestController display and only show a full screen white window, I am not sure what is wrong?

Welcome any comment

Thanks


I have been struggling with this as well, but I just discovered that for some reason viewWillAppear was not being called. Once I added [self viewWillAppear:YES] in the viewDidLoad function of my ViewController, the table appeared.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜