- Clean up implementation of modal window callbacks (issue #281).

- Fix CefBrowser::GoForward documentation typo (issue #291).

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@271 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2011-08-03 15:35:51 +00:00
parent 0f414c8ac8
commit 512b864639
20 changed files with 187 additions and 125 deletions

View File

@ -612,17 +612,15 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
break;
case WM_CLOSE:
// All clients must forward the WM_CLOSE call to all contained browser
// windows to give those windows a chance to cleanup before the window
// closes. Don't forward this message if you are cancelling the request.
if(g_handler.get())
{
HWND hWnd = g_handler->GetBrowserHwnd();
if (hWnd)
::SendMessage(hWnd, WM_CLOSE, 0, 0);
if (g_handler.get()) {
CefRefPtr<CefBrowser> browser = g_handler->GetBrowser();
if (browser.get()) {
// Let the browser window know we are about to destroy it.
browser->ParentWindowWillClose();
}
}
break;
case WM_DESTROY:
// The frame window has exited
PostQuitMessage(0);