remove dead code
This commit is contained in:
parent
9dd5ad0fb5
commit
0ac2bf2321
|
@ -9,14 +9,9 @@
|
||||||
#import <Cocoa/Cocoa.h>
|
#import <Cocoa/Cocoa.h>
|
||||||
|
|
||||||
@interface Image_OpenerAppDelegate : NSObject <NSApplicationDelegate> {
|
@interface Image_OpenerAppDelegate : NSObject <NSApplicationDelegate> {
|
||||||
@private
|
|
||||||
NSWindow *_window;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@property (assign) IBOutlet NSWindow *window;
|
|
||||||
|
|
||||||
|
|
||||||
//-(IBAction)openDocument:(id)sender;
|
|
||||||
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
|
@ -7,12 +7,9 @@
|
||||||
//
|
//
|
||||||
|
|
||||||
#import "Image_OpenerAppDelegate.h"
|
#import "Image_OpenerAppDelegate.h"
|
||||||
#import "WindowController.h"
|
|
||||||
#import "IODocumentController.h"
|
|
||||||
|
|
||||||
@implementation Image_OpenerAppDelegate
|
@implementation Image_OpenerAppDelegate
|
||||||
|
|
||||||
@synthesize window = _window;
|
|
||||||
|
|
||||||
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
|
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
|
||||||
{
|
{
|
||||||
|
@ -23,17 +20,9 @@
|
||||||
|
|
||||||
-(void)applicationWillFinishLaunching:(NSNotification *)notification {
|
-(void)applicationWillFinishLaunching:(NSNotification *)notification {
|
||||||
|
|
||||||
// initialize the shared document controller.
|
|
||||||
//[[IODocumentController alloc] init];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
- (BOOL)application:(NSApplication *)theApplication openFile:(NSString *)filename
|
|
||||||
{
|
|
||||||
[WindowController controllerWithFilePath: filename];
|
|
||||||
return YES;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
-(BOOL)applicationShouldOpenUntitledFile:(NSApplication *)sender {
|
-(BOOL)applicationShouldOpenUntitledFile:(NSApplication *)sender {
|
||||||
return NO;
|
return NO;
|
||||||
|
@ -43,42 +32,5 @@
|
||||||
return NO;
|
return NO;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
-(IBAction)openDocument:(id)sender
|
|
||||||
{
|
|
||||||
NSOpenPanel *panel;
|
|
||||||
|
|
||||||
panel = [NSOpenPanel openPanel];
|
|
||||||
|
|
||||||
[panel setCanChooseFiles: YES];
|
|
||||||
[panel setCanCreateDirectories: NO];
|
|
||||||
[panel setResolvesAliases: YES];
|
|
||||||
[panel setAllowsMultipleSelection: NO];
|
|
||||||
[panel setExtensionHidden: NO];
|
|
||||||
|
|
||||||
|
|
||||||
[panel beginWithCompletionHandler: ^(NSInteger result){
|
|
||||||
|
|
||||||
if (result == 1)
|
|
||||||
{
|
|
||||||
NSURL *url = [[panel URLs] lastObject];
|
|
||||||
NSString *path = [url isFileURL] ? [url path] : nil;
|
|
||||||
|
|
||||||
//NSLog(@"%d %@", (int)result, path);
|
|
||||||
|
|
||||||
if (path)
|
|
||||||
{
|
|
||||||
|
|
||||||
[WindowController controllerWithFilePath: path];
|
|
||||||
|
|
||||||
[[NSDocumentController sharedDocumentController] noteNewRecentDocumentURL: url];
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
}];
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
Loading…
Reference in New Issue