Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Core / CSharp / System / Windows / Input / Stylus / StylusButtonEventArgs.cs / 1 / StylusButtonEventArgs.cs
using System; using System.Collections; using System.ComponentModel; using System.Windows.Media; namespace System.Windows.Input { ///////////////////////////////////////////////////////////////////////// //////Event argument used to subscribe to StylusButtonDown/Up events. ///The only information required to be passed by this argument is which button had the state change. /// public class StylusButtonEventArgs : StylusEventArgs { ///////////////////////////////////////////////////////////////////// ////// Initializes a new instance of the StylusButtonEventArgs class. /// /// /// The logical Stylus device associated with this event. /// /// /// The time when the input occured. /// /// /// The button. /// public StylusButtonEventArgs( StylusDevice stylusDevice, int timestamp, StylusButton button) : base(stylusDevice, timestamp) { // ISSUE_XiaoTu: Do we need any validation here? _button = button; } ////// Get the StylusButton /// public StylusButton StylusButton { get { return _button; } } ///////////////////////////////////////////////////////////////////// ////// 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) { StylusButtonEventHandler handler = (StylusButtonEventHandler)genericHandler; handler(genericTarget, this); } ///////////////////////////////////////////////////////////////////// /// StylusButton _button; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Collections; using System.ComponentModel; using System.Windows.Media; namespace System.Windows.Input { ///////////////////////////////////////////////////////////////////////// //////Event argument used to subscribe to StylusButtonDown/Up events. ///The only information required to be passed by this argument is which button had the state change. /// public class StylusButtonEventArgs : StylusEventArgs { ///////////////////////////////////////////////////////////////////// ////// Initializes a new instance of the StylusButtonEventArgs class. /// /// /// The logical Stylus device associated with this event. /// /// /// The time when the input occured. /// /// /// The button. /// public StylusButtonEventArgs( StylusDevice stylusDevice, int timestamp, StylusButton button) : base(stylusDevice, timestamp) { // ISSUE_XiaoTu: Do we need any validation here? _button = button; } ////// Get the StylusButton /// public StylusButton StylusButton { get { return _button; } } ///////////////////////////////////////////////////////////////////// ////// 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) { StylusButtonEventHandler handler = (StylusButtonEventHandler)genericHandler; handler(genericTarget, this); } ///////////////////////////////////////////////////////////////////// /// StylusButton _button; } } // 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
- DeleteStoreRequest.cs
- DynamicValidatorEventArgs.cs
- FigureParaClient.cs
- SeparatorAutomationPeer.cs
- EventHandlerList.cs
- KnownTypeAttribute.cs
- CodeValidator.cs
- DragEvent.cs
- AddInActivator.cs
- DocumentXPathNavigator.cs
- RoutingSection.cs
- ExpressionEditorAttribute.cs
- _DigestClient.cs
- Slider.cs
- BindingContext.cs
- GPStream.cs
- EntityDataSourceChangedEventArgs.cs
- GridViewUpdatedEventArgs.cs
- UIElement.cs
- ServiceSecurityAuditBehavior.cs
- DesignerSelectionListAdapter.cs
- XPathDocument.cs
- Model3DCollection.cs
- FixedMaxHeap.cs
- DataColumnMapping.cs
- SmiTypedGetterSetter.cs
- Int16KeyFrameCollection.cs
- VirtualDirectoryMappingCollection.cs
- ContentValidator.cs
- XmlDocumentFragment.cs
- AnnotationObservableCollection.cs
- QilReference.cs
- AttributeEmitter.cs
- ReadOnlyCollectionBuilder.cs
- DebugView.cs
- DataGridViewCellStyleConverter.cs
- NotFiniteNumberException.cs
- CssStyleCollection.cs
- SafeSystemMetrics.cs
- InstanceOwnerException.cs
- PathGradientBrush.cs
- XmlBufferReader.cs
- ConstraintConverter.cs
- XmlElementList.cs
- RelationshipConstraintValidator.cs
- SqlRowUpdatingEvent.cs
- NativeMethodsOther.cs
- TransformCryptoHandle.cs
- Italic.cs
- DomNameTable.cs
- ISAPIWorkerRequest.cs
- AdornerPresentationContext.cs
- RotateTransform.cs
- SourceLineInfo.cs
- DataSetMappper.cs
- HyperLinkColumn.cs
- XmlRawWriter.cs
- JsonReader.cs
- SamlEvidence.cs
- ButtonChrome.cs
- FontFamily.cs
- DataServiceResponse.cs
- DispatcherExceptionEventArgs.cs
- DiscoveryClientChannelBase.cs
- XmlSchemaAttributeGroup.cs
- Operand.cs
- WebResourceAttribute.cs
- PreApplicationStartMethodAttribute.cs
- QilLiteral.cs
- Process.cs
- LogFlushAsyncResult.cs
- PriorityBinding.cs
- XmlCountingReader.cs
- WebSysDescriptionAttribute.cs
- NameValueConfigurationCollection.cs
- Publisher.cs
- PropertySegmentSerializer.cs
- XmlUTF8TextReader.cs
- SoapAttributeAttribute.cs
- Ref.cs
- DispatchChannelSink.cs
- DataGridToolTip.cs
- ToolBarPanel.cs
- CallSiteHelpers.cs
- HtmlInputCheckBox.cs
- versioninfo.cs
- PrinterSettings.cs
- ComponentResourceKey.cs
- AssemblyFilter.cs
- DtrList.cs
- XamlSerializerUtil.cs
- StylusSystemGestureEventArgs.cs
- SafeLocalAllocation.cs
- Content.cs
- PartialArray.cs
- InvalidateEvent.cs
- EntitySetBaseCollection.cs
- XmlDataSourceView.cs
- WebPartVerbCollection.cs
- AsyncDataRequest.cs