mirror of
https://github.com/QL-Win/QuickLook.git
synced 2025-09-26 20:21:36 +00:00
abstract plugin interface
This commit is contained in:
@@ -65,7 +65,8 @@ void DOpus::GetSelected(PWCHAR buffer)
|
||||
cds.cbData = static_cast<DWORD>(wcslen(data) + 1) * sizeof WCHAR;
|
||||
cds.lpData = data;
|
||||
|
||||
auto ret = SendMessage(FindWindow(DOPUS_CLASS, DOPUS_NAME), WM_COPYDATA, reinterpret_cast<WPARAM>(hMsgWnd), reinterpret_cast<LPARAM>(&cds));
|
||||
auto ret = SendMessage(FindWindow(DOPUS_CLASS, DOPUS_NAME), WM_COPYDATA, reinterpret_cast<WPARAM>(hMsgWnd),
|
||||
reinterpret_cast<LPARAM>(&cds));
|
||||
if (!ret)
|
||||
return;
|
||||
|
||||
|
@@ -99,7 +99,8 @@ void DialogHook::GetSelectedFromWoW64HookHelper(PWCHAR buffer)
|
||||
if (hHelperWnd == nullptr)
|
||||
return;
|
||||
|
||||
auto hMapFile = CreateFileMapping(INVALID_HANDLE_VALUE, nullptr, PAGE_READWRITE, 0, MAX_PATH * sizeof WCHAR, SHARED_MEM_NAME);
|
||||
auto hMapFile = CreateFileMapping(INVALID_HANDLE_VALUE, nullptr, PAGE_READWRITE, 0, MAX_PATH * sizeof WCHAR,
|
||||
SHARED_MEM_NAME);
|
||||
if (hMapFile == nullptr)
|
||||
return;
|
||||
|
||||
|
@@ -142,7 +142,8 @@ void Shell32::getSelectedFromDesktop(PWCHAR buffer)
|
||||
VARIANT pvarLoc;
|
||||
VariantInit(&pvarLoc);
|
||||
long phwnd;
|
||||
if (FAILED(psw->FindWindowSW(&pvarLoc, &pvarLoc, SWC_DESKTOP, &phwnd, SWFO_NEEDDISPATCH, reinterpret_cast<IDispatch**>(&pwba))))
|
||||
if (FAILED(psw->FindWindowSW(&pvarLoc, &pvarLoc, SWC_DESKTOP, &phwnd, SWFO_NEEDDISPATCH, reinterpret_cast<IDispatch**>(
|
||||
&pwba))))
|
||||
return;
|
||||
|
||||
if (HelperMethods::IsCursorActivated(reinterpret_cast<HWND>(LongToHandle(phwnd))))
|
||||
|
@@ -75,5 +75,6 @@ void WoW64HookHelper::createJob()
|
||||
JOBOBJECT_EXTENDED_LIMIT_INFORMATION lpJobObjectInfo = {sizeof lpJobObjectInfo};
|
||||
lpJobObjectInfo.BasicLimitInformation = BasicLimitInformation;
|
||||
|
||||
SetInformationJobObject(hJob, JobObjectExtendedLimitInformation, &lpJobObjectInfo, sizeof JOBOBJECT_EXTENDED_LIMIT_INFORMATION);
|
||||
SetInformationJobObject(hJob, JobObjectExtendedLimitInformation, &lpJobObjectInfo,
|
||||
sizeof JOBOBJECT_EXTENDED_LIMIT_INFORMATION);
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -34,9 +34,9 @@ HWND hMsgWindow = nullptr;
|
||||
UINT WM_HOOK_NOTIFY = 0;
|
||||
|
||||
int APIENTRY wWinMain(_In_ HINSTANCE hInstance,
|
||||
_In_opt_ HINSTANCE hPrevInstance,
|
||||
_In_ LPWSTR lpCmdLine,
|
||||
_In_ int nCmdShow)
|
||||
_In_opt_ HINSTANCE hPrevInstance,
|
||||
_In_ LPWSTR lpCmdLine,
|
||||
_In_ int nCmdShow)
|
||||
{
|
||||
// do not run when double-clicking
|
||||
if (wcsstr(GetCommandLine(), RUN_ARG) == nullptr)
|
||||
|
Reference in New Issue
Block a user