Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / CleanUpVirtualizedItemEventArgs.cs / 1305600 / CleanUpVirtualizedItemEventArgs.cs
//----------------------------------------------------------------------------
//
// Copyright (C) Microsoft Corporation. All rights reserved.
//
//---------------------------------------------------------------------------
using System;
using System.ComponentModel;
namespace System.Windows.Controls
{
///
/// Event arguments communicating an element that is being prepared to be re-virtualized.
///
public class CleanUpVirtualizedItemEventArgs : RoutedEventArgs
{
internal CleanUpVirtualizedItemEventArgs(object value, UIElement element)
: base(VirtualizingStackPanel.CleanUpVirtualizedItemEvent)
{
_value = value;
_element = element;
}
///
/// The original data value.
/// If the data value is a visual element, it will be the same as UIElement.
///
public object Value
{
get
{
return _value;
}
}
///
/// The instance of the visual element that represented the data value.
/// If the data value is a visual element, it will be the same as UIElement.
///
public UIElement UIElement
{
get
{
return _element;
}
}
///
/// Set by handlers of this event to true to indicate that the
/// re-virtualizing of this item should not happen.
///
public bool Cancel
{
get
{
return _cancel;
}
set
{
_cancel = value;
}
}
private object _value;
private UIElement _element;
private bool _cancel;
}
///
/// The delegate to use for handlers that receive CleanUpVirtualizedItemEventArgs.
///
public delegate void CleanUpVirtualizedItemEventHandler(object sender, CleanUpVirtualizedItemEventArgs e);
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
//----------------------------------------------------------------------------
//
// Copyright (C) Microsoft Corporation. All rights reserved.
//
//---------------------------------------------------------------------------
using System;
using System.ComponentModel;
namespace System.Windows.Controls
{
///
/// Event arguments communicating an element that is being prepared to be re-virtualized.
///
public class CleanUpVirtualizedItemEventArgs : RoutedEventArgs
{
internal CleanUpVirtualizedItemEventArgs(object value, UIElement element)
: base(VirtualizingStackPanel.CleanUpVirtualizedItemEvent)
{
_value = value;
_element = element;
}
///
/// The original data value.
/// If the data value is a visual element, it will be the same as UIElement.
///
public object Value
{
get
{
return _value;
}
}
///
/// The instance of the visual element that represented the data value.
/// If the data value is a visual element, it will be the same as UIElement.
///
public UIElement UIElement
{
get
{
return _element;
}
}
///
/// Set by handlers of this event to true to indicate that the
/// re-virtualizing of this item should not happen.
///
public bool Cancel
{
get
{
return _cancel;
}
set
{
_cancel = value;
}
}
private object _value;
private UIElement _element;
private bool _cancel;
}
///
/// The delegate to use for handlers that receive CleanUpVirtualizedItemEventArgs.
///
public delegate void CleanUpVirtualizedItemEventHandler(object sender, CleanUpVirtualizedItemEventArgs 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
- TrustLevel.cs
- ClaimComparer.cs
- DockEditor.cs
- ConsoleCancelEventArgs.cs
- AuthenticationException.cs
- SimpleMailWebEventProvider.cs
- Conditional.cs
- MethodCallConverter.cs
- XmlCodeExporter.cs
- FontWeights.cs
- BitmapEffectInputData.cs
- EdmSchemaError.cs
- EndOfStreamException.cs
- MailSettingsSection.cs
- SynchronizedDispatch.cs
- DataGridViewCellStyleConverter.cs
- CreateUserWizardStep.cs
- Crc32.cs
- AnchoredBlock.cs
- ScrollEventArgs.cs
- EventLogPermission.cs
- BulletDecorator.cs
- MouseOverProperty.cs
- HttpProfileBase.cs
- EventLogEntryCollection.cs
- SmiContextFactory.cs
- DesignTimeHTMLTextWriter.cs
- SmiConnection.cs
- HitTestFilterBehavior.cs
- SapiAttributeParser.cs
- ApplicationFileParser.cs
- OverflowException.cs
- Token.cs
- AmbiguousMatchException.cs
- GeneralTransform3DTo2DTo3D.cs
- JsonEnumDataContract.cs
- RSAPKCS1SignatureFormatter.cs
- TextTreeTextNode.cs
- FixedSOMLineRanges.cs
- WebPartRestoreVerb.cs
- SafeEventLogReadHandle.cs
- ControlDesigner.cs
- OutputCacheModule.cs
- XPathDescendantIterator.cs
- StateChangeEvent.cs
- CodeVariableReferenceExpression.cs
- ScriptingAuthenticationServiceSection.cs
- Pool.cs
- SafeCoTaskMem.cs
- RubberbandSelector.cs
- HttpRequest.cs
- ObjectViewQueryResultData.cs
- KeyEventArgs.cs
- WebPartAddingEventArgs.cs
- DataShape.cs
- SiteMapNodeItem.cs
- WindowsIPAddress.cs
- SingleAnimation.cs
- UrlMapping.cs
- FieldNameLookup.cs
- OrCondition.cs
- PropagatorResult.cs
- OrderingExpression.cs
- SynchronizationContext.cs
- GridViewEditEventArgs.cs
- ExpressionBindings.cs
- Monitor.cs
- UnsafeNativeMethods.cs
- UpdateRecord.cs
- DispatcherEventArgs.cs
- DrawingBrush.cs
- PropertyGridView.cs
- TypeResolvingOptionsAttribute.cs
- HTTP_SERVICE_CONFIG_URLACL_PARAM.cs
- Lease.cs
- Error.cs
- _Events.cs
- SafeEventLogWriteHandle.cs
- SendActivityDesigner.cs
- Encoding.cs
- ControlPropertyNameConverter.cs
- TextEditorCharacters.cs
- GrammarBuilderPhrase.cs
- RenderingBiasValidation.cs
- NamespaceMapping.cs
- MultilineStringConverter.cs
- OperandQuery.cs
- PublisherMembershipCondition.cs
- Expr.cs
- BindingExpression.cs
- ListParaClient.cs
- ConvertersCollection.cs
- SizeConverter.cs
- SQLByte.cs
- TableNameAttribute.cs
- FacetChecker.cs
- RotationValidation.cs
- ServiceInfoCollection.cs
- GridViewPageEventArgs.cs
- ClientScriptItemCollection.cs