Skip to content

Commit

Permalink
Add Feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisballinger committed Dec 19, 2012
1 parent 175f199 commit ab20cf2
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
10 changes: 8 additions & 2 deletions OpenWatch/OWSettingsViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
#import "OWRecordingListViewController.h"
#import "OWUtilities.h"

#define ACCOUNT_ROW 0
#define FEEDBACK_ROW 1

@interface OWSettingsViewController ()

@end
Expand All @@ -31,7 +34,8 @@ - (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view.
[self addCellInfoWithSection:0 row:0 labelText:ACCOUNT_STRING cellType:kCellTypeNone userInputView:nil];
[self addCellInfoWithSection:0 row:ACCOUNT_ROW labelText:ACCOUNT_STRING cellType:kCellTypeNone userInputView:nil];
[self addCellInfoWithSection:0 row:FEEDBACK_ROW labelText:SEND_FEEDBACK_STRING cellType:kCellTypeNone userInputView:nil];
}

- (void)didReceiveMemoryWarning
Expand All @@ -46,11 +50,13 @@ - (void) viewWillAppear:(BOOL)animated {
}

- (void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
if (indexPath.row == 0) {
if (indexPath.row == ACCOUNT_ROW) {
OWLoginViewController *loginView = [[OWLoginViewController alloc] init];
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:loginView];
navController.navigationBar.tintColor = [OWUtilities navigationBarColor];
[self presentViewController:navController animated:YES completion:nil];
} else if (indexPath.row == FEEDBACK_ROW) {
[TestFlight openFeedbackView];
}
[tableView deselectRowAtIndexPath:indexPath animated:YES];
}
Expand Down
1 change: 1 addition & 0 deletions OpenWatch/OWStrings.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
#define SAVED_STRING NSLocalizedString(@"Saved", @"Title for saved recordings")
#define WELCOME_STRING NSLocalizedString(@"Welcome!", @"title for welcome screen")
#define STOP_RECORDING_STRING NSLocalizedString(@"Stop Recording?", @"Question whether user wants to actually stop recording")
#define SEND_FEEDBACK_STRING NSLocalizedString(@"Send Feedback", @"help us improve the app")
#define WELCOME_TEXTVIEW_STRING NSLocalizedString(@"Welcome, new Watcher!\n\
\n\
Thanks for installing OpenWatch!\n\
Expand Down
1 change: 0 additions & 1 deletion OpenWatch/OWWatchViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#import "OWWatchViewController.h"
#import "OWAccountAPIClient.h"
#import "OWRecordingTag.h"
#import "OWRemoteRecordingViewController.h"
#import "OWRecordingTableViewCell.h"
#import "OWStrings.h"
#import "OWUtilities.h"
Expand Down
2 changes: 2 additions & 0 deletions OpenWatch/OpenWatch-Prefix.pch
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// Prefix header for all source files of the 'OpenWatch' target in the 'OpenWatch' project
//


#import <Availability.h>

#ifndef __IPHONE_3_0
Expand All @@ -16,4 +17,5 @@
#import "CoreData+MagicalRecord.h"
#import "TestFlight.h"
#import "OWCheckpoints.h"
#define NSLog(__FORMAT__, ...) TFLog((@"%s [Line %d] " __FORMAT__), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__)
#endif

0 comments on commit ab20cf2

Please sign in to comment.