mirror of
https://github.com/nickshanks/ResKnife.git
synced 2024-12-22 02:29:56 +00:00
Made existing template fields editable so I don't have to edit templates in the Hex Editor anymore.
This commit is contained in:
parent
d3ad470d45
commit
ef49978240
@ -18,5 +18,6 @@
|
||||
-(short) shortValue;
|
||||
|
||||
-(NSString*) stringValue;
|
||||
-(void) setStringValue: (NSString*)str;
|
||||
|
||||
@end
|
||||
|
@ -64,5 +64,15 @@
|
||||
}
|
||||
|
||||
|
||||
-(void) setStringValue: (NSString*)str
|
||||
{
|
||||
char cstr[256];
|
||||
char* endPtr = cstr +255;
|
||||
|
||||
strncpy( cstr, [str cString], 255 );
|
||||
shortValue = strtol( cstr, &endPtr, 10 );
|
||||
}
|
||||
|
||||
|
||||
|
||||
@end
|
||||
|
@ -45,7 +45,7 @@
|
||||
|
||||
[self setStringValue: [NSString stringWithCString:buf length:4]];
|
||||
|
||||
NSLog(@"PSTR: %@", stringValue);
|
||||
NSLog(@"TNAM: %@", stringValue);
|
||||
}
|
||||
|
||||
|
||||
|
@ -239,6 +239,12 @@
|
||||
return [item valueForKey:[tableColumn identifier]];
|
||||
}
|
||||
|
||||
-(void) outlineView:(NSOutlineView *)outlineView setObjectValue:(id)object forTableColumn:(NSTableColumn *)tableColumn byItem:(id)item
|
||||
{
|
||||
[item takeValue:object forKey: [tableColumn identifier]];
|
||||
}
|
||||
|
||||
|
||||
|
||||
-(BOOL) windowShouldClose: (id)sender // Window delegate.
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user