Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / Controls / Primitives / DragCompletedEventArgs.cs / 1 / DragCompletedEventArgs.cs
using System; using System.Windows.Controls; using System.Windows; namespace System.Windows.Controls.Primitives { ////// This DragCompletedEventArgs class contains additional information about the /// DragCompleted event. /// ////// public class DragCompletedEventArgs: RoutedEventArgs { /// /// This is an instance constructor for the DragCompletedEventArgs class. It /// is constructed with a reference to the event being raised. /// ///Nothing. public DragCompletedEventArgs(double horizontalChange, double verticalChange, bool canceled) : base() { _horizontalChange = horizontalChange; _verticalChange = verticalChange; _wasCanceled = canceled; RoutedEvent=Thumb.DragCompletedEvent; } ////// Read-only access to the horizontal distance between the point where mouse's left-button /// was pressed and the point where mouse's left-button was released /// public double HorizontalChange { get { return _horizontalChange; } } ////// Read-only access to the vertical distance between the point where mouse's left-button /// was pressed and the point where mouse's left-button was released /// public double VerticalChange { get { return _verticalChange; } } ////// Read-only access to boolean states whether the drag operation was canceled or not. /// ///public bool Canceled { get { return _wasCanceled; } } /// /// This method is used to perform the proper type casting in order to /// call the type-safe DragCompletedEventHandler delegate for the DragCompletedEvent event. /// /// The handler to invoke. /// The current object along the event's route. ///Nothing. ////// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { DragCompletedEventHandler handler = (DragCompletedEventHandler)genericHandler; handler(genericTarget, this); } private double _horizontalChange; private double _verticalChange; private bool _wasCanceled; } /// /// This delegate must used by handlers of the DragCompleted event. /// /// The current element along the event's route. /// The event arguments containing additional information about the event. ///Nothing. public delegate void DragCompletedEventHandler(object sender, DragCompletedEventArgs 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; namespace System.Windows.Controls.Primitives { ////// This DragCompletedEventArgs class contains additional information about the /// DragCompleted event. /// ////// public class DragCompletedEventArgs: RoutedEventArgs { /// /// This is an instance constructor for the DragCompletedEventArgs class. It /// is constructed with a reference to the event being raised. /// ///Nothing. public DragCompletedEventArgs(double horizontalChange, double verticalChange, bool canceled) : base() { _horizontalChange = horizontalChange; _verticalChange = verticalChange; _wasCanceled = canceled; RoutedEvent=Thumb.DragCompletedEvent; } ////// Read-only access to the horizontal distance between the point where mouse's left-button /// was pressed and the point where mouse's left-button was released /// public double HorizontalChange { get { return _horizontalChange; } } ////// Read-only access to the vertical distance between the point where mouse's left-button /// was pressed and the point where mouse's left-button was released /// public double VerticalChange { get { return _verticalChange; } } ////// Read-only access to boolean states whether the drag operation was canceled or not. /// ///public bool Canceled { get { return _wasCanceled; } } /// /// This method is used to perform the proper type casting in order to /// call the type-safe DragCompletedEventHandler delegate for the DragCompletedEvent event. /// /// The handler to invoke. /// The current object along the event's route. ///Nothing. ////// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { DragCompletedEventHandler handler = (DragCompletedEventHandler)genericHandler; handler(genericTarget, this); } private double _horizontalChange; private double _verticalChange; private bool _wasCanceled; } /// /// This delegate must used by handlers of the DragCompleted event. /// /// The current element along the event's route. /// The event arguments containing additional information about the event. ///Nothing. public delegate void DragCompletedEventHandler(object sender, DragCompletedEventArgs 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
- InfiniteTimeSpanConverter.cs
- OdbcEnvironment.cs
- AspCompat.cs
- Helpers.cs
- RestClientProxyHandler.cs
- ErrorTableItemStyle.cs
- StateItem.cs
- MemoryStream.cs
- IsolatedStorage.cs
- Executor.cs
- SystemTcpStatistics.cs
- SqlCrossApplyToCrossJoin.cs
- XmlAttributeProperties.cs
- Behavior.cs
- GacUtil.cs
- FocusWithinProperty.cs
- DesignerWithHeader.cs
- Vector3DConverter.cs
- RequestCacheManager.cs
- CommonDialog.cs
- PageBuildProvider.cs
- OracleBFile.cs
- BaseCAMarshaler.cs
- WindowInteropHelper.cs
- SqlConnectionPoolGroupProviderInfo.cs
- Padding.cs
- DataObjectFieldAttribute.cs
- SessionIDManager.cs
- XmlNamespaceDeclarationsAttribute.cs
- StateMachineWorkflowInstance.cs
- TableHeaderCell.cs
- URLMembershipCondition.cs
- CommunicationObjectFaultedException.cs
- ArrayHelper.cs
- TemplateBuilder.cs
- SecurityElement.cs
- arclist.cs
- XmlSchemaSimpleTypeRestriction.cs
- CallSiteOps.cs
- EventMappingSettings.cs
- DataFieldEditor.cs
- TcpHostedTransportConfiguration.cs
- DetailsViewPageEventArgs.cs
- TemplateParser.cs
- WindowsBrush.cs
- ErrorItem.cs
- SecurityState.cs
- TreeViewCancelEvent.cs
- FilterQueryOptionExpression.cs
- Line.cs
- HttpClientProtocol.cs
- SmiRecordBuffer.cs
- ThumbButtonInfo.cs
- _HeaderInfo.cs
- DataListCommandEventArgs.cs
- TraceContext.cs
- DurationConverter.cs
- SchemaElementLookUpTableEnumerator.cs
- LongTypeConverter.cs
- dbenumerator.cs
- TextPenaltyModule.cs
- MessagePropertyVariants.cs
- ColumnReorderedEventArgs.cs
- LogExtent.cs
- CommonXSendMessage.cs
- SqlCacheDependencyDatabase.cs
- SiteMapNodeItem.cs
- FieldDescriptor.cs
- PropertiesTab.cs
- TemplatedWizardStep.cs
- ProfilePropertySettings.cs
- TranslateTransform3D.cs
- QueryInterceptorAttribute.cs
- webproxy.cs
- ToolStripPanelRenderEventArgs.cs
- SoapTypeAttribute.cs
- HashSetDebugView.cs
- UnsafeNativeMethods.cs
- SQLDateTimeStorage.cs
- LinkTarget.cs
- DefinitionBase.cs
- ImageAnimator.cs
- OperationCanceledException.cs
- UInt32Converter.cs
- SqlDataSourceStatusEventArgs.cs
- DataServiceRequestException.cs
- TickBar.cs
- SequenceFullException.cs
- CallbackWrapper.cs
- WebSysDescriptionAttribute.cs
- LogFlushAsyncResult.cs
- Matrix3DStack.cs
- SR.Designer.cs
- Frame.cs
- XsdDuration.cs
- DefinitionBase.cs
- XComponentModel.cs
- CustomErrorsSection.cs
- ObsoleteAttribute.cs
- DLinqAssociationProvider.cs