Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Core / CSharp / System / Windows / GiveFeedbackEventArgs.cs / 1 / 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
- SafeRightsManagementHandle.cs
- QilTernary.cs
- WeakEventManager.cs
- Guid.cs
- SoapConverter.cs
- TextTreeRootTextBlock.cs
- DataSourceXmlSerializer.cs
- XmlSchemaGroup.cs
- ListViewGroup.cs
- VBIdentifierNameEditor.cs
- GraphicsState.cs
- NativeMethodsOther.cs
- ObjectView.cs
- ExtendedProtectionPolicy.cs
- UnsafeNativeMethods.cs
- ConfigurationManagerHelperFactory.cs
- FileDialogPermission.cs
- SqlCacheDependencyDatabase.cs
- Thumb.cs
- MarkupWriter.cs
- MinimizableAttributeTypeConverter.cs
- WinInetCache.cs
- BinarySerializer.cs
- HostProtectionException.cs
- EventWaitHandleSecurity.cs
- ColorDialog.cs
- OperatingSystemVersionCheck.cs
- SerializationStore.cs
- SectionInformation.cs
- ManipulationVelocities.cs
- TableAdapterManagerHelper.cs
- CalloutQueueItem.cs
- EdmProperty.cs
- CollaborationHelperFunctions.cs
- XmlSchemaSubstitutionGroup.cs
- XmlSerializerOperationGenerator.cs
- InternalConfigHost.cs
- EndpointAddress10.cs
- UInt32.cs
- PeekCompletedEventArgs.cs
- DefaultTextStoreTextComposition.cs
- SpecialNameAttribute.cs
- DBPropSet.cs
- AnimationException.cs
- CompletedAsyncResult.cs
- HtmlImage.cs
- DesignerValidationSummaryAdapter.cs
- BamlTreeNode.cs
- SymbolPair.cs
- BinHexEncoder.cs
- CountdownEvent.cs
- CellConstantDomain.cs
- StreamingContext.cs
- SqlCacheDependencySection.cs
- DynamicPropertyReader.cs
- AnimationStorage.cs
- UrlUtility.cs
- NativeMethods.cs
- _SslState.cs
- XmlTextWriter.cs
- AudioDeviceOut.cs
- EncodingStreamWrapper.cs
- GPStream.cs
- MenuItemBinding.cs
- PersonalizablePropertyEntry.cs
- DesignerHelpers.cs
- TypeSource.cs
- CheckBox.cs
- SqlCommand.cs
- SpAudioStreamWrapper.cs
- SemaphoreSlim.cs
- Section.cs
- DoWorkEventArgs.cs
- RefreshEventArgs.cs
- DataGridViewTopLeftHeaderCell.cs
- TCEAdapterGenerator.cs
- VisualBasic.cs
- ParentQuery.cs
- CodeActivity.cs
- DataObjectAttribute.cs
- FolderBrowserDialog.cs
- RemoteWebConfigurationHostStream.cs
- PopupControlService.cs
- XmlSchemaDatatype.cs
- SqlLiftIndependentRowExpressions.cs
- DesignRelationCollection.cs
- SimpleType.cs
- CodeExpressionStatement.cs
- InputLangChangeRequestEvent.cs
- HttpWebRequest.cs
- Menu.cs
- UIElementParagraph.cs
- XmlSchemaAttributeGroupRef.cs
- DefaultParameterValueAttribute.cs
- MarginCollapsingState.cs
- ScriptRegistrationManager.cs
- CompositeControl.cs
- DispatcherProcessingDisabled.cs
- HttpNamespaceReservationInstallComponent.cs
- ISAPIApplicationHost.cs