2
0

PolycodeAppDelegate.h 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. //
  2. // PolycodeAppDelegate.h
  3. // Polycode
  4. //
  5. // Created by Ivan Safrin on 11/28/10.
  6. // Copyright 2010 Local Projects. All rights reserved.
  7. //
  8. #import <Cocoa/Cocoa.h>
  9. #import "PolycodeView.h"
  10. #include "Polycode.h"
  11. #include "PolycodeIDEApp.h"
  12. using namespace Polycode;
  13. @class PolycodeAppDelegate;
  14. class PolycodeAppEventHandler : public EventHandler {
  15. public:
  16. PolycodeAppEventHandler() {}
  17. ~PolycodeAppEventHandler() {}
  18. void handleEvent(Event *evt);
  19. PolycodeAppDelegate* appDelegate;
  20. };
  21. @interface PolycodeAppDelegate : NSObject <NSApplicationDelegate> {
  22. NSWindow *window;
  23. PolycodeIDEApp *app;
  24. PolycodeView *polycodeView;
  25. PolycodeAppEventHandler *eventHandler;
  26. NSTimer* timer;
  27. NSMenu *projectMenu;
  28. String fileToOpen;
  29. BOOL mustShowProjectMenu;
  30. }
  31. @property (assign) IBOutlet PolycodeView *polycodeView;
  32. @property (assign) IBOutlet NSWindow *window;
  33. @property (assign) IBOutlet NSMenu *projectMenu;
  34. - (void) showProjectMenu;
  35. // Menu accessors
  36. -(IBAction) toggleConsole: (id) sender;
  37. -(IBAction) refreshProject: (id) sender;
  38. -(IBAction) renameFile: (id) sender;
  39. -(IBAction) removeFile: (id) sender;
  40. -(IBAction) newGroup: (id) sender;
  41. -(IBAction) browseExamples: (id) sender;
  42. -(IBAction) runProject: (id) sender;
  43. -(IBAction) exportProject: (id) sender;
  44. -(IBAction) newProject: (id) sender;
  45. -(IBAction) closeProject: (id) sender;
  46. -(IBAction) closeFile: (id) sender;
  47. -(IBAction) newFile: (id) sender;
  48. -(IBAction) openProject: (id) sender;
  49. -(IBAction) saveFile: (id) sender;
  50. -(IBAction) findText: (id) sender;
  51. -(IBAction) openDocs: (id) sender;
  52. -(IBAction) showAbout: (id) sender;
  53. -(IBAction) showSettings: (id) sender;
  54. -(IBAction) createNewTab: (id) sender;
  55. -(IBAction) showNextTab: (id) sender;
  56. -(IBAction) showPreviousTab: (id) sender;
  57. -(IBAction) closeTab: (id) sender;
  58. @end