diff options
Diffstat (limited to 'Source')
-rw-r--r-- | Source/SPDataAdditions.m | 2 | ||||
-rw-r--r-- | Source/SPTableContentDataSource.m | 8 |
2 files changed, 7 insertions, 3 deletions
diff --git a/Source/SPDataAdditions.m b/Source/SPDataAdditions.m index ab0bfb01..351ef4d8 100644 --- a/Source/SPDataAdditions.m +++ b/Source/SPDataAdditions.m @@ -304,7 +304,7 @@ string = @"-- cannot display --"; } else if ([string length] > 255) { - string = [string substringToIndex:255]; + string = [[string substringToIndex:254] stringByAppendingString:@"…"]; } return string; diff --git a/Source/SPTableContentDataSource.m b/Source/SPTableContentDataSource.m index 0f84950d..c49169a0 100644 --- a/Source/SPTableContentDataSource.m +++ b/Source/SPTableContentDataSource.m @@ -108,8 +108,12 @@ if ([value isNSNull]) return [prefs objectForKey:SPNullValue]; - if ([value isKindOfClass:[NSData class]]) - return [value shortStringRepresentationUsingEncoding:[mySQLConnection stringEncoding]]; + if ([value isKindOfClass:[NSData class]]) { + if ([tableContentView shouldUseFieldEditorForRow:rowIndex column:columnIndex]) { + return [value shortStringRepresentationUsingEncoding:[mySQLConnection stringEncoding]]; + } + return [value stringRepresentationUsingEncoding:[mySQLConnection stringEncoding]]; + } if ([value isSPNotLoaded]) return NSLocalizedString(@"(not loaded)", @"value shown for hidden blob and text fields"); |