Relaxed the Window caption setting in order to avoid problems with threaded applications or external windows.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@1604 dfc29bdd-3216-0410-991c-e03cc46cb475master
parent
28dbc4bec4
commit
ba581fddd0
|
@ -602,21 +602,24 @@ void CIrrDeviceWin32::resizeIfNecessary()
|
|||
}
|
||||
|
||||
|
||||
|
||||
//! sets the caption of the window
|
||||
void CIrrDeviceWin32::setWindowCaption(const wchar_t* text)
|
||||
{
|
||||
DWORD dwResult;
|
||||
if (IsNonNTWindows)
|
||||
{
|
||||
core::stringc s = text;
|
||||
SetWindowTextA(HWnd, s.c_str());
|
||||
const core::stringc s = text;
|
||||
SendMessageTimeout(HWnd, WM_SETTEXT, 0,
|
||||
reinterpret_cast<LPARAM>(s.c_str()),
|
||||
SMTO_ABORTIFHUNG, 2000, &dwResult);
|
||||
}
|
||||
else
|
||||
SetWindowTextW(HWnd, text);
|
||||
SendMessageTimeoutW(HWnd, WM_SETTEXT, 0,
|
||||
reinterpret_cast<LPARAM>(text),
|
||||
SMTO_ABORTIFHUNG, 2000, &dwResult);
|
||||
}
|
||||
|
||||
|
||||
|
||||
//! presents a surface in the client area
|
||||
bool CIrrDeviceWin32::present(video::IImage* image, void* windowId, core::rect<s32>* src)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue