Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Core / CSharp / System / Windows / Input / InputEventArgs.cs / 1 / InputEventArgs.cs
using System.Collections; using System; using System.Security; using MS.Internal.PresentationCore; // for FriendAccessAllowed namespace System.Windows.Input { ////// The InputEventArgs class represents a type of RoutedEventArgs that /// are relevant to all input events. /// [FriendAccessAllowed ] // expose UserInitiated public class InputEventArgs : RoutedEventArgs { ////// Initializes a new instance of the InputEventArgs class. /// /// /// The input device to associate with this event. /// /// /// The time when the input occured. /// public InputEventArgs(InputDevice inputDevice, int timestamp) { /* inputDevice parameter being null is valid*/ /* timestamp parameter is valuetype, need not be checked */ _inputDevice = inputDevice; _timestamp = timestamp; } ////// Read-only access to the input device that initiated this /// event. /// public InputDevice Device { get {return _inputDevice;} internal set {_inputDevice = value;} } ////// Read-only access to the input timestamp. /// public int Timestamp { get {return _timestamp;} } ////// The mechanism used to call the type-specific handler on the /// target. /// /// /// The generic handler to call in a type-specific way. /// /// /// The target to call the handler on. /// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { InputEventHandler handler = (InputEventHandler) genericHandler; handler(genericTarget, this); } private InputDevice _inputDevice; private static int _timestamp; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System.Collections; using System; using System.Security; using MS.Internal.PresentationCore; // for FriendAccessAllowed namespace System.Windows.Input { ////// The InputEventArgs class represents a type of RoutedEventArgs that /// are relevant to all input events. /// [FriendAccessAllowed ] // expose UserInitiated public class InputEventArgs : RoutedEventArgs { ////// Initializes a new instance of the InputEventArgs class. /// /// /// The input device to associate with this event. /// /// /// The time when the input occured. /// public InputEventArgs(InputDevice inputDevice, int timestamp) { /* inputDevice parameter being null is valid*/ /* timestamp parameter is valuetype, need not be checked */ _inputDevice = inputDevice; _timestamp = timestamp; } ////// Read-only access to the input device that initiated this /// event. /// public InputDevice Device { get {return _inputDevice;} internal set {_inputDevice = value;} } ////// Read-only access to the input timestamp. /// public int Timestamp { get {return _timestamp;} } ////// The mechanism used to call the type-specific handler on the /// target. /// /// /// The generic handler to call in a type-specific way. /// /// /// The target to call the handler on. /// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { InputEventHandler handler = (InputEventHandler) genericHandler; handler(genericTarget, this); } private InputDevice _inputDevice; private static int _timestamp; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DataControlReference.cs
- TemplateInstanceAttribute.cs
- AbstractExpressions.cs
- FixUpCollection.cs
- FileDetails.cs
- BlobPersonalizationState.cs
- SimpleRecyclingCache.cs
- FormViewPagerRow.cs
- SelectionProviderWrapper.cs
- OdbcPermission.cs
- KeyNotFoundException.cs
- TCPClient.cs
- RadioButtonAutomationPeer.cs
- QuadraticBezierSegment.cs
- LineMetrics.cs
- EFAssociationProvider.cs
- PageWrapper.cs
- Single.cs
- ResXDataNode.cs
- EmbeddedMailObject.cs
- TimeSpan.cs
- BamlLocalizerErrorNotifyEventArgs.cs
- OperationContextScope.cs
- EntityDataSourceViewSchema.cs
- DataGridSortCommandEventArgs.cs
- PropertyTabChangedEvent.cs
- Connection.cs
- ImageCodecInfo.cs
- ButtonFlatAdapter.cs
- RightsController.cs
- _RequestCacheProtocol.cs
- SafeNativeMethods.cs
- AssemblyAttributesGoHere.cs
- Point3D.cs
- PrimitiveRenderer.cs
- SmiEventSink_DeferedProcessing.cs
- DSASignatureDeformatter.cs
- AudienceUriMode.cs
- HMACRIPEMD160.cs
- TrustDriver.cs
- PathGeometry.cs
- RichTextBox.cs
- PixelShader.cs
- _FtpDataStream.cs
- ToolStripItemDesigner.cs
- GridViewAutoFormat.cs
- DesignerPainter.cs
- LifetimeMonitor.cs
- ObjectDataSourceEventArgs.cs
- CompositeFontInfo.cs
- TraceHwndHost.cs
- SuppressMergeCheckAttribute.cs
- WebPartAddingEventArgs.cs
- ZipIOModeEnforcingStream.cs
- SafeUserTokenHandle.cs
- AutoResetEvent.cs
- Process.cs
- FullTextBreakpoint.cs
- ScriptManagerProxy.cs
- DataServices.cs
- ProfileBuildProvider.cs
- VisualTreeHelper.cs
- ServiceRoute.cs
- AssemblyResourceLoader.cs
- HttpException.cs
- ImageListStreamer.cs
- PointCollectionConverter.cs
- StreamHelper.cs
- FormsAuthenticationCredentials.cs
- _HelperAsyncResults.cs
- WmfPlaceableFileHeader.cs
- IPEndPoint.cs
- ArrayExtension.cs
- Context.cs
- ConfigXmlCDataSection.cs
- SemanticResolver.cs
- Clock.cs
- RotateTransform3D.cs
- XmlSchemaAnyAttribute.cs
- WorkflowApplicationCompletedException.cs
- CodeArgumentReferenceExpression.cs
- HandleDictionary.cs
- CodeDomComponentSerializationService.cs
- SecurityResources.cs
- precedingsibling.cs
- RadioButtonFlatAdapter.cs
- ArraySubsetEnumerator.cs
- UnaryNode.cs
- SqlClientPermission.cs
- XamlInt32CollectionSerializer.cs
- Point4DConverter.cs
- CodeComment.cs
- HttpDebugHandler.cs
- PropertyPathConverter.cs
- SQLBinary.cs
- BoundPropertyEntry.cs
- AdapterDictionary.cs
- MemberAccessException.cs
- SoapFormatExtensions.cs
- Timer.cs