Developer Area

root/apps/iphone/my.tel/trunk/Classes/KeywordEditController.h @ 634

Revision 634, 2.0 kB (checked in by henri, 4 years ago)

Further improvements to Keyword editing

Line 
1//
2//  KeywordEditController.h
3//  My.tel
4//
5//  Created by Henri Asseily on 11/27/08.
6//  Copyright 2008 Telnic Ltd.. All rights reserved.
7//
8
9#import <UIKit/UIKit.h>
10#import "MyTelConnect.h"
11#import "Keyword.h"
12#import "HATextViewEditController.h"
13#import "HATypePickerController.h"
14
15enum kKKeywordEditTableViewSections {
16        kKKeywordEditTableViewSectionType,                      // Primary type
17        kKKeywordEditTableViewSectionValue,                     // Primary value
18        kKKeywordEditTableViewSectionSecondaries,       // Array of secondaries
19        kKKeywordEditTableViewSectionsCount                     // Keep this last to get the count of sections
20};
21
22@protocol KeywordEditDelegate <TelControllerDelegate>
23@required
24- (NSString *)longNameForKeyword:(NSString *)shortName;
25- (NSArray *)typesForKeyword:(NSString *)shortName;
26@end
27
28#define kKPrimaryValueMaxLength 255             // max length of value when keyword has secondaries
29#define kKValueMaxLength        255                     // max length of value when keyword doesn't have secondaries
30
31
32@interface KeywordEditController : UITableViewController <UITableViewDelegate,
33UITableViewDataSource,
34HATextViewEditDelegate,
35HATypePickerViewDelegate> {
36       
37        NSString *keywordId;
38        NSString *primaryType;
39        NSString *primaryValue;
40        NSMutableArray *secondaryKeywords;
41        id <KeywordEditDelegate> delegate;
42@private
43        UIBarButtonItem *buttonSave;
44        BOOL isEditing;
45        NSInteger rowBeingEdited;
46        HATypePickerController *typePickerController;
47}
48
49+ (KeywordEditController *)controllerForKeyword:(NSDictionary *)aRec delegate:(id <KeywordEditDelegate>)aDelegate;
50- (KeywordEditController *)initWithKeyword:(NSDictionary *)aRec delegate:(id <KeywordEditDelegate>)aDelegate;
51- (void)didClickCancel;
52- (void)didClickSave;
53- (NSMutableArray *)fillSecondaryKeywords:(NSArray *)secArray;
54
55@property (nonatomic, retain) NSString *keywordId;
56@property (nonatomic, retain) NSString *primaryType;
57@property (nonatomic, retain) NSString *primaryValue;
58@property (nonatomic, retain) NSMutableArray *secondaryKeywords;
59@property (retain) id <KeywordEditDelegate> delegate;
60@property (nonatomic, readonly) BOOL keywordHasSecondaries;
61
62@end
Note: See TracBrowser for help on using the browser.
Telnic
Search This Site
Partners
Neustar
ICANN
Main site | WHOIS | Sell .tel | FAQ | Archived Site | About Telnic | Contact Us