From ba09d82aecc42487a4ebc981231c612546cdeca3 Mon Sep 17 00:00:00 2001 From: neon443 <69979447+neon443@users.noreply.github.com> Date: Sun, 3 May 2026 16:28:52 +0100 Subject: [PATCH] afsd --- StickerSlack/Emoji/GifManager.swift | 37 ----------------------------- 1 file changed, 37 deletions(-) diff --git a/StickerSlack/Emoji/GifManager.swift b/StickerSlack/Emoji/GifManager.swift index 7dc4289..a00f90f 100644 --- a/StickerSlack/Emoji/GifManager.swift +++ b/StickerSlack/Emoji/GifManager.swift @@ -38,41 +38,4 @@ class GifManager { } return result } - - static func dataFrom(frames: [(frame: CGImage, showFor: Double)]) -> Data? { - var data = NSMutableData() - - let fileProperties = [ - kCGImagePropertyGIFDictionary: [ - kCGImagePropertyGIFLoopCount: 0 - ] - ] - - guard let destination = CGImageDestinationCreateWithData( - data, - UTType.gif.identifier as CFString, - frames.count, - nil - ) else { fatalError() } - - CGImageDestinationSetProperties(destination, fileProperties as NSDictionary) - - for frame in frames { - autoreleasepool { - let frameProperties = [ - kCGImagePropertyGIFDictionary: [ - kCGImagePropertyGIFDelayTime: frame.showFor - ] - ] - CGImageDestinationAddImage( - destination, - frame.frame, - frameProperties as CFDictionary - ) - } - } - - guard CGImageDestinationFinalize(destination) else { fatalError() } - return data as Data - } }