mirror of
https://github.com/atom/atom.git
synced 2026-04-06 03:02:13 -04:00
@@ -30,6 +30,8 @@
|
||||
|
||||
|
||||
if (!background) {
|
||||
[self setShouldCascadeWindows:NO];
|
||||
[self setWindowFrameAutosaveName:@"AtomWindow"];
|
||||
[self showWindow:self];
|
||||
}
|
||||
|
||||
@@ -76,7 +78,13 @@
|
||||
|
||||
- (void)windowDidLoad {
|
||||
[self.window setDelegate:self];
|
||||
[self performSelector:@selector(attachWebView) withObject:nil afterDelay:0];
|
||||
}
|
||||
|
||||
// If this is run directly in windowDidLoad, the web view doesn't
|
||||
// have the correct initial size based on the frame's last stored size.
|
||||
// HACK: I hate this and want to place this code directly in windowDidLoad
|
||||
- (void)attachWebView {
|
||||
NSURL *url = [[NSBundle mainBundle] resourceURL];
|
||||
NSMutableString *urlString = [NSMutableString string];
|
||||
[urlString appendString:[[url URLByAppendingPathComponent:@"static/index.html"] absoluteString]];
|
||||
|
||||
Reference in New Issue
Block a user