Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / QueryContinueDragEventArgs.cs / 1 / QueryContinueDragEventArgs.cs
//---------------------------------------------------------------------------- // // File: QueryContinueDragEventArgs.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: QueryContinueDragEventArgs for drag-and-drop operation. // // History: // 08/19/2004 : [....] Created // //--------------------------------------------------------------------------- using System; using System.Diagnostics; using SR=MS.Internal.PresentationCore.SR; using SRID=MS.Internal.PresentationCore.SRID; namespace System.Windows { ////// The QueryContinueDragEventArgs class represents a type of RoutedEventArgs that /// are relevant to QueryContinueDrag event. /// public sealed class QueryContinueDragEventArgs : RoutedEventArgs { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Initializes a new instance of the QueryContinueDragEventArgs class. /// /// /// Escape key was pressed. /// /// /// Input states. /// internal QueryContinueDragEventArgs(bool escapePressed, DragDropKeyStates dragDropKeyStates) { if (!DragDrop.IsValidDragDropKeyStates(dragDropKeyStates)) { Debug.Assert(false, "Invalid dragDropKeyStates"); } this._escapePressed = escapePressed; this._dragDropKeyStates = dragDropKeyStates; } #endregion Constructors //------------------------------------------------------ // // Public Methods // //----------------------------------------------------- #region Public Methods ////// Escape key was pressed. /// public bool EscapePressed { get { return _escapePressed; } } ////// The DragDropKeyStates that indicates the current states for /// physical keyboard keys and mouse buttons. /// public DragDropKeyStates KeyStates { get {return _dragDropKeyStates;} } ////// The action of drag operation /// public DragAction Action { get { return _action; } set { if (!DragDrop.IsValidDragAction(value)) { throw new ArgumentException(SR.Get(SRID.DragDrop_DragActionInvalid, "value")); } _action = value; } } #endregion Public Methods #region Protected Methods //------------------------------------------------------ // // Protected Methods // //------------------------------------------------------ ////// 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) { QueryContinueDragEventHandler handler = (QueryContinueDragEventHandler)genericHandler; handler(genericTarget, this); } #endregion Protected Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private bool _escapePressed; private DragDropKeyStates _dragDropKeyStates; private DragAction _action; #endregion Private Fields } } // 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
- CqlWriter.cs
- Rotation3D.cs
- PersonalizationStateInfoCollection.cs
- UnsafeNativeMethods.cs
- DataGridViewComboBoxColumnDesigner.cs
- UnsafeNativeMethods.cs
- embossbitmapeffect.cs
- ExcludePathInfo.cs
- PathFigure.cs
- FillBehavior.cs
- OracleBinary.cs
- ValidateNames.cs
- ShaderEffect.cs
- GregorianCalendarHelper.cs
- DictionaryEntry.cs
- Wildcard.cs
- DPCustomTypeDescriptor.cs
- TypeValidationEventArgs.cs
- AutomationElementCollection.cs
- ComponentSerializationService.cs
- StringCollection.cs
- WizardPanelChangingEventArgs.cs
- ConfigXmlComment.cs
- BitmapCacheBrush.cs
- SeverityFilter.cs
- EpmContentSerializer.cs
- IgnoreFileBuildProvider.cs
- AsyncSerializedWorker.cs
- Binding.cs
- TreeView.cs
- Bold.cs
- UInt16.cs
- RegistryConfigurationProvider.cs
- OSFeature.cs
- StylusPointProperty.cs
- XPathDescendantIterator.cs
- HttpModule.cs
- WebPartEditorApplyVerb.cs
- MruCache.cs
- HashCodeCombiner.cs
- Compiler.cs
- _NtlmClient.cs
- TreeViewEvent.cs
- DataControlImageButton.cs
- TailCallAnalyzer.cs
- ScriptServiceAttribute.cs
- LinkButton.cs
- PageCodeDomTreeGenerator.cs
- DbConnectionPoolCounters.cs
- OleDbRowUpdatingEvent.cs
- MatrixUtil.cs
- PartBasedPackageProperties.cs
- URIFormatException.cs
- GcHandle.cs
- ExtensionFile.cs
- CssClassPropertyAttribute.cs
- SecurityPermission.cs
- SubqueryRules.cs
- MyContact.cs
- QilNode.cs
- DictionaryBase.cs
- RadialGradientBrush.cs
- QueryStringHandler.cs
- Int16Animation.cs
- FrameworkContentElement.cs
- CodeCommentStatement.cs
- CodeDelegateCreateExpression.cs
- FixedNode.cs
- OciEnlistContext.cs
- ConfigXmlText.cs
- NativeMethods.cs
- MarkupObject.cs
- Solver.cs
- SystemGatewayIPAddressInformation.cs
- Vector3DCollection.cs
- DetailsViewUpdatedEventArgs.cs
- WebPartUtil.cs
- Asn1IntegerConverter.cs
- TimeoutHelper.cs
- ProxyAttribute.cs
- ItemList.cs
- WebSysDescriptionAttribute.cs
- ISFClipboardData.cs
- RecordManager.cs
- IntMinMaxAggregationOperator.cs
- DataGridSortCommandEventArgs.cs
- ItemChangedEventArgs.cs
- ContainerParagraph.cs
- SmtpSpecifiedPickupDirectoryElement.cs
- Geometry3D.cs
- TdsParserStateObject.cs
- InputEventArgs.cs
- XmlQueryStaticData.cs
- ColumnWidthChangingEvent.cs
- OdbcPermission.cs
- ActivityDesignerLayoutSerializers.cs
- ResolvedKeyFrameEntry.cs
- Trace.cs
- Metafile.cs
- InitializingNewItemEventArgs.cs