Files
ZASENJC db1a28da00 fix(macos): 修复 Release 优化下动态 NSColor 闭包提前释放导致启动崩溃
- 在 pale_ink 动态提供器闭包中使用 Retained::autorelease_ptr(color) 将 NSColor 放入自动释放池后再返回裸指针,避免 Release 模式下 objc_retainAutoreleasedReturnValue 优化导致函数返回前即被 drop 释放
- 升级版本至 0.2.4
2026-10-16 18:53:08 +08:00

134 lines
2.9 KiB
TOML

[workspace]
resolver = "2"
members = [
"crates/ttree-core",
"crates/ttree-storage",
"crates/ttree-platform",
"crates/ttree-ocr",
"crates/ttree-translate",
"crates/ttree-ai",
"crates/ttree-updater",
"apps/macos",
"apps/windows",
]
[workspace.package]
version = "0.2.4"
edition = "2021"
authors = ["ZASENJC"]
license = "MIT"
[workspace.dependencies]
anyhow = "1"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
tokio = { version = "1", features = ["full"] }
reqwest = { version = "0.12", features = ["json", "stream", "cookies"] }
futures-util = "0.3"
url = "2"
urlencoding = "2"
tempfile = "3"
dirs = "6"
auto-launch = "0.5"
global-hotkey = "0.8"
core-foundation = "0.10"
block2 = "0.6"
objc2 = "0.6"
objc2-foundation = { version = "0.3", features = [
"NSArray",
"NSAttributedString",
"NSBundle",
"NSData",
"NSDictionary",
"NSError",
"NSGeometry",
"NSObject",
"NSProcessInfo",
"NSRange",
"NSRunLoop",
"NSString",
"NSThread",
"NSTimer",
"NSURL",
"NSValue",
] }
objc2-core-foundation = "0.3"
objc2-core-graphics = { version = "0.3", features = [
"CGBitmapContext",
"CGColorSpace",
"CGContext",
"CGEvent",
"CGEventTypes",
"CGImage",
"CGRemoteOperation",
] }
objc2-core-image = { version = "0.3", features = ["CIContext"] }
objc2-core-ml = { version = "0.3", features = ["MLCPUComputeDevice", "MLComputeDeviceProtocol"] }
objc2-image-io = { version = "0.3", features = ["CGImageSource"] }
objc2-vision = { version = "0.3", features = [
"objc2-core-graphics",
"objc2-core-ml",
"VNRequest",
"VNRecognizeTextRequest",
"VNObservation",
"VNRequestHandler",
"VNTypes",
] }
objc2-app-kit = { version = "0.3", features = [
"block2",
"NSAppearance",
"NSApplication",
"NSBezierPath",
"NSBox",
"NSButton",
"NSButtonCell",
"NSCell",
"NSColor",
"NSColorList",
"NSControl",
"NSEvent",
"NSFont",
"NSGraphics",
"NSImage",
"NSMenu",
"NSMenuItem",
"NSOpenPanel",
"NSPanel",
"NSPasteboard",
"NSPasteboardItem",
"NSPopUpButton",
"NSResponder",
"NSRunningApplication",
"NSSavePanel",
"NSScreen",
"NSScrollView",
"NSSecureTextField",
"NSSegmentedControl",
"NSSlider",
"NSStatusBar",
"NSStatusBarButton",
"NSStatusItem",
"NSText",
"NSTextContainer",
"NSTextField",
"NSTextFieldCell",
"NSTextStorage",
"NSTextView",
"NSView",
"NSVisualEffectView",
"NSWindow",
"objc2-core-foundation",
"objc2-core-graphics",
] }
objc2-quartz-core = { version = "0.3", features = ["CALayer", "objc2-core-graphics"] }
windows = { version = "0.58", features = [
"Foundation",
"Foundation_Collections",
"Globalization",
"Graphics_Imaging",
"Media_Ocr",
"Security_Cryptography",
"Storage_Streams",
"Win32_System_WinRT",
] }