-
Notifications
You must be signed in to change notification settings - Fork 0
/
BPReadingDetailViewController.h
49 lines (35 loc) · 1.82 KB
/
BPReadingDetailViewController.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
//
// BPReadingDetailView.h
// BPTracker
//
// Created by Robert Saccone on 1/30/11.
// Copyright (c) 2017 Robert Saccone. All rights reserved.
//
#import <UIKit/UIKit.h>
@class BloodPressureReading;
@class DatePickerViewController;
@class NoteTakerViewController;
@class BPReadingDetailViewController;
typedef BOOL (^DoneUpdatingBloodPressureReadingBlock)(BOOL saved);
@protocol BPReadingDetailViewControllerDelegate <NSObject>
- (void)modeChanged:(BOOL)editing;
- (BOOL)doneUpdatingBloodPressureReading:(BPReadingDetailViewController *)viewController bloodPressureReading:(BloodPressureReading *)reading saved:(BOOL)saved newReading:(BOOL)newReading;
@end
@interface BPReadingDetailViewController : UIViewController<UITextViewDelegate, UITextFieldDelegate>
// Designated initializer for this class.
- (id)init:(BloodPressureReading *)bloodPressureReading newReading:(BOOL)newBPReading
setDefaultsFromReading:(BOOL)defaultsFromReading
doneCallback:(DoneUpdatingBloodPressureReadingBlock)doneCallbackBlock;
// Designated initializer for this class.
- (id)init:(BloodPressureReading *)bloodPressureReading newReading:(BOOL)newBPReading
setDefaultsFromReading:(BOOL)defaultsFromReading
viewControllerDelegate:(id<BPReadingDetailViewControllerDelegate>)delegate;
// Cancels any editing action underway.
- (void)cancelEditMode;
@property(nonatomic, strong) BloodPressureReading *bloodPressureReading;
@property(nonatomic, assign) BOOL allowEditing;
@property(nonatomic, readonly, assign) BOOL newReading;
@property(nonatomic, readonly, assign) BOOL editMode;
@property(nonatomic, readonly, assign) BOOL canceled;
@property(nonatomic, readonly, assign) BOOL updated;
@end