From 1e990bdfdc2ba24234c0a4103786449596b03079 Mon Sep 17 00:00:00 2001 From: Takase <20792268+takase1121@users.noreply.github.com> Date: Thu, 9 Mar 2023 21:58:32 +0800 Subject: [PATCH] refactor(main): move SetProcessDPIAware to manifests (#1413) --- resources/windows/lite-xl.exe.manifest.in | 7 +++++++ src/main.c | 6 +----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/resources/windows/lite-xl.exe.manifest.in b/resources/windows/lite-xl.exe.manifest.in index 9e787587..a01ac8d2 100644 --- a/resources/windows/lite-xl.exe.manifest.in +++ b/resources/windows/lite-xl.exe.manifest.in @@ -24,6 +24,13 @@ /> + + + + true + + + diff --git a/src/main.c b/src/main.c index c5e15707..7bc57b6e 100644 --- a/src/main.c +++ b/src/main.c @@ -120,11 +120,7 @@ void set_macos_bundle_resources(lua_State *L); #endif int main(int argc, char **argv) { -#ifdef _WIN32 - HINSTANCE lib = LoadLibrary("user32.dll"); - int (*SetProcessDPIAware)() = (void*) GetProcAddress(lib, "SetProcessDPIAware"); - SetProcessDPIAware(); -#else +#ifndef _WIN32 signal(SIGPIPE, SIG_IGN); #endif