Guest User

Untitled

a guest
Oct 16th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. @interface AppDelegate : NSObject <NSApplicationDelegate>
  2. {
  3. NewRepoWindowController* newRepoSheet;
  4. }
  5.  
  6. - (IBAction)addRepo:(id)sender;
  7.  
  8. @property (assign) IBOutlet NSWindow *window;
  9.  
  10. @end
  11.  
  12. #import "AppDelegate.h"
  13. @implementation AppDelegate
  14.  
  15. - (void)applicationDidFinishLaunching:(NSNotification *)aNotification
  16. {
  17. newRepoSheet = [[NewRepoWindowController alloc] initWithWindowNibName:@"NewRepoWindowController"];
  18. }
  19.  
  20. - (IBAction)addRepo:(id)sender {
  21.  
  22. [NSApp beginSheet: newRepoSheet.window
  23. modalForWindow: self.window
  24. modalDelegate: newRepoSheet
  25. didEndSelector: @selector(didEndSheet:returnCode:contextInfo:)
  26. contextInfo: nil];
  27.  
  28. }
  29. @end
Add Comment
Please, Sign In to add comment