2011-09-29 62 views
1

我不知道有沒有人使用過SBTableAlert。它看起來很棒,但沒有太多的文檔。SBTableAlert的問題。它顯示警報但不顯示UITableView

它也沒有調用UITableView將使用的任何函數。任何人都可以幫助下面的代碼。

//load the bookmarks and setup the popup 
SBTableAlert *bookmarkAlert; 

bookmarkAlert = [[SBTableAlert alloc] initWithTitle:@"Jump to:" cancelButtonTitle:@"Back" messageFormat:nil]; 
[bookmarkAlert setDelegate:self]; 
//[bookmarkAlert setDataSource:self]; 

NSString *settingsicon = [[NSBundle mainBundle] pathForResource:@"gear" ofType:@"png"]; 
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageWithContentsOfFile:settingsicon] style:UIBarButtonItemStylePlain target:bookmarkAlert action:@selector(show)]; 
+0

爲了讓這個工作正常運行,你遇到了什麼? – jroyce

回答

0

在上面的代碼,你不設置數據源。這將是你沒有得到你想要的東西的明顯原因,除非你稍後設置。

+0

我實際上不記得我做了什麼來完成它的工作,但是在經過許多精力充沛的工作之後,我在一段時間之前完成了這個項目。 – Alienz

+0

是的,我也有一個「有趣」的時間。 – jroyce