MCPcopy Create free account
hub / github.com/RustOtomeLab/RustEng / from_weak

Method from_weak

src/config/volume.rs:37–47  ·  view source on GitHub ↗
(weak: Weak<MainWindow>)

Source from the content-addressed store, hash-verified

35 }
36
37 pub(crate) fn from_weak(weak: Weak<MainWindow>) -> Self {
38 if let Some(window) = weak.upgrade() {
39 VolumeConfig {
40 main: window.get_main_volume(),
41 bgm: window.get_bgm_volume(),
42 voice: window.get_voice_volume(),
43 }
44 } else {
45 unreachable!()
46 }
47 }
48}
49
50impl Executor {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected