commit
29cfbea1ef
|
@ -125,4 +125,9 @@ Localization/StringsConvertor/output
|
|||
.DS_Store
|
||||
|
||||
env/**/**
|
||||
!env/.env
|
||||
!env/.env
|
||||
|
||||
|
||||
## Ruby ###
|
||||
vendor/
|
||||
.bundle/
|
||||
|
|
|
@ -253,23 +253,6 @@ extension MediaHostToMediaPreviewViewControllerAnimatedTransitioning {
|
|||
return rect
|
||||
}()
|
||||
let maskLayerToPath = maskLayerToRect.flatMap { UIBezierPath(rect: $0) }?.cgPath
|
||||
let maskLayerToFinalRect: CGRect? = {
|
||||
guard case .attachments = transitionItem.source else { return nil }
|
||||
var rect = maskLayerToRect ?? transitionMaskView.frame
|
||||
// clip tabBar when bar visible
|
||||
guard let tabBarController = toVC.tabBarController,
|
||||
!tabBarController.tabBar.isHidden,
|
||||
let tabBarSuperView = tabBarController.tabBar.superview
|
||||
else { return rect }
|
||||
let tabBarFrameInWindow = tabBarSuperView.convert(tabBarController.tabBar.frame, to: nil)
|
||||
let offset = rect.maxY - tabBarFrameInWindow.minY
|
||||
guard offset > 0 else { return rect }
|
||||
rect.size.height -= offset
|
||||
return rect
|
||||
}()
|
||||
|
||||
// FIXME:
|
||||
_ = maskLayerToFinalRect.flatMap { UIBezierPath(rect: $0) }?.cgPath
|
||||
|
||||
if let maskLayerToPath = maskLayerToPath {
|
||||
maskLayer.path = maskLayerToPath
|
||||
|
|
|
@ -48,7 +48,7 @@ extension UIImage {
|
|||
guard let outputImage = filter.outputImage else { return nil }
|
||||
|
||||
var bitmap = [UInt8](repeating: 0, count: 4)
|
||||
let context = CIContext(options: [.workingColorSpace: kCFNull])
|
||||
let context = CIContext(options: [.workingColorSpace: kCFNull as Any])
|
||||
context.render(outputImage, toBitmap: &bitmap, rowBytes: 4, bounds: CGRect(x: 0, y: 0, width: 1, height: 1), format: .RGBA8, colorSpace: nil)
|
||||
|
||||
return UIColor(red: CGFloat(bitmap[0]) / 255, green: CGFloat(bitmap[1]) / 255, blue: CGFloat(bitmap[2]) / 255, alpha: CGFloat(bitmap[3]) / 255)
|
||||
|
|
|
@ -108,11 +108,6 @@ extension MastodonStatusPublisher: StatusPublisher {
|
|||
|
||||
// Task: attachment
|
||||
|
||||
let uploadContext = AttachmentViewModel.UploadContext(
|
||||
apiService: api,
|
||||
authContext: authContext
|
||||
)
|
||||
|
||||
var attachmentIDs: [Mastodon.Entity.Attachment.ID] = []
|
||||
for attachmentViewModel in attachmentViewModels {
|
||||
// set progress
|
||||
|
@ -161,11 +156,6 @@ extension MastodonStatusPublisher: StatusPublisher {
|
|||
guard pollOptions != nil else { return nil }
|
||||
return self.pollExpireConfigurationOption.seconds
|
||||
}()
|
||||
let pollMultiple: Bool? = {
|
||||
guard self.isPollComposing else { return nil }
|
||||
guard pollOptions != nil else { return nil }
|
||||
return self.pollMultipleConfigurationOption
|
||||
}()
|
||||
let inReplyToID: Mastodon.Entity.Status.ID? = try await api.backgroundManagedObjectContext.perform {
|
||||
guard let replyTo = self.replyTo?.object(in: api.backgroundManagedObjectContext) else { return nil }
|
||||
return replyTo.id
|
||||
|
|
|
@ -43,7 +43,9 @@ extension MastodonTests {
|
|||
} receiveValue: { domain in
|
||||
expectation.fulfill()
|
||||
}
|
||||
wait(for: [expectation], timeout: 10)
|
||||
withExtendedLifetime(cancellable) {
|
||||
wait(for: [expectation], timeout: 10)
|
||||
}
|
||||
}
|
||||
|
||||
func testConnectOnion() async throws {
|
||||
|
|
Loading…
Reference in New Issue