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
- DataTableMapping.cs
- XmlSchemaInferenceException.cs
- HttpCookieCollection.cs
- TextElementCollectionHelper.cs
- RSAPKCS1KeyExchangeFormatter.cs
- XmlEventCache.cs
- _ConnectStream.cs
- Calendar.cs
- OptionUsage.cs
- BaseParaClient.cs
- NativeCppClassAttribute.cs
- StringFreezingAttribute.cs
- SqlAliasesReferenced.cs
- MemberListBinding.cs
- Cursor.cs
- TypedRowGenerator.cs
- InvalidDocumentContentsException.cs
- RtfNavigator.cs
- MemberAssignment.cs
- WebBrowserUriTypeConverter.cs
- Cursors.cs
- Proxy.cs
- HMACSHA384.cs
- TimeSpanFormat.cs
- CellNormalizer.cs
- SplitterPanelDesigner.cs
- BindingNavigator.cs
- Site.cs
- ParserStack.cs
- VolatileEnlistmentState.cs
- CssTextWriter.cs
- NotifyInputEventArgs.cs
- SymLanguageVendor.cs
- HttpModulesSection.cs
- PeerNameResolver.cs
- QilTernary.cs
- SmiContextFactory.cs
- RepeaterItemCollection.cs
- List.cs
- QueryExpr.cs
- XpsFilter.cs
- ConfigXmlReader.cs
- GridToolTip.cs
- ExpressionBindingCollection.cs
- ConfigXmlWhitespace.cs
- BezierSegment.cs
- CachedBitmap.cs
- NameGenerator.cs
- LicenseContext.cs
- HttpListenerRequest.cs
- SqlDesignerDataSourceView.cs
- OdbcEnvironment.cs
- UInt64Converter.cs
- HitTestDrawingContextWalker.cs
- FieldTemplateUserControl.cs
- ToolTipService.cs
- PackageRelationship.cs
- PropertyBuilder.cs
- XamlSerializerUtil.cs
- PropertyKey.cs
- XmlTextAttribute.cs
- SpotLight.cs
- DynamicHyperLink.cs
- WindowsSolidBrush.cs
- InvalidComObjectException.cs
- IndividualDeviceConfig.cs
- DataContractSet.cs
- SecurityContextSecurityTokenParameters.cs
- WrappedIUnknown.cs
- SpotLight.cs
- ClientCultureInfo.cs
- ByteBufferPool.cs
- FusionWrap.cs
- ScriptingAuthenticationServiceSection.cs
- TextParagraph.cs
- Vector3DAnimationUsingKeyFrames.cs
- RemotingAttributes.cs
- CharConverter.cs
- SAPIEngineTypes.cs
- LifetimeServices.cs
- EncryptedXml.cs
- RawUIStateInputReport.cs
- Rect3DValueSerializer.cs
- PathNode.cs
- TextWriterTraceListener.cs
- EventTrigger.cs
- ProbeMatchesMessage11.cs
- RedirectionProxy.cs
- HttpListenerException.cs
- RecognizedAudio.cs
- FormViewDeleteEventArgs.cs
- ZoneButton.cs
- CodeAttributeArgument.cs
- MemberRelationshipService.cs
- ActivationArguments.cs
- UIPropertyMetadata.cs
- SignatureToken.cs
- ButtonColumn.cs
- DashStyles.cs
- XPathPatternBuilder.cs