Do not track recent locations

This commit is contained in:
Allan Odgaard
2013-01-12 00:12:22 +01:00
parent b4066afc9a
commit 49c587e6bd
2 changed files with 0 additions and 10 deletions

View File

@@ -15,7 +15,3 @@
@property (nonatomic, readonly) NSInteger historyCount;
- (NSURL*)urlAtIndex:(NSInteger)index;
@end
@interface OakHistoryController (WorkaroundForBeingBackedByNSMutableArray)
@property (nonatomic, readonly) NSArray* recentLocations;
@end

View File

@@ -3,7 +3,6 @@
#import <oak/debug.h>
@interface OakHistoryController ()
@property (nonatomic) NSMutableArray* recentLocations;
@property (nonatomic) NSMutableArray* history;
@end
@@ -14,7 +13,6 @@
{
_history = [NSMutableArray new];
_historyIndex = -1;
_recentLocations = [NSMutableArray new];
}
return self;
}
@@ -33,7 +31,6 @@
- (void)setState:(NSDictionary*)newState
{
[_recentLocations removeAllObjects];
[_history removeAllObjects];
for(NSDictionary* entry in newState[@"history"])
{
@@ -64,9 +61,6 @@
- (void)addURLToHistory:(NSURL*)url
{
ASSERT(url);
[_recentLocations removeObject:url];
[_recentLocations addObject:url];
if(++_historyIndex < [_history count])
[_history removeObjectsInRange:NSMakeRange(_historyIndex, [_history count] - _historyIndex)];