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
- ExceptionHelpers.cs
- DynamicScriptObject.cs
- SafeCancelMibChangeNotify.cs
- ItemsChangedEventArgs.cs
- Deserializer.cs
- ObjectListCommandEventArgs.cs
- UseLicense.cs
- MetadataSource.cs
- CodeRegionDirective.cs
- Size.cs
- SettingsProviderCollection.cs
- TextOnlyOutput.cs
- TrackingRecord.cs
- QuaternionRotation3D.cs
- DropSource.cs
- AssemblySettingAttributes.cs
- RSAPKCS1KeyExchangeFormatter.cs
- AutoCompleteStringCollection.cs
- DataTableClearEvent.cs
- brushes.cs
- XmlCharacterData.cs
- WebRequestModulesSection.cs
- ValidationError.cs
- EventRoute.cs
- MarginsConverter.cs
- CodeCommentStatementCollection.cs
- DocumentViewerHelper.cs
- GeneralTransform3DTo2D.cs
- KeyEventArgs.cs
- DataGridAddNewRow.cs
- JobCollate.cs
- ConversionHelper.cs
- Listener.cs
- ConfigurationCollectionAttribute.cs
- DetailsViewDeleteEventArgs.cs
- BoundColumn.cs
- ActivityDesignerResources.cs
- TabletDeviceInfo.cs
- ClientRuntimeConfig.cs
- TabControl.cs
- Keyboard.cs
- CodeDelegateCreateExpression.cs
- TdsParserStaticMethods.cs
- ComponentRenameEvent.cs
- TraceProvider.cs
- Object.cs
- EditingCommands.cs
- SoapEnumAttribute.cs
- UIElementCollection.cs
- FieldNameLookup.cs
- ContractNamespaceAttribute.cs
- XmlStreamStore.cs
- SqlCrossApplyToCrossJoin.cs
- RegexRunnerFactory.cs
- CellLabel.cs
- WorkflowApplicationTerminatedException.cs
- _NegotiateClient.cs
- DockPatternIdentifiers.cs
- BitmapEffectInputConnector.cs
- DESCryptoServiceProvider.cs
- Unit.cs
- ServiceOperationParameter.cs
- RuleSetBrowserDialog.cs
- FileDialogCustomPlace.cs
- ByteAnimationBase.cs
- TcpTransportManager.cs
- DeviceContexts.cs
- Bidi.cs
- XPathDocumentIterator.cs
- WindowsGraphicsWrapper.cs
- ProfileServiceManager.cs
- BufferedOutputStream.cs
- IndexerNameAttribute.cs
- HttpListenerContext.cs
- BamlStream.cs
- PopOutPanel.cs
- SqlDataSourceEnumerator.cs
- DelayedRegex.cs
- DataControlField.cs
- MouseWheelEventArgs.cs
- _LocalDataStore.cs
- GeometryCollection.cs
- PenContext.cs
- OperationPickerDialog.cs
- EmptyReadOnlyDictionaryInternal.cs
- elementinformation.cs
- DbProviderSpecificTypePropertyAttribute.cs
- XmlArrayAttribute.cs
- CultureInfoConverter.cs
- BitmapEffectOutputConnector.cs
- ItemCollection.cs
- OraclePermission.cs
- WebPartCollection.cs
- Clock.cs
- RawStylusInputReport.cs
- CryptographicAttribute.cs
- DecimalKeyFrameCollection.cs
- HttpApplicationFactory.cs
- Helpers.cs
- StylusEditingBehavior.cs