summaryrefslogtreecommitdiff
path: root/Juick/ViewControllers/ThreadViewController.m
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2017-12-03 20:12:08 +0300
committerGravatar Vitaly Takmazov2017-12-03 20:12:08 +0300
commitccf06c2af74f63e5276e15f3e10acf74bf4174f7 (patch)
treec32c2b16c4c09cf074bde2b98b3bce6c277e359c /Juick/ViewControllers/ThreadViewController.m
parent95f73b34319b62df320dcaa43e9c7925dc4868df (diff)
WIP
Diffstat (limited to 'Juick/ViewControllers/ThreadViewController.m')
-rw-r--r--Juick/ViewControllers/ThreadViewController.m36
1 files changed, 21 insertions, 15 deletions
diff --git a/Juick/ViewControllers/ThreadViewController.m b/Juick/ViewControllers/ThreadViewController.m
index 893765b..4de0cab 100644
--- a/Juick/ViewControllers/ThreadViewController.m
+++ b/Juick/ViewControllers/ThreadViewController.m
@@ -9,23 +9,20 @@
#import "ThreadViewController.h"
#import "ColorScheme.h"
#import "MessageCell.h"
+@import PHFComposeBarView;
@interface ThreadViewController ()
@property (nonatomic, readwrite, retain) UIView *inputAccessoryView;
+-(void) updateQuoteText:(Message *)message;
+
@end
@implementation ThreadViewController
- (void)viewDidLoad {
[super viewDidLoad];
-
- // Uncomment the following line to preserve selection between presentations.
- // self.clearsSelectionOnViewWillAppear = NO;
-
- // Uncomment the following line to display an Edit button in the navigation bar for this view controller.
- // self.navigationItem.rightBarButtonItem = self.editButtonItem;
}
@@ -36,17 +33,26 @@
- (UIView *)inputAccessoryView {
if (!_inputAccessoryView) {
CGRect viewBounds = self.view.bounds;
- CGRect frame = CGRectMake(0, viewBounds.size.height - PHFComposeBarViewInitialHeight, viewBounds.size.width,
- PHFComposeBarViewInitialHeight);
- PHFComposeBarView *_view = [[PHFComposeBarView alloc] initWithFrame:frame];
- _view.backgroundColor = [UIColor whiteColor];
- _view.buttonTintColor = [ColorScheme linkColor];
- _view.maxLinesCount = 4;
- _view.utilityButtonImage = [UIImage imageNamed:@"Camera"];
- _view.delegate = self;
- _inputAccessoryView = _view;
+ CGRect frame = CGRectMake(0, viewBounds.size.height - PHFComposeBarViewInitialHeight - self.view.safeAreaInsets.top + self.view.safeAreaInsets.bottom, viewBounds.size.width, PHFComposeBarViewInitialHeight);
+ PHFComposeBarView *inputView = [[PHFComposeBarView alloc] initWithFrame:frame];
+ inputView.backgroundColor = [UIColor whiteColor];
+ inputView.buttonTintColor = [ColorScheme linkColor];
+ inputView.maxLinesCount = 4;
+ inputView.utilityButtonImage = [UIImage imageNamed:@"Camera"];
+ inputView.delegate = self;
+ _inputAccessoryView = inputView;
}
return _inputAccessoryView;
}
+-(void) updateQuoteText:(Message *)message {
+ /*MessageInputView *inputView = (MessageInputView *)self.inputAccessoryView;
+ inputView.quoteText.text = message.text;*/
+}
+
+-(void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
+ Message * selectedMessage = [self.messages objectAtIndex:indexPath.row];
+ [self updateQuoteText:selectedMessage];
+}
+
@end