ntwain/NTwain/Triplets/DGControl/DGControl.DeviceEvent.cs
2014-04-04 07:25:11 -04:00

17 lines
508 B
C#

using NTwain.Data;
using NTwain.Values;
using System;
namespace NTwain.Triplets
{
public sealed class DeviceEvent : OpBase
{
internal DeviceEvent(ITwainSessionInternal session) : base(session) { }
public ReturnCode Get(out TWDeviceEvent sourceDeviceEvent)
{
Session.VerifyState(4, 7, DataGroups.Control, DataArgumentType.DeviceEvent, Message.Get);
sourceDeviceEvent = new TWDeviceEvent();
return PInvoke.DsmEntry(Session.AppId, Session.SourceId, Message.Get, sourceDeviceEvent);
}
}
}