2015-11-18 13:42:25 +00:00
|
|
|
/*
|
|
|
|
Copyright 2015 OpenMarket Ltd
|
2017-02-14 17:21:46 +00:00
|
|
|
Copyright 2017 Vector Creations Ltd
|
2015-11-18 13:42:25 +00:00
|
|
|
|
|
|
|
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>
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
`RoomExtraInfosInfoView` instance is a view used to display extra information
|
|
|
|
*/
|
2016-03-07 12:56:52 +00:00
|
|
|
@interface RoomActivitiesView : MXKRoomActivitiesView <UITextViewDelegate, UIGestureRecognizerDelegate>
|
2015-11-18 14:59:04 +00:00
|
|
|
|
2015-12-16 15:52:32 +00:00
|
|
|
@property (weak, nonatomic) IBOutlet UIView *separatorView;
|
2016-02-25 12:54:53 +00:00
|
|
|
@property (weak, nonatomic) IBOutlet UIImageView *iconImageView;
|
2015-11-18 14:59:04 +00:00
|
|
|
@property (weak, nonatomic) IBOutlet UILabel *messageLabel;
|
2016-03-07 12:56:52 +00:00
|
|
|
@property (weak, nonatomic) IBOutlet UITextView *messageTextView;
|
2015-11-18 14:59:04 +00:00
|
|
|
|
2015-11-18 13:42:25 +00:00
|
|
|
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *mainHeightConstraint;
|
2015-11-18 14:59:04 +00:00
|
|
|
|
2016-02-25 12:54:53 +00:00
|
|
|
/**
|
|
|
|
Notify that some messages are not sent.
|
|
|
|
Replace the current notification if any.
|
|
|
|
|
2017-02-14 10:01:38 +00:00
|
|
|
@param notification the notification message to display.
|
2016-03-07 12:56:52 +00:00
|
|
|
@param onResendLinkPressed block called when user selects the resend link.
|
2017-03-07 15:46:56 +00:00
|
|
|
@param onCancelLinkPressed block called when user selects the cancel link.
|
2016-03-07 12:56:52 +00:00
|
|
|
@param onIconTapGesture block called when user taps on notification icon.
|
2016-02-25 12:54:53 +00:00
|
|
|
*/
|
2017-03-07 15:46:56 +00:00
|
|
|
- (void)displayUnsentMessagesNotification:(NSString*)notification withResendLink:(void (^)(void))onResendLinkPressed andCancelLink:(void (^)(void))onCancelLinkPressed andIconTapGesture:(void (^)(void))onIconTapGesture;
|
2016-02-25 12:54:53 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Display network error.
|
|
|
|
Replace the current notification if any.
|
|
|
|
|
|
|
|
@param labelText the notification message
|
|
|
|
*/
|
|
|
|
- (void)displayNetworkErrorNotification:(NSString*)labelText;
|
|
|
|
|
|
|
|
/**
|
|
|
|
Display a typing notification.
|
|
|
|
Replace the current notification if any.
|
|
|
|
|
|
|
|
@param labelText the current typing message.
|
|
|
|
*/
|
|
|
|
- (void)displayTypingNotification:(NSString*)labelText;
|
|
|
|
|
2016-08-08 16:40:22 +00:00
|
|
|
/**
|
|
|
|
Display an ongoing conference call.
|
|
|
|
Replace the current notification if any.
|
|
|
|
|
2016-09-06 11:30:06 +00:00
|
|
|
@param ongoingConferenceCallPressed the block called when the user clicks on the banner.
|
|
|
|
video is YES if the user chose to join the conf in video mode.
|
2017-08-17 10:17:07 +00:00
|
|
|
@param ongoingConferenceCallClosePressed the block called when the user clicks on the banner close button.
|
|
|
|
nil means do not display a close button.
|
2016-08-08 16:40:22 +00:00
|
|
|
*/
|
2017-08-17 10:17:07 +00:00
|
|
|
- (void)displayOngoingConferenceCall:(void (^)(BOOL video))ongoingConferenceCallPressed onClosePressed:(void (^)(void))ongoingConferenceCallClosePressed;
|
2016-09-06 11:30:06 +00:00
|
|
|
|
2016-08-29 16:34:00 +00:00
|
|
|
/**
|
|
|
|
Display a "scroll to bottom" icon.
|
|
|
|
Replace the current notification if any.
|
|
|
|
|
|
|
|
@param newMessagesCount the count of the unread messages.
|
|
|
|
@param onIconTapGesture block called when user taps on notification icon.
|
|
|
|
*/
|
|
|
|
- (void)displayScrollToBottomIcon:(NSUInteger)newMessagesCount onIconTapGesture:(void (^)(void))onIconTapGesture;
|
|
|
|
|
2018-07-27 09:48:38 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
Notify that the a room is obsolete and a replacement room is available.
|
|
|
|
|
|
|
|
@param onRoomReplacementLinkTapped block called when user selects the room replacement link.
|
|
|
|
*/
|
|
|
|
- (void)displayRoomReplacementWithRoomLinkTappedHandler:(void (^)(void))onRoomReplacementLinkTapped;
|
|
|
|
|
2018-08-21 16:25:56 +00:00
|
|
|
/**
|
|
|
|
Display a kMXErrCodeStringResourceLimitExceeded error received during a /sync request.
|
|
|
|
|
|
|
|
@param errorDict the error data.
|
|
|
|
@param onAdminContactTapped a callback indicating if the user wants to contact their admin.
|
|
|
|
*/
|
|
|
|
- (void)showResourceLimitExceededError:(NSDictionary *)errorDict onAdminContactTapped:(void (^)(NSURL *adminContact))onAdminContactTapped;
|
|
|
|
|
2016-02-25 12:54:53 +00:00
|
|
|
/**
|
|
|
|
Remove any displayed information.
|
|
|
|
*/
|
|
|
|
- (void)reset;
|
2015-11-18 14:59:04 +00:00
|
|
|
|
2015-11-18 13:42:25 +00:00
|
|
|
@end
|