-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathNNRestaurantView.h
50 lines (36 loc) · 1.1 KB
/
NNRestaurantView.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
//
// NNRestaurantView.h
// lunchd
//
// Created by MacRae Linton on 3/26/10.
// Copyright 2010 Apple Inc.. All rights reserved.
//
#import <Cocoa/Cocoa.h>
#import "NNRestaurant.h"
#import "NNPerson.h"
#import "NNLunchControl.h"
@interface NNRestaurantView : NSView {
NSTextField *nameField;
NSButton *voteButton;
NSButton *vetoButton;
NNPerson *mePerson;
NNRestaurant *representedRestaurant;
}
- (id)initWithFrame:(NSRect)frame andController:(id)controller;
- (void)setRepresentedRestaurant:(NNRestaurant *)restaurant;
- (NNRestaurant *)representedRestaurant;
//This takes the state in the object and redraws.
//gets called by observing the votes attribute on the represented restaurant
- (void)updateState;
@end
@interface NNPersonView : NSView {
NSTextField *nameField;
NNPerson *representedPerson;
}
- (id)initWithFrame:(NSRect)frame andController:(id)controller;
- (void)setRepresentedPerson:(NNPerson *)person;
- (NNPerson *)representedPerson;
//This takes the state in the object and redraws.
//gets called by observing the votes attribute on the represented restaurant
- (void)updateState;
@end