mirror of
https://github.com/lightsoutgames/godot-tts
synced 2024-11-08 17:55:56 +00:00
Refactor to cfg!
where possible.
This commit is contained in:
parent
d115470c0d
commit
a4c61a421f
10
src/lib.rs
10
src/lib.rs
|
@ -82,9 +82,11 @@ impl TTS {
|
|||
builder
|
||||
.add_property("can_detect_screen_reader")
|
||||
.with_getter(|_: &TTS, _| {
|
||||
#[cfg(windows)]
|
||||
return true;
|
||||
return false;
|
||||
if cfg!(windows) {
|
||||
true
|
||||
} else {
|
||||
false
|
||||
}
|
||||
})
|
||||
.done();
|
||||
builder
|
||||
|
@ -95,7 +97,7 @@ impl TTS {
|
|||
let tolk = tolk::Tolk::new();
|
||||
return tolk.detect_screen_reader().is_some();
|
||||
}
|
||||
return false;
|
||||
false
|
||||
})
|
||||
.done();
|
||||
builder
|
||||
|
|
Loading…
Reference in New Issue
Block a user