From 4c64b79dc24bc1d8e61aff59176c27059bd0313c Mon Sep 17 00:00:00 2001 From: rowanbeentje Date: Thu, 22 Sep 2011 23:41:48 +0000 Subject: - Fix editing of binary string values, a regression in r3428; addresses log 2665 --- Source/SPTableContent.m | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Source/SPTableContent.m') diff --git a/Source/SPTableContent.m b/Source/SPTableContent.m index 4f12f021..81bc44f6 100644 --- a/Source/SPTableContent.m +++ b/Source/SPTableContent.m @@ -4438,6 +4438,9 @@ if (!useFieldEditor && ![[columnDefinition objectForKey:@"typegrouping"] isEqualToString:@"enum"] && isBlob) useFieldEditor = YES; if (!useFieldEditor) { id cellValue = [tableValues cellDataAtRow:rowIndex column:[[aTableColumn identifier] integerValue]]; + if ([cellValue isKindOfClass:[NSData class]]) { + cellValue = [[[NSString alloc] initWithData:cellValue encoding:[mySQLConnection stringEncoding]] autorelease]; + } if (![cellValue isNSNull] && [[columnDefinition objectForKey:@"typegrouping"] isEqualToString:@"string"] && [cellValue rangeOfCharacterFromSet:[NSCharacterSet newlineCharacterSet] options:NSLiteralSearch].location != NSNotFound) -- cgit v1.2.3