Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
yingDev committed Feb 24, 2016
1 parent 9d45630 commit 6b8cff0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions WGestures.Core/Impl/Windows/MouseHook.cs
Original file line number Diff line number Diff line change
Expand Up @@ -210,12 +210,12 @@ protected virtual IntPtr MouseHookProc(int nCode, IntPtr wParam, IntPtr lParam)
{
if (MouseHookEvent != null)
{
var timeBefore = DateTime.Now;
var timeBefore = DateTime.UtcNow;

MouseHookEvent(args);

var timeElapsed = DateTime.Now - timeBefore;
Debug.WriteLine("MouseHookEvent used time: " + timeElapsed.TotalMilliseconds);
var timeElapsed = DateTime.UtcNow - timeBefore;
//Debug.WriteLine("MouseHookEvent used time: " + timeElapsed.TotalMilliseconds);

//如果用了太长时间,则假定卡住了,重新安装
if(timeElapsed.TotalMilliseconds > 1000)
Expand Down

0 comments on commit 6b8cff0

Please sign in to comment.