This commit is contained in:
恍兮惚兮 2024-11-15 08:27:40 +08:00
parent 53b87c3cbe
commit 826b179595
3 changed files with 5 additions and 3 deletions

View File

@ -3,9 +3,6 @@ cmake_minimum_required(VERSION 3.16)
project(LunaPlugins)
option(WINXP "WINXP" OFF)
if(WINXP)
add_definitions(-DWINXP=${WINXP})
endif()
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake)

View File

@ -366,6 +366,7 @@ bool tryhookv8()
if (funcsucc)
{
useclipboard = !std::filesystem::exists(std::filesystem::path(getModuleFilename().value()).replace_filename("disable.clipboard"));
#ifndef WINXP
usehttp = !std::filesystem::exists(std::filesystem::path(getModuleFilename().value()).replace_filename("disable.http"));
if (usehttp)
{
@ -374,6 +375,9 @@ bool tryhookv8()
hook_LUNA_CONTENTBYPASS();
dont_detach = true;
}
#else
usehttp = false;
#endif
if (useclipboard)
{
hookClipboard();

View File

@ -51,6 +51,7 @@ endif()
option(WINXP "WINXP" OFF)
if(WINXP)
add_definitions(-DWINXP=${WINXP})
set(YY_Thunks_for_WinXP ${CMAKE_CURRENT_LIST_DIR}/YY-Thunks/objs/X86/YY_Thunks_for_WinXP.obj)
else()
set(YY_Thunks_for_WinXP)