mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Replace IntPtr.Zero with Handle or HWND
This commit is contained in:
parent
94f0bb961e
commit
6842fcaf44
1 changed files with 2 additions and 2 deletions
|
|
@ -282,7 +282,7 @@ namespace Flow.Launcher.Infrastructure
|
|||
{
|
||||
var hWndDesktop = PInvoke.FindWindowEx(hWnd, HWND.Null, "SHELLDLL_DefView", null);
|
||||
hWndDesktop = PInvoke.FindWindowEx(hWndDesktop, HWND.Null, "SysListView32", "FolderView");
|
||||
if (hWndDesktop.Value != IntPtr.Zero)
|
||||
if (hWndDesktop != HWND.Null)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
|
@ -873,7 +873,7 @@ retry:
|
|||
|
||||
// 4. Open that process
|
||||
hShellProcess = PInvoke.OpenProcess(PROCESS_ACCESS_RIGHTS.PROCESS_QUERY_INFORMATION, false, dwPID);
|
||||
if (hShellProcess == IntPtr.Zero)
|
||||
if (hShellProcess == HANDLE.Null)
|
||||
{
|
||||
errorInfo = $"Can't open desktop shell process: {Marshal.GetLastWin32Error()}";
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Reference in a new issue