aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPAppController.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/SPAppController.m')
-rw-r--r--Source/SPAppController.m30
1 files changed, 3 insertions, 27 deletions
diff --git a/Source/SPAppController.m b/Source/SPAppController.m
index a90876fa..046628b3 100644
--- a/Source/SPAppController.m
+++ b/Source/SPAppController.m
@@ -659,35 +659,11 @@
}
}
- if(!processDocument)
+ // if no processDoc found and no passedProcessID was passed execute
+ // command at front most doc
+ if(!processDocument && !passedProcessID)
processDocument = [[[self frontDocumentWindow] delegate] selectedTableDocument];
-
- BOOL userTerminated = NO;
-
- // while(1) {
- // NSEvent* event = [NSApp nextEventMatchingMask:NSAnyEventMask
- // untilDate:[NSDate distantPast]
- // inMode:NSDefaultRunLoopMode
- // dequeue:YES];
- //
- // if ([event type] == NSKeyDown) {
- // unichar key = [[event characters] length] == 1 ? [[event characters] characterAtIndex:0] : 0;
- // if (([event modifierFlags] & NSCommandKeyMask) && key == '.') {
- // userTerminated = YES;
- // break;
- // }
- // }
- // [NSApp sendEvent:event];
- // if(![processDocument isWorking]) break;
- // usleep(1000);
- // }
- //
- // if(userTerminated) {
- // NSBeep();
- // return;
- // }
-
if(processDocument && command) {
if([command isEqualToString:@"passToDoc"]) {
NSMutableDictionary *cmdDict = [NSMutableDictionary dictionary];