mirror of https://github.com/ndarilek/tts-rs.git
Cast the bool to i8 for Apple Silicon
This commit is contained in:
parent
42879dfa1f
commit
abd97ebf73
|
@ -196,6 +196,18 @@ impl Backend for AppKit {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[cfg(target_arch = "aarch64")]
|
||||||
|
fn is_speaking(&self) -> Result<bool, Error> {
|
||||||
|
let is_speaking: i8 = unsafe { msg_send![self.0, isSpeaking] };
|
||||||
|
Ok(is_speaking == YES as i8)
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(target_arch = "x86")]
|
||||||
|
#[cfg(target_arch = "x86_64")]
|
||||||
|
#[cfg(target_arch = "mips")]
|
||||||
|
#[cfg(target_arch = "powerpc")]
|
||||||
|
#[cfg(target_arch = "powerpc64")]
|
||||||
|
#[cfg(target_arch = "arm")]
|
||||||
fn is_speaking(&self) -> Result<bool, Error> {
|
fn is_speaking(&self) -> Result<bool, Error> {
|
||||||
let is_speaking: i8 = unsafe { msg_send![self.0, isSpeaking] };
|
let is_speaking: i8 = unsafe { msg_send![self.0, isSpeaking] };
|
||||||
Ok(is_speaking == YES)
|
Ok(is_speaking == YES)
|
||||||
|
|
Loading…
Reference in New Issue