whitespace and Xcode project cleanup

This commit is contained in:
Corey Johnson
2011-09-04 18:16:46 -07:00
parent 819ec44e98
commit 094434776d
4 changed files with 16 additions and 17 deletions

View File

@@ -7,7 +7,7 @@
objects = {
/* Begin PBXBuildFile section */
04C8F31614144CC00041D072 /* AtomApp.m in Sources */ = {isa = PBXBuildFile; fileRef = 04C8F31514144CC00041D072 /* AtomApp.m */; };
046973A414145A9500415518 /* AtomApp.m in Sources */ = {isa = PBXBuildFile; fileRef = 046973A314145A9500415518 /* AtomApp.m */; };
83599F9B13FE0F8400AC37E3 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 83599F9A13FE0F8400AC37E3 /* WebKit.framework */; };
8359A6EE13FE26DA00AC37E3 /* JavaScriptCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8359A6ED13FE26DA00AC37E3 /* JavaScriptCore.framework */; };
837D8BA91408FAAA009B6DFA /* AtomWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 837D8BA71408FAAA009B6DFA /* AtomWindowController.m */; };
@@ -28,8 +28,8 @@
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
04C8F31414144CC00041D072 /* AtomApp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AtomApp.h; sourceTree = "<group>"; };
04C8F31514144CC00041D072 /* AtomApp.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AtomApp.m; sourceTree = "<group>"; };
046973A214145A9500415518 /* AtomApp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AtomApp.h; path = Classes/AtomApp.h; sourceTree = "<group>"; };
046973A314145A9500415518 /* AtomApp.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AtomApp.m; path = Classes/AtomApp.m; sourceTree = "<group>"; };
1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = "<absolute>"; };
13E42FB307B3F0F600E4EEF1 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = /System/Library/Frameworks/CoreData.framework; sourceTree = "<absolute>"; };
29B97324FDCFA39411CA2CEA /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = "<absolute>"; };
@@ -80,8 +80,8 @@
080E96DDFE201D6D7F000001 /* Classes */ = {
isa = PBXGroup;
children = (
04C8F31414144CC00041D072 /* AtomApp.h */,
04C8F31514144CC00041D072 /* AtomApp.m */,
046973A214145A9500415518 /* AtomApp.h */,
046973A314145A9500415518 /* AtomApp.m */,
837D8BA61408FAAA009B6DFA /* AtomWindowController.h */,
837D8BA71408FAAA009B6DFA /* AtomWindowController.m */,
29B97315FDCFA39411CA2CEA /* Other Sources */,
@@ -275,7 +275,7 @@
837D8BD91408FAD4009B6DFA /* JSCocoaFFIClosure.m in Sources */,
837D8BDA1408FAD4009B6DFA /* JSCocoaLib.m in Sources */,
837D8BDB1408FAD4009B6DFA /* JSCocoaPrivateObject.m in Sources */,
04C8F31614144CC00041D072 /* AtomApp.m in Sources */,
046973A414145A9500415518 /* AtomApp.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};

View File

@@ -5,8 +5,8 @@
@implementation AtomApp
- (void)sendEvent:(NSEvent *)event {
switch ([event type]) {
case NSKeyDown:
switch ([event type]) {
case NSKeyDown:
case NSFlagsChanged: {
AtomWindowController *controller = (AtomWindowController *)[[self keyWindow] windowController];
BOOL handeled = [controller handleKeyEvent:event];
@@ -14,10 +14,10 @@
[super sendEvent:event];
}
}
default:
default:
[super sendEvent:event];
break;
}
break;
}
}
// AppDelegate

View File

@@ -23,18 +23,18 @@
- (void)windowDidLoad {
[super windowDidLoad];
[self setShouldCascadeWindows:YES];
[self setWindowFrameAutosaveName:@"atomWindow"];
if (self.URL) {
[webView setMainFrameURL:self.URL];
}
}
else {
JSCocoa* jsc = [[JSCocoa alloc] initWithGlobalContext:[[webView mainFrame] globalContext]];
[jsc setObject:self withName:@"WindowController"];
NSString *resourcePath = [[NSBundle mainBundle] resourcePath];
NSString *requirePath = [resourcePath stringByAppendingString:@"/src/require.js"];
[jsc evalJSFile:requirePath];
@@ -43,7 +43,7 @@
NSURL *htmlURL = [resourceURL URLByAppendingPathComponent:@"static"];
NSURL *indexURL = [htmlURL URLByAppendingPathComponent:@"index.html"];
NSString *html = [NSString stringWithContentsOfURL:indexURL encoding:NSUTF8StringEncoding error:nil];
[[webView mainFrame] loadHTMLString:html baseURL:htmlURL];
[[webView mainFrame] loadHTMLString:html baseURL:htmlURL];
}
}
@@ -51,5 +51,4 @@
return NO;
}
@end