Made it possible to create event args externally for testing.

This commit is contained in:
soukoku
2014-09-12 07:16:10 -04:00
parent 81710b7e99
commit 0cd02ac16e
10 changed files with 245 additions and 161 deletions

View File

@@ -113,7 +113,6 @@ namespace NTwain
//{
System.Windows.Forms.Application.RemoveMessageFilter(this);
_filter = null;
Handle = IntPtr.Zero;
//});
}
@@ -191,9 +190,9 @@ namespace NTwain
if (_hooker != null)
{
_hooker.RemoveHook(FilterMessage);
_hooker.Dispose();
// cannot really dispose _hook or the window will also dispose
//_hooker.Dispose();
_hooker = null;
Handle = IntPtr.Zero;
}
}
}