Increase Windows cefclient timer speed so that CefDoMessageLoopWork() is called more frequently in single-threaded message loop mode (issue #189).

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@193 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2011-02-23 15:33:44 +00:00
parent 6ca5cff06c
commit 7684d7442e

View File

@@ -368,8 +368,11 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
static_cast<CefRefPtr<CefHandler> >(g_handler), static_cast<CefRefPtr<CefHandler> >(g_handler),
"http://www.google.com"); "http://www.google.com");
// Start the timer that will be used to update child window state // Start the timer that will be used to update child window state. The
SetTimer(hWnd, 1, 250, NULL); // timer is also necessary in single-threaded message loop mode so that
// CefDoMessageLoopWork() is called frequently enough for things like
// smooth JavaScript animation.
SetTimer(hWnd, 1, USER_TIMER_MINIMUM, NULL);
} }
return 0; return 0;