aboutsummaryrefslogtreecommitdiffstats
path: root/Source/TableContent.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/TableContent.m')
-rw-r--r--Source/TableContent.m12
1 files changed, 10 insertions, 2 deletions
diff --git a/Source/TableContent.m b/Source/TableContent.m
index 4d68ce1f..46fde6b3 100644
--- a/Source/TableContent.m
+++ b/Source/TableContent.m
@@ -2387,9 +2387,17 @@ objectValueForTableColumn:(NSTableColumn *)aTableColumn
{
if ( tableView == tableContentView )
{
- NSString *tmp = [tableContentView draggedRowsAsTabString:rows];
+
+ NSString *tmp;
+
+ // By holding ⌘, ⇧, or/and ⌥ copies selected rows as SQL INSERTS
+ // otherwise \t delimited lines
+ if([[NSApp currentEvent] modifierFlags] & (NSCommandKeyMask|NSShiftKeyMask|NSAlternateKeyMask))
+ tmp = [tableContentView selectedRowsAsSqlInserts];
+ else
+ tmp = [tableContentView draggedRowsAsTabString:rows];
- if ( nil != tmp )
+ if ( nil != tmp && [tmp length] )
{
[pboard declareTypes:[NSArray arrayWithObjects: NSTabularTextPboardType,
NSStringPboardType, nil]