Bug 511167 - WINCE -> WINCE_WINDOWS_MOBILE for Increase the thread priority between mouse down and mouse up. r=vlad

This commit is contained in:
Doug Turner 2009-08-27 13:11:04 -07:00
Родитель 8209e9878f
Коммит b5b90f973e
1 изменённых файлов: 7 добавлений и 4 удалений

Просмотреть файл

@ -154,6 +154,9 @@
#if defined(WINCE) #if defined(WINCE)
#include "nsWindowCE.h" #include "nsWindowCE.h"
#endif
#if defined(WINCE_WINDOWS_MOBILE)
#define KILL_PRIORITY_ID 2444 #define KILL_PRIORITY_ID 2444
#endif #endif
@ -3859,16 +3862,16 @@ PRBool nsWindow::ProcessMessage(UINT msg, WPARAM &wParam, LPARAM &lParam,
} }
break; break;
#ifdef WINCE_WINDOWS_MOBILE
case WM_TIMER: case WM_TIMER:
#ifdef WINCE
SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_NORMAL); SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_NORMAL);
KillTimer(mWnd, KILL_PRIORITY_ID); KillTimer(mWnd, KILL_PRIORITY_ID);
#endif
break; break;
#endif
case WM_LBUTTONDOWN: case WM_LBUTTONDOWN:
{ {
#ifdef WINCE #ifdef WINCE_WINDOWS_MOBILE
SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_ABOVE_NORMAL); SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_ABOVE_NORMAL);
SetTimer(mWnd, KILL_PRIORITY_ID, 2000 /* 2 seconds */, NULL); SetTimer(mWnd, KILL_PRIORITY_ID, 2000 /* 2 seconds */, NULL);
#endif #endif
@ -3884,7 +3887,7 @@ PRBool nsWindow::ProcessMessage(UINT msg, WPARAM &wParam, LPARAM &lParam,
PR_FALSE, nsMouseEvent::eLeftButton); PR_FALSE, nsMouseEvent::eLeftButton);
DispatchPendingEvents(); DispatchPendingEvents();
#ifdef WINCE #ifdef WINCE_WINDOWS_MOBILE
SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_NORMAL); SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_NORMAL);
KillTimer(mWnd, KILL_PRIORITY_ID); KillTimer(mWnd, KILL_PRIORITY_ID);
#endif #endif