Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / Primitives / DragStartedEventArgs.cs / 1305600 / DragStartedEventArgs.cs
using System; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows; namespace System.Windows.Controls.Primitives { ////// This DragStartedEventArgs class contains additional information about the /// DragStarted event. /// ////// public class DragStartedEventArgs: RoutedEventArgs { /// /// This is an instance constructor for the DragStartedEventArgs class. It /// is constructed with a reference to the event being raised. /// ///Nothing. public DragStartedEventArgs(double horizontalOffset, double verticalOffset) : base() { _horizontalOffset = horizontalOffset; _verticalOffset = verticalOffset; RoutedEvent=Thumb.DragStartedEvent; } ////// Read-only access to the horizontal offset (relative to Thumb's co-ordinate). /// public double HorizontalOffset { get { return _horizontalOffset; } } ////// Read-only access to the vertical offset (relative to Thumb's co-ordinate). /// public double VerticalOffset { get { return _verticalOffset; } } ////// This method is used to perform the proper type casting in order to /// call the type-safe DragStartedEventHandler delegate for the DragStartedEvent event. /// /// The handler to invoke. /// The current object along the event's route. ///Nothing. ////// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { DragStartedEventHandler handler = (DragStartedEventHandler)genericHandler; handler(genericTarget, this); } private double _horizontalOffset; private double _verticalOffset; } /// /// This delegate must used by handlers of the DragStarted event. /// /// The current element along the event's route. /// The event arguments containing additional information about the event. ///Nothing. public delegate void DragStartedEventHandler(object sender, DragStartedEventArgs 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 DragStartedEventArgs class contains additional information about the /// DragStarted event. /// ////// public class DragStartedEventArgs: RoutedEventArgs { /// /// This is an instance constructor for the DragStartedEventArgs class. It /// is constructed with a reference to the event being raised. /// ///Nothing. public DragStartedEventArgs(double horizontalOffset, double verticalOffset) : base() { _horizontalOffset = horizontalOffset; _verticalOffset = verticalOffset; RoutedEvent=Thumb.DragStartedEvent; } ////// Read-only access to the horizontal offset (relative to Thumb's co-ordinate). /// public double HorizontalOffset { get { return _horizontalOffset; } } ////// Read-only access to the vertical offset (relative to Thumb's co-ordinate). /// public double VerticalOffset { get { return _verticalOffset; } } ////// This method is used to perform the proper type casting in order to /// call the type-safe DragStartedEventHandler delegate for the DragStartedEvent event. /// /// The handler to invoke. /// The current object along the event's route. ///Nothing. ////// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { DragStartedEventHandler handler = (DragStartedEventHandler)genericHandler; handler(genericTarget, this); } private double _horizontalOffset; private double _verticalOffset; } /// /// This delegate must used by handlers of the DragStarted event. /// /// The current element along the event's route. /// The event arguments containing additional information about the event. ///Nothing. public delegate void DragStartedEventHandler(object sender, DragStartedEventArgs 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
- CommunicationException.cs
- OleDbSchemaGuid.cs
- AssemblyUtil.cs
- SqlColumnizer.cs
- GeneralTransformGroup.cs
- UnsafeNativeMethods.cs
- IntegerFacetDescriptionElement.cs
- MetadataUtil.cs
- CallbackTimeoutsBehavior.cs
- QilScopedVisitor.cs
- StatusBarPanel.cs
- OverlappedAsyncResult.cs
- ConfigurationSectionCollection.cs
- StringFormat.cs
- LeaseManager.cs
- XPathDocumentIterator.cs
- WorkflowViewManager.cs
- ButtonField.cs
- Metadata.cs
- followingsibling.cs
- Baml2006ReaderFrame.cs
- TeredoHelper.cs
- ResponseBodyWriter.cs
- OperationCanceledException.cs
- ScrollChrome.cs
- DbConnectionInternal.cs
- TextServicesLoader.cs
- XmlWellformedWriter.cs
- UnsafeNativeMethodsPenimc.cs
- FolderNameEditor.cs
- WebHeaderCollection.cs
- DataPagerCommandEventArgs.cs
- Attribute.cs
- DrawItemEvent.cs
- OrderByBuilder.cs
- DataGridViewCellLinkedList.cs
- StackOverflowException.cs
- DLinqDataModelProvider.cs
- TcpTransportElement.cs
- _HelperAsyncResults.cs
- ManagementScope.cs
- ObjectStateManagerMetadata.cs
- InternalConfigHost.cs
- ContractSearchPattern.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- EntityFrameworkVersions.cs
- DataSourceXmlClassAttribute.cs
- Win32Native.cs
- UniqueConstraint.cs
- OracleTransaction.cs
- ChunkedMemoryStream.cs
- SqlCacheDependency.cs
- ClockController.cs
- InputScopeConverter.cs
- TextServicesCompartmentEventSink.cs
- SqlCommandSet.cs
- QilTargetType.cs
- ServerValidateEventArgs.cs
- SQLUtility.cs
- COMException.cs
- RequestCachingSection.cs
- TextDecorationCollection.cs
- PersonalizationProviderCollection.cs
- Utility.cs
- MatchSingleFxEngineOpcode.cs
- TransformerTypeCollection.cs
- VisualTarget.cs
- QilCloneVisitor.cs
- RequestBringIntoViewEventArgs.cs
- SelectingProviderEventArgs.cs
- InternalConfigHost.cs
- _SslStream.cs
- SoapTypeAttribute.cs
- Renderer.cs
- ErrorHandler.cs
- ProviderCommandInfoUtils.cs
- ToolCreatedEventArgs.cs
- XPathBinder.cs
- GlobalItem.cs
- DispatcherProcessingDisabled.cs
- Canvas.cs
- SystemGatewayIPAddressInformation.cs
- SmiXetterAccessMap.cs
- Stackframe.cs
- ProgressPage.cs
- AccessibleObject.cs
- ColorContextHelper.cs
- DrawingVisualDrawingContext.cs
- ProvideValueServiceProvider.cs
- TextBoxAutoCompleteSourceConverter.cs
- AttachedAnnotation.cs
- CodeAttributeArgumentCollection.cs
- QilVisitor.cs
- BookmarkEventArgs.cs
- DataBinder.cs
- InheritanceService.cs
- ExtendedProperty.cs
- MessageParameterAttribute.cs
- Converter.cs
- ErrorProvider.cs