Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Core / CSharp / System / Windows / GiveFeedbackEventArgs.cs / 1305600 / GiveFeedbackEventArgs.cs
//---------------------------------------------------------------------------- // // File: GiveFeedbackEventArgs.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: GiveFeedbackEventArgs for drag-and-drop operation.// // // History: // 08/19/2004 : sangilj Created // //--------------------------------------------------------------------------- using System; using System.Diagnostics; namespace System.Windows { ////// The GiveFeedbackEventArgs class represents a type of RoutedEventArgs that /// are relevant to GiveFeedback. /// public sealed class GiveFeedbackEventArgs : RoutedEventArgs { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Initializes a new instance of the GiveFeedbackEventArgs class. /// /// /// The effect of the drag operation. /// /// /// Use the default cursors. /// internal GiveFeedbackEventArgs(DragDropEffects effects, bool useDefaultCursors) { if (!DragDrop.IsValidDragDropEffects(effects)) { Debug.Assert(false, "Invalid effects"); } this._effects = effects; this._useDefaultCursors = useDefaultCursors; } #endregion Constructors //------------------------------------------------------ // // Public Methods // //----------------------------------------------------- #region Public Methods ////// The effects of drag operation /// public DragDropEffects Effects { get { return _effects; } } ////// Use the default cursors. /// public bool UseDefaultCursors { get { return _useDefaultCursors; } set { _useDefaultCursors = 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) { GiveFeedbackEventHandler handler = (GiveFeedbackEventHandler)genericHandler; handler(genericTarget, this); } #endregion Protected Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private DragDropEffects _effects; private bool _useDefaultCursors; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // File: GiveFeedbackEventArgs.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: GiveFeedbackEventArgs for drag-and-drop operation.// // // History: // 08/19/2004 : sangilj Created // //--------------------------------------------------------------------------- using System; using System.Diagnostics; namespace System.Windows { ////// The GiveFeedbackEventArgs class represents a type of RoutedEventArgs that /// are relevant to GiveFeedback. /// public sealed class GiveFeedbackEventArgs : RoutedEventArgs { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Initializes a new instance of the GiveFeedbackEventArgs class. /// /// /// The effect of the drag operation. /// /// /// Use the default cursors. /// internal GiveFeedbackEventArgs(DragDropEffects effects, bool useDefaultCursors) { if (!DragDrop.IsValidDragDropEffects(effects)) { Debug.Assert(false, "Invalid effects"); } this._effects = effects; this._useDefaultCursors = useDefaultCursors; } #endregion Constructors //------------------------------------------------------ // // Public Methods // //----------------------------------------------------- #region Public Methods ////// The effects of drag operation /// public DragDropEffects Effects { get { return _effects; } } ////// Use the default cursors. /// public bool UseDefaultCursors { get { return _useDefaultCursors; } set { _useDefaultCursors = 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) { GiveFeedbackEventHandler handler = (GiveFeedbackEventHandler)genericHandler; handler(genericTarget, this); } #endregion Protected Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private DragDropEffects _effects; private bool _useDefaultCursors; #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
- CodeSnippetStatement.cs
- MenuItem.cs
- EncoderParameter.cs
- Int16.cs
- CompilerWrapper.cs
- CapabilitiesPattern.cs
- SplitterPanelDesigner.cs
- NodeInfo.cs
- TextDecorationCollection.cs
- COM2ExtendedUITypeEditor.cs
- MinimizableAttributeTypeConverter.cs
- EntryIndex.cs
- RoleService.cs
- WindowsListViewItem.cs
- SQLInt64.cs
- WindowsPen.cs
- TypeReference.cs
- EmissiveMaterial.cs
- FunctionCommandText.cs
- NegatedCellConstant.cs
- Matrix3D.cs
- BindingExpressionUncommonField.cs
- DES.cs
- SoapReflector.cs
- DesignerCapabilities.cs
- DataRelation.cs
- _AcceptOverlappedAsyncResult.cs
- Expr.cs
- Soap12FormatExtensions.cs
- TypeDescriptionProvider.cs
- MetadataArtifactLoaderXmlReaderWrapper.cs
- Item.cs
- ServiceOperation.cs
- oledbmetadatacolumnnames.cs
- TextureBrush.cs
- PolygonHotSpot.cs
- HMACSHA1.cs
- listitem.cs
- HandoffBehavior.cs
- ScrollData.cs
- TransactedBatchingElement.cs
- PriorityChain.cs
- RegionInfo.cs
- CatalogPartChrome.cs
- DynamicActionMessageFilter.cs
- RowUpdatingEventArgs.cs
- FixedSOMPageElement.cs
- ButtonFlatAdapter.cs
- X509IssuerSerialKeyIdentifierClause.cs
- OneOfTypeConst.cs
- KeyedCollection.cs
- CommandLineParser.cs
- RangeExpression.cs
- FormCollection.cs
- AudioFileOut.cs
- Canvas.cs
- LateBoundBitmapDecoder.cs
- XmlCharCheckingReader.cs
- PropertyValueUIItem.cs
- HMAC.cs
- TemplateManager.cs
- FileUtil.cs
- BooleanExpr.cs
- SQLInt32Storage.cs
- Pool.cs
- WebPermission.cs
- SerializationObjectManager.cs
- DataGridViewHeaderCell.cs
- CustomWebEventKey.cs
- JavaScriptSerializer.cs
- EffectiveValueEntry.cs
- VectorCollectionConverter.cs
- InvalidStoreProtectionKeyException.cs
- GlobalProxySelection.cs
- HttpHandlerAction.cs
- BitmapEffectGroup.cs
- SqlDataSourceStatusEventArgs.cs
- XmlReaderSettings.cs
- Exceptions.cs
- PropertyMapper.cs
- ListParagraph.cs
- SiteMapNodeItem.cs
- NetSectionGroup.cs
- Message.cs
- LogSwitch.cs
- DetailsViewUpdatedEventArgs.cs
- BuildManagerHost.cs
- Relationship.cs
- OleDbConnectionFactory.cs
- PersistenceContextEnlistment.cs
- ListViewInsertEventArgs.cs
- NetworkInterface.cs
- NumberFunctions.cs
- WindowShowOrOpenTracker.cs
- DataGridViewCellStyleConverter.cs
- BuildProviderCollection.cs
- ConnectionPointCookie.cs
- ManipulationStartingEventArgs.cs
- EntitySqlException.cs
- HttpPostClientProtocol.cs