Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Framework / System / Windows / Controls / Primitives / DragStartedEventArgs.cs / 1 / 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
- SQLSingle.cs
- ClrProviderManifest.cs
- WorkflowNamespace.cs
- ImplicitInputBrush.cs
- MsmqUri.cs
- SdlChannelSink.cs
- ConfigUtil.cs
- DeviceContext2.cs
- FixedSOMTextRun.cs
- SinglePageViewer.cs
- BinaryCommonClasses.cs
- AxisAngleRotation3D.cs
- EditBehavior.cs
- ProvideValueServiceProvider.cs
- RecipientInfo.cs
- InputLangChangeEvent.cs
- DocumentsTrace.cs
- DataServiceQueryOfT.cs
- TransformerConfigurationWizardBase.cs
- SoapProcessingBehavior.cs
- TemplateAction.cs
- DataContractSerializerMessageContractImporter.cs
- CachedFontFace.cs
- InteropTrackingRecord.cs
- OrderedEnumerableRowCollection.cs
- XmlSchemaValidator.cs
- Vector3D.cs
- ExcCanonicalXml.cs
- Substitution.cs
- _IPv4Address.cs
- AuthorizationPolicyTypeElement.cs
- MissingMethodException.cs
- FormViewCommandEventArgs.cs
- ProfileService.cs
- FrameworkRichTextComposition.cs
- DefaultDialogButtons.cs
- MessageSmuggler.cs
- ProvidersHelper.cs
- activationcontext.cs
- FigureParaClient.cs
- hwndwrapper.cs
- UnicastIPAddressInformationCollection.cs
- ActiveDesignSurfaceEvent.cs
- ConnectionStringSettings.cs
- SimpleParser.cs
- TargetParameterCountException.cs
- RtfToXamlLexer.cs
- GlobalizationAssembly.cs
- HashHelper.cs
- SecurityRuntime.cs
- SelectorAutomationPeer.cs
- ThreadPoolTaskScheduler.cs
- XamlClipboardData.cs
- CheckBox.cs
- RenameRuleObjectDialog.cs
- MemoryFailPoint.cs
- ApplyImportsAction.cs
- FreezableCollection.cs
- CryptoStream.cs
- DesignerMetadata.cs
- FontStyleConverter.cs
- DefaultCommandConverter.cs
- CommonObjectSecurity.cs
- ExpressionEvaluator.cs
- DiscreteKeyFrames.cs
- ReachIDocumentPaginatorSerializerAsync.cs
- HtmlDocument.cs
- SessionStateContainer.cs
- FlowDocumentPage.cs
- InputEventArgs.cs
- ParagraphResult.cs
- BrowserTree.cs
- EventPropertyMap.cs
- SplitContainer.cs
- SslStreamSecurityBindingElement.cs
- GeometryCollection.cs
- OutputScopeManager.cs
- StoryFragments.cs
- HMACSHA1.cs
- AssemblyAssociatedContentFileAttribute.cs
- XmlSchemaObject.cs
- IRCollection.cs
- DrawingVisual.cs
- OleDbReferenceCollection.cs
- NavigateEvent.cs
- DefaultPropertyAttribute.cs
- SizeChangedEventArgs.cs
- DataSetMappper.cs
- DataMemberConverter.cs
- TTSEngineProxy.cs
- Help.cs
- Process.cs
- ModifyActivitiesPropertyDescriptor.cs
- Trace.cs
- PointAnimationUsingKeyFrames.cs
- Vector3DValueSerializer.cs
- HwndKeyboardInputProvider.cs
- CharAnimationUsingKeyFrames.cs
- PreviousTrackingServiceAttribute.cs
- NetworkInformationPermission.cs