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
- QueryContinueDragEventArgs.cs
- SrgsElement.cs
- WebBrowserNavigatingEventHandler.cs
- StrongNameIdentityPermission.cs
- ZipIOCentralDirectoryBlock.cs
- VirtualPathProvider.cs
- MetadataItemSerializer.cs
- RecipientInfo.cs
- HttpCookie.cs
- ItemContainerPattern.cs
- ImageSource.cs
- EventWaitHandleSecurity.cs
- DocumentViewerAutomationPeer.cs
- MultitargetUtil.cs
- EntityDataSourceDesigner.cs
- MarshalDirectiveException.cs
- TrustLevel.cs
- ReadOnlyDataSourceView.cs
- NonBatchDirectoryCompiler.cs
- ValidationEventArgs.cs
- LogEntryHeaderDeserializer.cs
- SecurityDocument.cs
- StringExpressionSet.cs
- Serializer.cs
- EventLogPermissionHolder.cs
- MediaContextNotificationWindow.cs
- InstanceDataCollection.cs
- TextEditorTyping.cs
- BamlBinaryWriter.cs
- MsmqInputChannel.cs
- SizeAnimationBase.cs
- XmlSerializationWriter.cs
- QueryOperator.cs
- FlowDocumentScrollViewerAutomationPeer.cs
- TranslateTransform3D.cs
- TimeSpan.cs
- FontEmbeddingManager.cs
- SqlRewriteScalarSubqueries.cs
- Partitioner.cs
- LoginUtil.cs
- GridView.cs
- MenuStrip.cs
- SigningProgress.cs
- DocumentApplicationJournalEntry.cs
- PageParser.cs
- ScriptManagerProxy.cs
- SQLMembershipProvider.cs
- EventBuilder.cs
- InvalidComObjectException.cs
- CustomAttributeFormatException.cs
- _TransmitFileOverlappedAsyncResult.cs
- HttpClientCertificate.cs
- TimeStampChecker.cs
- RegexGroup.cs
- SqlCacheDependencySection.cs
- MyContact.cs
- XmlCharacterData.cs
- RectConverter.cs
- XslVisitor.cs
- CommentGlyph.cs
- SamlSubject.cs
- OleDbPermission.cs
- TreeNodeEventArgs.cs
- NumericExpr.cs
- TlsnegoTokenProvider.cs
- GlobalizationSection.cs
- XmlWriter.cs
- OrderedDictionaryStateHelper.cs
- MinimizableAttributeTypeConverter.cs
- RepeaterItemCollection.cs
- ViewStateException.cs
- OutputCacheSection.cs
- IApplicationTrustManager.cs
- WhitespaceSignificantCollectionAttribute.cs
- Compiler.cs
- FormatterServicesNoSerializableCheck.cs
- RightsManagementPermission.cs
- ParameterSubsegment.cs
- UrlAuthFailedErrorFormatter.cs
- NativeCppClassAttribute.cs
- DynamicMethod.cs
- DoubleAnimationUsingKeyFrames.cs
- SelectionItemProviderWrapper.cs
- XPathNodeInfoAtom.cs
- StylusTip.cs
- CompatibleComparer.cs
- OracleRowUpdatedEventArgs.cs
- ProgressPage.cs
- PolyQuadraticBezierSegment.cs
- StringWriter.cs
- DBSqlParserColumnCollection.cs
- LongValidatorAttribute.cs
- CheckableControlBaseAdapter.cs
- TableCellCollection.cs
- Size.cs
- XmlExtensionFunction.cs
- SelectionPattern.cs
- DatePickerAutomationPeer.cs
- DetailsViewUpdateEventArgs.cs
- ProxyGenerationError.cs