зеркало из https://github.com/nextcloud/talk-ios.git
Use material activity indicator in chat messages sending delivery state.
Signed-off-by: Ivan Sein <ivan@nextcloud.com>
This commit is contained in:
Родитель
cdf813c5d5
Коммит
09a969a269
1
Podfile
1
Podfile
|
@ -12,5 +12,6 @@ pod 'UICKeyChainStore'
|
|||
pod 'Realm'
|
||||
pod "AFViewShaker", "~> 0.0.5"
|
||||
pod 'BKPasscodeView', '~> 0.1.2'
|
||||
pod 'MaterialComponents/ActivityIndicator'
|
||||
end
|
||||
|
||||
|
|
|
@ -1312,10 +1312,12 @@
|
|||
inputPaths = (
|
||||
"${PODS_ROOT}/Target Support Files/Pods-VideoCalls/Pods-VideoCalls-resources.sh",
|
||||
"${PODS_ROOT}/DateTools/DateTools/DateTools/DateTools.bundle",
|
||||
"${PODS_ROOT}/MaterialComponents/components/ActivityIndicator/src/MaterialActivityIndicator.bundle",
|
||||
);
|
||||
name = "[CP] Copy Pods Resources";
|
||||
outputPaths = (
|
||||
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/DateTools.bundle",
|
||||
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/MaterialActivityIndicator.bundle",
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
shellPath = /bin/sh;
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
#import "ChatMessageTableViewCell.h"
|
||||
#import "SLKUIConstants.h"
|
||||
#import "QuotedMessageView.h"
|
||||
#import "MaterialActivityIndicator.h"
|
||||
#import "UIImageView+AFNetworking.h"
|
||||
#import "UIImageView+Letters.h"
|
||||
|
||||
|
@ -193,8 +194,9 @@
|
|||
[self.statusView.subviews makeObjectsPerformSelector: @selector(removeFromSuperview)];
|
||||
|
||||
if (state == ChatMessageDeliveryStateSending) {
|
||||
UIActivityIndicatorView *activityIndicator = [[UIActivityIndicatorView alloc] initWithFrame:CGRectMake(0, 0, 20, 20)];
|
||||
activityIndicator.color = [UIColor darkGrayColor];
|
||||
MDCActivityIndicator *activityIndicator = [[MDCActivityIndicator alloc] initWithFrame:CGRectMake(0, 0, 20, 20)];
|
||||
activityIndicator.radius = 7.0f;
|
||||
activityIndicator.cycleColors = @[UIColor.grayColor];
|
||||
[activityIndicator startAnimating];
|
||||
[self.statusView addSubview:activityIndicator];
|
||||
} else if (state == ChatMessageDeliveryStateFailed) {
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
#import "FileMessageTableViewCell.h"
|
||||
#import "SLKUIConstants.h"
|
||||
#import "MaterialActivityIndicator.h"
|
||||
#import "NCSettingsController.h"
|
||||
#import "NCUtils.h"
|
||||
#import "OpenInFirefoxControllerObjC.h"
|
||||
|
@ -185,8 +186,9 @@
|
|||
[self.statusView.subviews makeObjectsPerformSelector: @selector(removeFromSuperview)];
|
||||
|
||||
if (state == ChatMessageDeliveryStateSending) {
|
||||
UIActivityIndicatorView *activityIndicator = [[UIActivityIndicatorView alloc] initWithFrame:CGRectMake(0, 0, 20, 20)];
|
||||
activityIndicator.color = [UIColor darkGrayColor];
|
||||
MDCActivityIndicator *activityIndicator = [[MDCActivityIndicator alloc] initWithFrame:CGRectMake(0, 0, 20, 20)];
|
||||
activityIndicator.radius = 7.0f;
|
||||
activityIndicator.cycleColors = @[UIColor.grayColor];
|
||||
[activityIndicator startAnimating];
|
||||
[self.statusView addSubview:activityIndicator];
|
||||
} else if (state == ChatMessageDeliveryStateFailed) {
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
//
|
||||
|
||||
#import "GroupedChatMessageTableViewCell.h"
|
||||
#import "MaterialActivityIndicator.h"
|
||||
#import "SLKUIConstants.h"
|
||||
|
||||
@implementation GroupedChatMessageTableViewCell
|
||||
|
@ -64,8 +65,9 @@
|
|||
[self.statusView.subviews makeObjectsPerformSelector: @selector(removeFromSuperview)];
|
||||
|
||||
if (state == ChatMessageDeliveryStateSending) {
|
||||
UIActivityIndicatorView *activityIndicator = [[UIActivityIndicatorView alloc] initWithFrame:CGRectMake(0, 0, 20, 20)];
|
||||
activityIndicator.color = [UIColor darkGrayColor];
|
||||
MDCActivityIndicator *activityIndicator = [[MDCActivityIndicator alloc] initWithFrame:CGRectMake(0, 0, 20, 20)];
|
||||
activityIndicator.radius = 7.0f;
|
||||
activityIndicator.cycleColors = @[UIColor.grayColor];
|
||||
[activityIndicator startAnimating];
|
||||
[self.statusView addSubview:activityIndicator];
|
||||
} else if (state == ChatMessageDeliveryStateFailed) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче