mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-28 20:26:57 +02:00
Prepare chat screen.
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
Copyright 2015 OpenMarket Ltd
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
#import <MatrixKit/MatrixKit.h>
|
||||
|
||||
@class MediaPickerViewController;
|
||||
|
||||
/**
|
||||
`MediaPickerViewController` delegate.
|
||||
*/
|
||||
@protocol MediaPickerViewControllerDelegate <NSObject>
|
||||
|
||||
/**
|
||||
Tells the delegate.
|
||||
|
||||
@param mediaPickerController the `MediaPickerViewController` instance.
|
||||
@param .
|
||||
*/
|
||||
- (void)todo:(MediaPickerViewController *)mediaPickerController;
|
||||
|
||||
@end
|
||||
|
||||
/**
|
||||
*/
|
||||
@interface MediaPickerViewController : MXKViewController
|
||||
|
||||
/**
|
||||
* Returns the `UINib` object initialized for a `MediaPickerViewController`.
|
||||
*
|
||||
* @return The initialized `UINib` object or `nil` if there were errors during initialization
|
||||
* or the nib file could not be located.
|
||||
*/
|
||||
+ (UINib *)nib;
|
||||
|
||||
/**
|
||||
* Creates and returns a new `MediaPickerViewController` object.
|
||||
*
|
||||
* @discussion This is the designated initializer for programmatic instantiation.
|
||||
*
|
||||
* @return An initialized `MediaPickerViewController` object if successful, `nil` otherwise.
|
||||
*/
|
||||
+ (instancetype)mediaPickerViewController;
|
||||
|
||||
/**
|
||||
The delegate for the view controller.
|
||||
*/
|
||||
@property (nonatomic) id<MediaPickerViewControllerDelegate> delegate;
|
||||
|
||||
|
||||
@end
|
||||
|
||||
@@ -0,0 +1,79 @@
|
||||
/*
|
||||
Copyright 2015 OpenMarket Ltd
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
#import "MediaPickerViewController.h"
|
||||
|
||||
@interface MediaPickerViewController ()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@implementation MediaPickerViewController
|
||||
|
||||
#pragma mark - Class methods
|
||||
|
||||
+ (UINib *)nib
|
||||
{
|
||||
return [UINib nibWithNibName:NSStringFromClass([MediaPickerViewController class])
|
||||
bundle:[NSBundle bundleForClass:[MediaPickerViewController class]]];
|
||||
}
|
||||
|
||||
+ (instancetype)mediaPickerViewController
|
||||
{
|
||||
return [[[self class] alloc] initWithNibName:NSStringFromClass([MediaPickerViewController class])
|
||||
bundle:[NSBundle bundleForClass:[MediaPickerViewController class]]];
|
||||
}
|
||||
|
||||
|
||||
|
||||
#pragma mark -
|
||||
|
||||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
// Do any additional setup after loading the view, typically from a nib.
|
||||
}
|
||||
|
||||
- (void)dealloc
|
||||
{
|
||||
}
|
||||
|
||||
- (void)didReceiveMemoryWarning
|
||||
{
|
||||
[super didReceiveMemoryWarning];
|
||||
// Dispose of any resources that can be recreated.
|
||||
}
|
||||
|
||||
- (void)viewWillAppear:(BOOL)animated
|
||||
{
|
||||
[super viewWillAppear:animated];
|
||||
}
|
||||
|
||||
- (void)viewWillDisappear:(BOOL)animated
|
||||
{
|
||||
[super viewWillDisappear:animated];
|
||||
}
|
||||
|
||||
#pragma mark - Override MXKViewController
|
||||
|
||||
- (void)destroy
|
||||
{
|
||||
[super destroy];
|
||||
}
|
||||
|
||||
@end
|
||||
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="7706" systemVersion="14D131" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES">
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="7703"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="MediaPickerViewController">
|
||||
<connections>
|
||||
<outlet property="view" destination="iN0-l3-epB" id="AXL-FN-kh5"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="iN0-l3-epB">
|
||||
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
|
||||
</view>
|
||||
</objects>
|
||||
</document>
|
||||
@@ -16,12 +16,11 @@
|
||||
|
||||
#import "RoomViewController.h"
|
||||
|
||||
#import "MXKRoomBubbleTableViewCell.h"
|
||||
|
||||
#import "AppDelegate.h"
|
||||
|
||||
#import "RageShakeManager.h"
|
||||
|
||||
#import "RoomInputToolbarView.h"
|
||||
|
||||
@interface RoomViewController ()
|
||||
{
|
||||
// Members list
|
||||
@@ -52,8 +51,8 @@
|
||||
// Set room title view
|
||||
[self setRoomTitleViewClass:MXKRoomTitleViewWithTopic.class];
|
||||
|
||||
// Replace the default input toolbar view with the one based on `HPGrowingTextView`.
|
||||
[self setRoomInputToolbarViewClass:MXKRoomInputToolbarViewWithHPGrowingText.class];
|
||||
// Replace the default input toolbar view.
|
||||
[self setRoomInputToolbarViewClass:RoomInputToolbarView.class];
|
||||
|
||||
// Set rageShake handler
|
||||
self.rageShakeManager = [RageShakeManager sharedManager];
|
||||
|
||||
Reference in New Issue
Block a user