-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathNNLunchControl.h
120 lines (85 loc) · 2.67 KB
/
NNLunchControl.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
//
// NNLunchControl.h
// lunchd
//
// Created by MacRae Linton on 3/9/10.
// Copyright 2010 Apple Inc.. All rights reserved.
//
#import <Cocoa/Cocoa.h>
#import <AddressBook/AddressBook.h>
#import "NNRestaurant.h"
#import "NNPerson.h"
#import "NNRestaurantView.h"
#import "NNSlidingStackView.h"
#import "NNNetworkSync.h"
@class NNNetworkSync;
@class NNNMessage;
@interface NNLunchControl : NSObject {
IBOutlet NNSlidingStackView *restaurantSSView;
IBOutlet NNSlidingStackView *personSSView;
NSTrackingArea *trackingArea;
BOOL getStartedNow;
BOOL gameIsOver;
NSMutableArray *people;
NSMutableArray *restaurants;
NSMutableArray *slidingQueue;
NSMutableArray *restaurantList;
//YOU
NSString *myGroup;
NNPerson *mePerson;
NSString *endChoice;
//TOP FIELDS
NSView *currentTopView;
IBOutlet NSView *whoView;
IBOutlet NSView *inOrOutView;
IBOutlet NSView *ininView;
IBOutlet NSView *outoutView;
IBOutlet NSWindow *theWindow;
IBOutlet NSTextField *nameField;
NSMutableArray *myDefaultRestaurants;
NNNetworkSync *networkSync;
NSStatusItem *menuBarItem;
NSTimer *counterDown;
int DEBUGS;
}
@property (retain) NSMutableArray *restaurants;
@property (retain) NSMutableArray *people;
@property (retain) NNPerson *mePerson;
@property (retain) NSMutableArray *myDefaultRestaurants;
@property (retain) NNNetworkSync *networkSync;
//- (void)addRestaurant:(NSString *)newRestaurant;
- (IBAction)imIn:(id)sender;
- (IBAction)imOut:(id)sender;
- (void)endGame:(NSString *)winningName;
- (void)playWhoAreYou:(id)sender;
- (NNRestaurant *)createNewRestaurantWithName:(NSString *)name;
- (NNPerson *)createNewPersonWithName:(NSString *)name;
- (IBAction)enterYourName:(id)sender;
- (IBAction)syncUpDefaults:(id)sender;
- (IBAction)voteButtonPress:(id)sender;
- (IBAction)vetoButtonPress:(id)sender;
- (void)updateRestaurantPosition:(NNRestaurant *)restaurant;
- (void)updatePersonPosition:(NNPerson *)person;
- (void)dealWithMessage:(NNNMessage *)message fromSocket:(AsyncSocket *)socket;
- (NNNMessage *)currentMessage;
- (void)lostConnectionToSocket:(AsyncSocket *)socket;
- (void)broadcastMessageToAll;
- (void)setTopView:(NSView *)newView;
- (void)extricatePerson:(NNPerson *)thePerson;
- (NSArray *)rightDiffBetweenArray:(NSArray *)array1 andArray:(NSArray *)array2;
- (id)objectWithName:(NSString *)name fromArray:(NSArray *)array;
//- (NSMenu *)applicationDockMenu:(NSApplication *)sender;
- (IBAction)debugButtonClick:(id)sender;
@end
@interface NNRestDef : NSObject {
NSString *rName;
}
@property (retain) NSString *rName;
@end
@interface NNShiftTuple : NSObject {
int fromIndex;
int toIndex;
}
@property (assign) int fromIndex;
@property (assign) int toIndex;
@end