mirror of
https://github.com/ndarilek/tts-rs.git
synced 2024-11-01 00:09:37 +00:00
Compare commits
4 Commits
cf72bad59a
...
359b1c8053
Author | SHA1 | Date | |
---|---|---|---|
359b1c8053 | |||
527b4cd61e | |||
97fa370dec | |||
915673eec6 |
|
@ -26,7 +26,7 @@ serde = { version = "1", optional = true, features = ["derive"] }
|
||||||
thiserror = "1"
|
thiserror = "1"
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
env_logger = "0.9"
|
env_logger = "0.10"
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies]
|
[target.'cfg(windows)'.dependencies]
|
||||||
tolk = { version = "0.5", optional = true }
|
tolk = { version = "0.5", optional = true }
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#[cfg(any(target_os = "macos", target_os = "ios"))]
|
#[cfg(any(target_os = "macos", target_os = "ios"))]
|
||||||
use std::{str::FromStr, sync::Mutex};
|
use std::sync::Mutex;
|
||||||
|
|
||||||
use cocoa_foundation::base::{id, nil, NO};
|
use cocoa_foundation::base::{id, nil, NO};
|
||||||
use cocoa_foundation::foundation::NSString;
|
use cocoa_foundation::foundation::NSString;
|
||||||
|
@ -10,7 +10,7 @@ use lazy_static::lazy_static;
|
||||||
use log::{info, trace};
|
use log::{info, trace};
|
||||||
use objc::runtime::{Object, Sel};
|
use objc::runtime::{Object, Sel};
|
||||||
use objc::{class, declare::ClassDecl, msg_send, sel, sel_impl};
|
use objc::{class, declare::ClassDecl, msg_send, sel, sel_impl};
|
||||||
use unic_langid::LanguageIdentifier;
|
use oxilangtag::LanguageTag;
|
||||||
|
|
||||||
use crate::{Backend, BackendId, Error, Features, Gender, UtteranceId, Voice, CALLBACKS};
|
use crate::{Backend, BackendId, Error, Features, Gender, UtteranceId, Voice, CALLBACKS};
|
||||||
|
|
||||||
|
@ -312,7 +312,7 @@ impl Backend for AvFoundation {
|
||||||
CFString::wrap_under_get_rule(msg_send![*v as *const Object, language])
|
CFString::wrap_under_get_rule(msg_send![*v as *const Object, language])
|
||||||
};
|
};
|
||||||
let language = language.to_string();
|
let language = language.to_string();
|
||||||
let language = LanguageIdentifier::from_str(&language).unwrap();
|
let language = LanguageTag::from_str(&language).unwrap();
|
||||||
Voice {
|
Voice {
|
||||||
id: id.to_string(),
|
id: id.to_string(),
|
||||||
name: name.to_string(),
|
name: name.to_string(),
|
||||||
|
|
Loading…
Reference in New Issue
Block a user