summaryrefslogtreecommitdiffstats
path: root/Classes/TopicsViewController.m
diff options
context:
space:
mode:
Diffstat (limited to 'Classes/TopicsViewController.m')
-rw-r--r--Classes/TopicsViewController.m13
1 files changed, 7 insertions, 6 deletions
diff --git a/Classes/TopicsViewController.m b/Classes/TopicsViewController.m
index 2548bf3..9751eb2 100644
--- a/Classes/TopicsViewController.m
+++ b/Classes/TopicsViewController.m
@@ -101,13 +101,13 @@
- (NSTimeInterval) daysApart:(NSDate *)date {
//NSLog(@"datestring: %@", [Topic dateToString:date]);
- NSDate *today = [NSDate date];
-
+// NSDate *today = [NSDate date];
+// NSLog(@"today: %@", today);
// NSDateFormatter *dateFormatter = [[[NSDateFormatter alloc] init] autorelease];
// [dateFormatter setDateFormat:@"yyyy-MM-dd"];
// NSDate *published = [dateFormatter dateFromString:string];
- return [today timeIntervalSinceDate:date];
+ return [date timeIntervalSinceNow];
}
// called after parsing is finished
@@ -282,12 +282,13 @@
[mi clear];
}
+ Topic *topic = [[tableDictionary objectForIndex:[indexPath section]] objectAtIndex:[indexPath row]];
//cell.useDarkBackground = (indexPath.row % 2 == 0);
- cell.title = [[topics objectAtIndex:indexPath.row] title];
- cell.picCount = [NSString stringWithFormat:@"%@", [[topics objectAtIndex:indexPath.row] picCount]];
+ cell.title = topic.title;
+ cell.picCount = [NSString stringWithFormat:@"%@", topic.picCount];
micon.url = [NSURL URLWithString:@"http://www.acidcow.com/favicon.ico"];
- mi.url = [NSURL URLWithString:[[topics objectAtIndex:indexPath.row] iconUrl]];
+ mi.url = [NSURL URLWithString:topic.iconUrl];
mi.squareCropped = true;
[objMan manage:mi];