mirror of
https://gitlab.com/gabmus/envision.git
synced 2025-09-25 18:58:38 +00:00
fix: prefer from trait over into
This commit is contained in:
parent
4029b4fae5
commit
e3ee44b1c4
2 changed files with 12 additions and 11 deletions
|
@ -139,6 +139,7 @@ pub fn set_current_active_runtime_to_profile(profile: &Profile) -> anyhow::Resul
|
||||||
let dest = get_active_runtime_json_path();
|
let dest = get_active_runtime_json_path();
|
||||||
set_file_readonly(&dest, false)?;
|
set_file_readonly(&dest, false)?;
|
||||||
backup_steam_active_runtime();
|
backup_steam_active_runtime();
|
||||||
|
// TODO: need to escape path spaces here?
|
||||||
let pfx = profile.clone().prefix;
|
let pfx = profile.clone().prefix;
|
||||||
let mut ar = build_profile_active_runtime(profile)?;
|
let mut ar = build_profile_active_runtime(profile)?;
|
||||||
// hack: relativize libopenxr_monado.so path for system installs
|
// hack: relativize libopenxr_monado.so path for system installs
|
||||||
|
|
|
@ -62,11 +62,11 @@ impl From<u32> for XRServiceType {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Into<u32> for XRServiceType {
|
impl From<&XRServiceType> for u32 {
|
||||||
fn into(self) -> u32 {
|
fn from(value: &XRServiceType) -> Self {
|
||||||
match self {
|
match value {
|
||||||
Self::Monado => 0,
|
XRServiceType::Monado => 0,
|
||||||
Self::Wivrn => 1,
|
XRServiceType::Wivrn => 1,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -215,12 +215,12 @@ impl From<u32> for LighthouseDriver {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Into<u32> for LighthouseDriver {
|
impl From<&LighthouseDriver> for u32 {
|
||||||
fn into(self) -> u32 {
|
fn from(value: &LighthouseDriver) -> Self {
|
||||||
match self {
|
match value {
|
||||||
Self::Vive => 0,
|
LighthouseDriver::Vive => 0,
|
||||||
Self::Survive => 1,
|
LighthouseDriver::Survive => 1,
|
||||||
Self::SteamVR => 2,
|
LighthouseDriver::SteamVR => 2,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue