mirror of
https://github.com/lightsoutgames/godot-tts
synced 2024-11-22 08:35:58 +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
|
builder
|
||||||
.add_property("can_detect_screen_reader")
|
.add_property("can_detect_screen_reader")
|
||||||
.with_getter(|_: &TTS, _| {
|
.with_getter(|_: &TTS, _| {
|
||||||
#[cfg(windows)]
|
if cfg!(windows) {
|
||||||
return true;
|
true
|
||||||
return false;
|
} else {
|
||||||
|
false
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.done();
|
.done();
|
||||||
builder
|
builder
|
||||||
|
@ -95,7 +97,7 @@ impl TTS {
|
||||||
let tolk = tolk::Tolk::new();
|
let tolk = tolk::Tolk::new();
|
||||||
return tolk.detect_screen_reader().is_some();
|
return tolk.detect_screen_reader().is_some();
|
||||||
}
|
}
|
||||||
return false;
|
false
|
||||||
})
|
})
|
||||||
.done();
|
.done();
|
||||||
builder
|
builder
|
||||||
|
|
Loading…
Reference in New Issue
Block a user