Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Framework / System / Windows / Controls / Primitives / DragDeltaEventArgs.cs / 1 / DragDeltaEventArgs.cs
using System; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows; namespace System.Windows.Controls.Primitives { ////// This DragDeltaEventArgs class contains additional information about the /// DragDeltaEvent event. /// ////// public class DragDeltaEventArgs: RoutedEventArgs { /// /// This is an instance constructor for the DragDeltaEventArgs class. It /// is constructed with a reference to the event being raised. /// ///Nothing. public DragDeltaEventArgs(double horizontalChange, double verticalChange) : base() { _horizontalChange = horizontalChange; _verticalChange = verticalChange; RoutedEvent=Thumb.DragDeltaEvent; } ////// Read-only access to the horizontal change. /// public double HorizontalChange { get { return _horizontalChange; } } ////// Read-only access to the vertical change. /// public double VerticalChange { get { return _verticalChange; } } ////// This method is used to perform the proper type casting in order to /// call the type-safe DragDeltaEventHandler delegate for the DragDeltaEvent event. /// /// The handler to invoke. /// The current object along the event's route. ///Nothing. ////// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { DragDeltaEventHandler handler = (DragDeltaEventHandler)genericHandler; handler(genericTarget, this); } private double _horizontalChange; private double _verticalChange; } /// /// This delegate must used by handlers of the DragDeltaEvent event. /// /// The current element along the event's route. /// The event arguments containing additional information about the event. ///Nothing. public delegate void DragDeltaEventHandler(object sender, DragDeltaEventArgs e); } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows; namespace System.Windows.Controls.Primitives { ////// This DragDeltaEventArgs class contains additional information about the /// DragDeltaEvent event. /// ////// public class DragDeltaEventArgs: RoutedEventArgs { /// /// This is an instance constructor for the DragDeltaEventArgs class. It /// is constructed with a reference to the event being raised. /// ///Nothing. public DragDeltaEventArgs(double horizontalChange, double verticalChange) : base() { _horizontalChange = horizontalChange; _verticalChange = verticalChange; RoutedEvent=Thumb.DragDeltaEvent; } ////// Read-only access to the horizontal change. /// public double HorizontalChange { get { return _horizontalChange; } } ////// Read-only access to the vertical change. /// public double VerticalChange { get { return _verticalChange; } } ////// This method is used to perform the proper type casting in order to /// call the type-safe DragDeltaEventHandler delegate for the DragDeltaEvent event. /// /// The handler to invoke. /// The current object along the event's route. ///Nothing. ////// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { DragDeltaEventHandler handler = (DragDeltaEventHandler)genericHandler; handler(genericTarget, this); } private double _horizontalChange; private double _verticalChange; } /// /// This delegate must used by handlers of the DragDeltaEvent event. /// /// The current element along the event's route. /// The event arguments containing additional information about the event. ///Nothing. public delegate void DragDeltaEventHandler(object sender, DragDeltaEventArgs e); } // 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
- BatchParser.cs
- GridViewPageEventArgs.cs
- DataGridPagingPage.cs
- storepermission.cs
- OAVariantLib.cs
- RoutingChannelExtension.cs
- NullableBoolConverter.cs
- WebEventCodes.cs
- PriorityBinding.cs
- Parsers.cs
- StringAnimationUsingKeyFrames.cs
- FontCacheUtil.cs
- LineInfo.cs
- CodeMethodInvokeExpression.cs
- AccessKeyManager.cs
- Converter.cs
- CollectionBase.cs
- DecoderNLS.cs
- IntegerValidator.cs
- SafeBitVector32.cs
- SafeHandles.cs
- CodeObjectCreateExpression.cs
- X509CertificateValidator.cs
- ProcessHost.cs
- DataColumnMapping.cs
- VariableQuery.cs
- Decoder.cs
- WebEncodingValidator.cs
- ConfigurationValidatorAttribute.cs
- TextInfo.cs
- RepeatBehaviorConverter.cs
- SqlBinder.cs
- Link.cs
- PropertyTabChangedEvent.cs
- XmlILConstructAnalyzer.cs
- XmlEntity.cs
- UInt64Converter.cs
- mediapermission.cs
- ShellProvider.cs
- ComponentResourceKeyConverter.cs
- ProcessInputEventArgs.cs
- OleStrCAMarshaler.cs
- SoapExtension.cs
- ColorConvertedBitmapExtension.cs
- HighContrastHelper.cs
- ModelToObjectValueConverter.cs
- ConfigurationManagerInternalFactory.cs
- MouseOverProperty.cs
- DocumentPage.cs
- SlipBehavior.cs
- TopClause.cs
- BindingExpressionUncommonField.cs
- MarginsConverter.cs
- XmlQueryStaticData.cs
- TextTreeTextBlock.cs
- DateTimeConstantAttribute.cs
- SequenceDesignerAccessibleObject.cs
- DataReaderContainer.cs
- StateItem.cs
- SystemBrushes.cs
- DataGridTable.cs
- LayoutUtils.cs
- ListViewItemMouseHoverEvent.cs
- UnionExpr.cs
- DataGridBoolColumn.cs
- CancellationState.cs
- LinearGradientBrush.cs
- XmlTextReader.cs
- ResourceSet.cs
- DataGridViewCellEventArgs.cs
- LocatorPartList.cs
- DesignerActionPanel.cs
- RelOps.cs
- XNameConverter.cs
- AspNetHostingPermission.cs
- BrowserCapabilitiesCodeGenerator.cs
- EmptyImpersonationContext.cs
- ReaderWriterLock.cs
- _PooledStream.cs
- HandlerBase.cs
- StyleHelper.cs
- EdmToObjectNamespaceMap.cs
- FixedFlowMap.cs
- Keyboard.cs
- OdbcStatementHandle.cs
- ComplexPropertyEntry.cs
- ObjectIDGenerator.cs
- Registry.cs
- ComplexBindingPropertiesAttribute.cs
- Blend.cs
- ReachUIElementCollectionSerializerAsync.cs
- QilScopedVisitor.cs
- PropertyDescriptor.cs
- SafeCancelMibChangeNotify.cs
- JavaScriptObjectDeserializer.cs
- RuleSettings.cs
- PixelFormat.cs
- XPathPatternBuilder.cs
- UTF32Encoding.cs
- OpenTypeMethods.cs