diff --git a/libmwemu/src/winapi64/user32.rs b/libmwemu/src/winapi64/user32.rs index d7e76b2..8d5d8fd 100644 --- a/libmwemu/src/winapi64/user32.rs +++ b/libmwemu/src/winapi64/user32.rs @@ -8,6 +8,7 @@ pub fn gateway(addr: u64, emu: &mut emu::Emu) -> String { "MessageBoxA" => MessageBoxA(emu), "GetDesktopWindow" => GetDesktopWindow(emu), "GetSystemMetrics" => GetSystemMetrics(emu), + "SystemParametersInfoA" => SystemParametersInfoA(emu), _ => { if emu.cfg.skip_unimplemented == false { if emu.cfg.dump_on_exit && emu.cfg.dump_filename.is_some() { @@ -70,4 +71,17 @@ fn GetSystemMetrics(emu: &mut emu::Emu) { emu.regs.rax = 0; } +/* +BOOL SystemParametersInfoA( + [in] UINT uiAction, + [in] UINT uiParam, + [in, out] PVOID pvParam, + [in] UINT fWinIni +); +*/ +fn SystemParametersInfoA(emu: &mut emu::Emu) { + log_red!(emu, "** {} user32!SystemParametersInfoA", emu.pos); + // TODO: write pvParam + emu.regs.rax = 1; +} diff --git a/libmwemu/src/winapi64/uxtheme.rs b/libmwemu/src/winapi64/uxtheme.rs index 3b35eb6..b04b7bc 100644 --- a/libmwemu/src/winapi64/uxtheme.rs +++ b/libmwemu/src/winapi64/uxtheme.rs @@ -6,6 +6,8 @@ pub fn gateway(addr: u64, emu: &mut emu::Emu) -> String { let api = winapi64::kernel32::guess_api_name(emu, addr); match api.as_str() { "IsAppThemed" => IsAppThemed(emu), + "IsThemeActive" => IsThemeActive(emu), + "GetThemeAppProperties" => GetThemeAppProperties(emu), _ => { if emu.cfg.skip_unimplemented == false { if emu.cfg.dump_on_exit && emu.cfg.dump_filename.is_some() { @@ -22,6 +24,18 @@ pub fn gateway(addr: u64, emu: &mut emu::Emu) -> String { } fn IsAppThemed(emu: &mut emu::Emu) { + log_red!(emu, "** {} uxtheme!IsAppThemed", emu.pos); emu.regs.rax = 1; } +fn IsThemeActive(emu: &mut emu::Emu) { + log_red!(emu, "** {} uxtheme!IsThemeActive", emu.pos); + emu.regs.rax = 1; +} + +fn GetThemeAppProperties(emu: &mut emu::Emu) { + log_red!(emu, "** {} uxtheme!GetThemeAppProperties", emu.pos); + emu.regs.rax = 1; +} + +