diff --git a/source/gui/detail/bedrock_windows.cpp b/source/gui/detail/bedrock_windows.cpp index 58044bb9..a7ccb6c4 100644 --- a/source/gui/detail/bedrock_windows.cpp +++ b/source/gui/detail/bedrock_windows.cpp @@ -1,7 +1,7 @@ /** * A Bedrock Implementation * Nana C++ Library(http://www.nanapro.org) - * Copyright(C) 2003-2019 Jinhao(cnjinhao@hotmail.com) + * Copyright(C) 2003-2020 Jinhao(cnjinhao@hotmail.com) * * Distributed under the Boost Software License, Version 1.0. * (See accompanying file LICENSE_1_0.txt or copy at @@ -1191,9 +1191,7 @@ namespace detail } else if (pointer_wd != root_window) { - DWORD pid = 0; - ::GetWindowThreadProcessId(pointer_wd, &pid); - if (pid == ::GetCurrentProcessId()) + if (::GetWindowThreadProcessId(pointer_wd, nullptr) != ::GetCurrentThreadId()) ::PostMessage(pointer_wd, message, wParam, lParam); } }