mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Merge commit 'ed5f2636aae56207389ed5e04a1fe9d7b3d1c787'
This commit is contained in:
commit
69d60af5aa
@ -1365,7 +1365,8 @@ class ChatListItemNode: ItemListRevealOptionsItemNode {
|
||||
currentSecretIconImage = PresentationResourcesChatList.secretIcon(item.presentationData.theme)
|
||||
}
|
||||
var credibilityIconOffset: CGFloat = 0.0
|
||||
if !isPeerGroup {
|
||||
|
||||
if !isPeerGroup && item.index.messageIndex.id.peerId != item.context.account.peerId {
|
||||
if displayAsMessage {
|
||||
switch item.content {
|
||||
case let .peer(messages, _, _, _, _, _, _, _, _, _, _, _, _):
|
||||
|
@ -470,8 +470,15 @@ public final class NavigationContainer: ASDisplayNode, UIGestureRecognizerDelega
|
||||
})
|
||||
} else {
|
||||
if let fromValue = fromValue {
|
||||
if viewTreeContainsFirstResponder(view: fromValue.value.view) {
|
||||
self.ignoreInputHeight = true
|
||||
}
|
||||
|
||||
fromValue.value.viewWillLeaveNavigation()
|
||||
fromValue.value.viewWillDisappear(false)
|
||||
|
||||
self.keyboardViewManager?.dismissEditingWithoutAnimation(view: fromValue.value.view)
|
||||
|
||||
fromValue.value.setIgnoreAppearanceMethodInvocations(true)
|
||||
fromValue.value.displayNode.removeFromSupernode()
|
||||
fromValue.value.setIgnoreAppearanceMethodInvocations(false)
|
||||
@ -487,6 +494,7 @@ public final class NavigationContainer: ASDisplayNode, UIGestureRecognizerDelega
|
||||
toValue.value.displayNode.recursivelyEnsureDisplaySynchronously(true)
|
||||
toValue.value.viewDidAppear(false)
|
||||
}
|
||||
self.ignoreInputHeight = false
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -60,7 +60,7 @@ typedef enum {
|
||||
|
||||
- (id<LegacyComponentsAccessChecker>)accessChecker;
|
||||
|
||||
- (id<SDisposable>)requestAudioSession:(TGAudioSessionType)type interrupted:(void (^)())interrupted;
|
||||
- (id<SDisposable>)requestAudioSession:(TGAudioSessionType)type activated:(void (^)())activated interrupted:(void (^)())interrupted;
|
||||
|
||||
- (SThreadPool *)sharedMediaImageProcessingThreadPool;
|
||||
- (TGMemoryImageCache *)sharedMediaMemoryImageCache;
|
||||
|
@ -367,7 +367,7 @@ const NSInteger PGCameraFrameRate = 30;
|
||||
_hasAudioSession = true;
|
||||
[_audioSessionQueue dispatchSync:^
|
||||
{
|
||||
[_currentAudioSession setDisposable:[[LegacyComponentsGlobals provider] requestAudioSession:TGAudioSessionTypePlayAndRecord interrupted:nil]];
|
||||
[_currentAudioSession setDisposable:[[LegacyComponentsGlobals provider] requestAudioSession:TGAudioSessionTypePlayAndRecord activated:nil interrupted:nil]];
|
||||
}];
|
||||
}
|
||||
|
||||
|
@ -1120,7 +1120,7 @@
|
||||
__weak TGMediaPickerGalleryVideoItemView *weakSelf = self;
|
||||
[[SQueue concurrentDefaultQueue] dispatch:^
|
||||
{
|
||||
[_currentAudioSession setDisposable:[[LegacyComponentsGlobals provider] requestAudioSession:TGAudioSessionTypePlayVideo interrupted:^
|
||||
[_currentAudioSession setDisposable:[[LegacyComponentsGlobals provider] requestAudioSession:TGAudioSessionTypePlayVideo activated:nil interrupted:^
|
||||
{
|
||||
TGDispatchOnMainThread(^
|
||||
{
|
||||
|
@ -919,9 +919,6 @@ static CGFloat angleOffsetFromPortraitOrientationToOrientation(AVCaptureVideoOri
|
||||
if (![device respondsToSelector:@selector(setVideoZoomFactor:)])
|
||||
return false;
|
||||
|
||||
if (device.position == AVCaptureDevicePositionFront)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -572,10 +572,6 @@ typedef enum
|
||||
[self _transitionIn];
|
||||
|
||||
[self _beginAudioSession:false];
|
||||
[_queue dispatch:^
|
||||
{
|
||||
[_capturePipeline startRunning];
|
||||
}];
|
||||
}
|
||||
|
||||
- (void)viewDidAppear:(BOOL)animated
|
||||
@ -1308,7 +1304,16 @@ typedef enum
|
||||
_otherAudioPlaying = [[AVAudioSession sharedInstance] isOtherAudioPlaying];
|
||||
|
||||
__weak TGVideoMessageCaptureController *weakSelf = self;
|
||||
id<SDisposable> disposable = [[LegacyComponentsGlobals provider] requestAudioSession:speaker ? TGAudioSessionTypePlayAndRecordHeadphones : TGAudioSessionTypePlayAndRecord interrupted:^
|
||||
id<SDisposable> disposable = [[LegacyComponentsGlobals provider] requestAudioSession:speaker ? TGAudioSessionTypePlayAndRecordHeadphones : TGAudioSessionTypePlayAndRecord
|
||||
activated:^{
|
||||
__strong TGVideoMessageCaptureController *strongSelf = weakSelf;
|
||||
if (strongSelf != nil) {
|
||||
[strongSelf->_queue dispatch:^
|
||||
{
|
||||
[strongSelf->_capturePipeline startRunning];
|
||||
}];
|
||||
}
|
||||
} interrupted:^
|
||||
{
|
||||
TGDispatchOnMainThread(^{
|
||||
__strong TGVideoMessageCaptureController *strongSelf = weakSelf;
|
||||
|
@ -177,7 +177,7 @@ private final class LegacyComponentsGlobalsProviderImpl: NSObject, LegacyCompone
|
||||
return LegacyComponentsAccessCheckerImpl(context: legacyContext)
|
||||
}
|
||||
|
||||
public func request(_ type: TGAudioSessionType, interrupted: (() -> Void)!) -> SDisposable! {
|
||||
public func request(_ type: TGAudioSessionType, activated: (() -> Void)!, interrupted: (() -> Void)!) -> SDisposable! {
|
||||
if let legacyContext = legacyContext {
|
||||
let convertedType: ManagedAudioSessionType
|
||||
switch type {
|
||||
@ -187,6 +187,7 @@ private final class LegacyComponentsGlobalsProviderImpl: NSObject, LegacyCompone
|
||||
convertedType = .play
|
||||
}
|
||||
let disposable = legacyContext.sharedContext.mediaManager.audioSession.push(audioSessionType: convertedType, once: true, activate: { _ in
|
||||
activated?()
|
||||
}, deactivate: { _ in
|
||||
interrupted?()
|
||||
return .complete()
|
||||
|
@ -177,8 +177,8 @@ private final class StickerPackContainer: ASDisplayNode {
|
||||
|
||||
self.addSubnode(self.backgroundNode)
|
||||
self.addSubnode(self.gridNode)
|
||||
// self.addSubnode(self.actionAreaBackgroundNode)
|
||||
// self.addSubnode(self.actionAreaSeparatorNode)
|
||||
self.addSubnode(self.actionAreaBackgroundNode)
|
||||
self.addSubnode(self.actionAreaSeparatorNode)
|
||||
self.addSubnode(self.buttonNode)
|
||||
|
||||
self.addSubnode(self.titleBackgroundnode)
|
||||
|
Loading…
x
Reference in New Issue
Block a user