attachment_engine_macos 0.0.1-dev.0
attachment_engine_macos: ^0.0.1-dev.0 copied to clipboard
The macOS implementation of attachment_engine. Full-parity native Swift implementation — PDF (PDFKit), audio/video (AVFoundation/AVKit), webview (WKWebView), share, open-externally, office preview (Qu [...]
attachment_engine_macos #
The macOS implementation of attachment_engine,
backed entirely by native Swift code — no third-party plugin
dependencies.
Status #
Full feature parity with iOS/Android, native (see
macos/attachment_engine_macos/Sources/attachment_engine_macos/). Every
request/response call goes through a
pigeon-generated HostApi protocol
(schema: attachment_engine_platform_interface/pigeons/messages.dart,
generated bindings: Messages.g.swift); audio/video/download events
stay on hand-written FlutterEventChannels, noted per-row below:
- PDF — PDFKit (
PDFDocument,PDFPage.thumbnail), viaPdfHostApi - Audio — AVFoundation (
AVAudioPlayerfor local files,AVPlayerfor streaming URLs); control viaAudioHostApi, playback events via a hand-written per-playerFlutterEventChannel - Video — AVKit (
AVPlayerLayer), embedded via aFlutterPlatformViewFactory— surfaced to Dart throughAppKitView; control viaVideoHostApi, playback events via a hand-written per-playerFlutterEventChannel - WebView —
WKWebView, embedded the same way - Paths —
NSSearchPathForDirectoriesInDomains, viaPathsHostApi - Share —
NSSharingServicePicker(AppKit's native share sheet), viaShareHostApi - Open externally —
NSWorkspace.open(_:), viaOpenHostApi - Office preview —
QLPreviewPanel(QuickLook; doc/docx/xls/xlsx/ppt/ pptx/rtf and more, ships with every macOS install), viaOfficeHostApi - Download —
URLSession/URLSessionDownloadTask, with resume-data support; start/resume/cancel viaDownloadHostApi, progress events via a hand-written sharedFlutterEventChannel
Registers as a Swift Package (Package.swift) — Flutter reports
All plugins found for macos are Swift Packages. A .podspec is kept
alongside it for CocoaPods-only consumers, per Flutter's dual-support
requirement during the SPM migration window.
You should not need to depend on this package directly — add
attachment_engine to your app instead, and the
right platform implementation is selected automatically.