如果我的表格在3秒內未填滿所有信息,我想顯示「載入」消息。這裏是我想要我的桌子做的事情:如果表格需要很長時間,則顯示正在載入消息
-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
//First time
UITableView *cell = [tableView cellForRowAtIndexPath:indexPath];
//Configure table
//Second Time
}
NSTimeInterval timeDifference = [firstTime timeIntervalSinceDate:secondTime];
if (timeDifference == 3 seconds){
//Display Loading message
}
您有問題嗎? – 2012-07-17 18:37:08
那麼我的問題是如何顯示加載消息,如果它超過3秒。 我不能這樣做,因爲它會在完成一切後運行時差。 我不能這樣做,因爲那時我不知道時差。 我需要與我的表格視圖同時運行它。 – BigT 2012-07-17 19:24:20
你用什麼樣的信息加載你的桌子?從磁盤加載的圖片?或者下載文本? – 2012-07-17 21:22:38