Archived
1

Fundamental Redesign of the View and Controller

This commit is contained in:
Kim Wittenburg
2014-08-22 00:54:13 +02:00
parent a37d587e1f
commit c024886241
12 changed files with 255 additions and 150 deletions

View File

@@ -7,6 +7,7 @@
//
#import "MPExpressionStorage.h"
#import "MPExpressionView.h"
#import "MPExpressionLayout.h"
#import "MPFunctionLayout.h"
#import "MPRangePath.h"
@@ -19,6 +20,15 @@
@implementation MPExpressionStorage
- (instancetype)initWithExpressionView:(MPExpressionView *)expressionView elements:(NSArray *)elements
{
self = [self initWithElements:elements];
if (self) {
_expressionView = expressionView;
}
return self;
}
- (instancetype)initWithElements:(NSArray *)elements
{
self = [super initWithElements:elements];
@@ -69,7 +79,9 @@
for (NSUInteger index = 1; index < rangePath.location.length-1; index++) {
current = [current childLayoutAtIndex:index];
}
[current clearCacheInRange:rangePath.rangeAtLastIndex replacementLength:replacementLength];
[current clearCacheInRange:rangePath.rangeAtLastIndex
replacementLength:replacementLength];
self.expressionView.needsDisplay = YES;
}
@end