Skip to content

Commit

Permalink
added more logging
Browse files Browse the repository at this point in the history
  • Loading branch information
= committed Sep 7, 2024
1 parent a047765 commit f37cf6d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/display/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ fn get_primary_display_adapter() -> Result<DISPLAY_DEVICEW> {
}
return Ok(display_adapter);
}
Err("Could not get primary display device!".into())
Err("Could not get primary display adapter!".into())
}

fn get_current_display_mode(monitor_name: PCWSTR) -> Result<DEVMODEW> {
Expand Down Expand Up @@ -138,6 +138,7 @@ fn get_closest_match_display_mode(mode: RefreshRateMode) -> Result<DEVMODEW> {
}

pub fn set_display_refresh_rate(mode: RefreshRateMode) -> Result<()> {
LOGGER.debug(format!("Setting display refresh rate to {:?}...", mode));
let new_mode = get_closest_match_display_mode(mode)?;
unsafe {
let flags = ChangeDisplaySettingsW(Some(&new_mode), CDS_TYPE(0));
Expand Down

0 comments on commit f37cf6d

Please sign in to comment.