Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Core / CSharp / System / Windows / Input / InputEventArgs.cs / 1305600 / 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
- DoubleAnimation.cs
- MsmqChannelFactory.cs
- PathSegment.cs
- ScrollViewerAutomationPeer.cs
- ConvertersCollection.cs
- FixedTextSelectionProcessor.cs
- MetadataUtil.cs
- ActivityCodeDomSerializer.cs
- SizeValueSerializer.cs
- RequestCachePolicy.cs
- HyperLink.cs
- ImageListStreamer.cs
- XamlPointCollectionSerializer.cs
- CounterCreationData.cs
- XPathDocumentNavigator.cs
- jithelpers.cs
- CodeStatementCollection.cs
- EdgeProfileValidation.cs
- WrapPanel.cs
- TextEditorCharacters.cs
- EpmContentDeSerializerBase.cs
- InternalsVisibleToAttribute.cs
- TemplateControl.cs
- XmlAttributes.cs
- BasePropertyDescriptor.cs
- NetPipeSectionData.cs
- TreeNode.cs
- ChangeConflicts.cs
- TextRangeEdit.cs
- ControlPaint.cs
- FormatVersion.cs
- MostlySingletonList.cs
- GraphicsState.cs
- VariantWrapper.cs
- Label.cs
- MetabaseServerConfig.cs
- XmlSchemaGroup.cs
- Attributes.cs
- SecurityHeaderLayout.cs
- IFlowDocumentViewer.cs
- XmlDocumentType.cs
- SystemWebExtensionsSectionGroup.cs
- RectAnimationUsingKeyFrames.cs
- DataSourceExpressionCollection.cs
- TableDetailsCollection.cs
- MsmqIntegrationElement.cs
- MemberPath.cs
- AttachedAnnotationChangedEventArgs.cs
- ResXDataNode.cs
- InternalConfigRoot.cs
- CompatibleComparer.cs
- FillErrorEventArgs.cs
- Point4D.cs
- PasswordTextContainer.cs
- XmlSchemaObjectCollection.cs
- AsyncOperationLifetimeManager.cs
- SqlMethodAttribute.cs
- UpDownEvent.cs
- WCFModelStrings.Designer.cs
- DoubleAnimationUsingKeyFrames.cs
- OdbcConnectionFactory.cs
- SiteMapPath.cs
- TransformerInfoCollection.cs
- SamlSubject.cs
- SafeNativeMethods.cs
- DBSchemaRow.cs
- SafeEventHandle.cs
- CustomWebEventKey.cs
- MasterPageCodeDomTreeGenerator.cs
- SqlPersonalizationProvider.cs
- ExceptQueryOperator.cs
- TextTreeRootTextBlock.cs
- StoreAnnotationsMap.cs
- ThreadStartException.cs
- RSAOAEPKeyExchangeFormatter.cs
- InheritedPropertyDescriptor.cs
- Security.cs
- ToolStripPanelDesigner.cs
- URLAttribute.cs
- ForEach.cs
- PropertyMapper.cs
- DataStreams.cs
- Calendar.cs
- AxHostDesigner.cs
- EntityStoreSchemaGenerator.cs
- CultureNotFoundException.cs
- ThreadExceptionDialog.cs
- Visual.cs
- ListView.cs
- UnmanagedMemoryStreamWrapper.cs
- LocatorBase.cs
- BrushValueSerializer.cs
- BoundField.cs
- MediaSystem.cs
- TimeSpan.cs
- HashSetEqualityComparer.cs
- SQLBytesStorage.cs
- ChtmlTextWriter.cs
- ComplexBindingPropertiesAttribute.cs
- UnsafePeerToPeerMethods.cs