PasteboardPublisher:NSPasteboard的定制组合发布者(当前正在开发中)

时间:2021-03-21 17:58:22
【文件属性】:
文件名称:PasteboardPublisher:NSPasteboard的定制组合发布者(当前正在开发中)
文件大小:16KB
文件格式:ZIP
更新时间:2021-03-21 17:58:22
swift swift-package-manager spm combine pasteboard 粘贴板监视器 PasteboardMonitor是一个简单的库,它将Combine发行者添加到AppKit的NSPasteboard类中。 该库尚在开发中,尚未经过全面测试。它是与我的粘贴板过滤应用程序一起开发的。请参考该代码以获取用法的工作示例。 我将其创建为学习练习,以帮助您了解Combine,也可以为macOS开发人员社区提供帮助,甚至是很小的机会。当前无法在NSPasteboard上“订阅”更改,因此必须通过反复轮询粘贴板的changeCount来完成。该库将其抽象出来,并添加了Combine Publisher API。 如果消费者更喜欢使用该接口,将来的计划还将添加一个NSNotificationCenter发射器。 我使用了许多文章来构建该库,但是最终使我感到是 。
【文件预览】:
PasteboardPublisher-main
----Sources()
--------PasteboardPublisher()
----.swiftpm()
--------xcode()
----PasteboardPublisher.xcodeproj()
--------xcshareddata()
--------project.xcworkspace()
--------PasteboardPublisher_Info.plist(723B)
--------project.pbxproj(19KB)
--------PasteboardPublisherTests_Info.plist(723B)
----Tests()
--------PasteboardPublisherTests()
----LICENSE(1KB)
----README.md(1KB)
----.swiftlint.yml(724B)
----Package.swift(413B)
----.gitignore(40B)
----changelog.md(6KB)

网友评论