mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 13:30:02 +00:00
Avoid a "pure call" issue.
This commit is contained in:
parent
cfb50bf4d6
commit
2251b0dd59
@ -8,11 +8,13 @@ Dialog::Dialog(LPCSTR res, HINSTANCE _hInstance, HWND _hParent)
|
||||
m_hInstance = _hInstance;
|
||||
m_hParent = _hParent;
|
||||
m_hResource=res;
|
||||
m_bValid = true;
|
||||
Create();
|
||||
}
|
||||
|
||||
Dialog::~Dialog()
|
||||
{
|
||||
m_bValid = false;
|
||||
Destroy();
|
||||
}
|
||||
|
||||
@ -38,7 +40,7 @@ void Dialog::Show(bool _bShow)
|
||||
INT_PTR Dialog::DlgProcStatic(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
Dialog *dis = (Dialog*)GetWindowLongPtr(hdlg, GWLP_USERDATA);
|
||||
if (dis)
|
||||
if (dis && dis->m_bValid)
|
||||
return dis->DlgProc(message,wParam,lParam);
|
||||
else
|
||||
{
|
||||
|
@ -9,6 +9,7 @@ protected:
|
||||
HWND m_hParent;
|
||||
HWND m_hDlg;
|
||||
LPCSTR m_hResource;
|
||||
bool m_bValid;
|
||||
|
||||
virtual BOOL DlgProc(UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user