summary history branches tags files
commit:305136ac4816d266f41438570aa63778807d8bf3
author:Jørgen P. Tjernø
committer:Jørgen P. Tjernø
date:Mon Mar 1 22:06:31 2021 -0800
parents:f25e35c76ebc1c91dc91cb6d5f3a216abb651cc9
Add non-Mac shim for `nsstring_to_string`

Adding a non-macOS shim for `nsstring_to_string` will allow this crate
and the examples to build on non-macOS platforms.
diff --git a/src/lib.rs b/src/lib.rs
line changes: +6/-0
index 3685e06..ceab61a
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -199,6 +199,12 @@ impl FruitApp {
 /// Docs in OS X build.
 pub fn parse_url_event(_event: *mut u64) -> String { "".into() }
 
+#[cfg(any(not(target_os = "macos"), feature = "dummy"))]
+/// Docs in OS X build.
+pub fn nsstring_to_string(_nsstring: *mut u64) -> String {
+    "".into()
+}
+
 /// API to move the executable into a Mac app bundle and relaunch (if necessary)
 ///
 /// Dummy implementation for non-OSX platforms.  See OS X build for proper