Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / DeferredSelectedIndexReference.cs / 1305600 / DeferredSelectedIndexReference.cs
//----------------------------------------------------------------------------
//
// File: DeferredSelectedIndexReference.cs
//
// Copyright (C) Microsoft Corporation. All rights reserved.
//
// Description: Proxy object passed to the property system to delay load
// Selector.SelectedIndex values.
//
//---------------------------------------------------------------------------
using System.Windows.Controls.Primitives;
namespace System.Windows.Controls
{
// Proxy object passed to the property system to delay load Selector.SelectedIndex
// values.
internal class DeferredSelectedIndexReference : DeferredReference
{
//-----------------------------------------------------
//
// Constructors
//
//-----------------------------------------------------
#region Constructors
internal DeferredSelectedIndexReference(Selector selector)
{
_selector = selector;
}
#endregion Constructors
//------------------------------------------------------
//
// Internal Methods
//
//-----------------------------------------------------
#region Internal Methods
// Does the real work to calculate the current SelectedIndexProperty value.
internal override object GetValue(BaseValueSourceInternal valueSource)
{
return _selector.InternalSelectedIndex;
}
// Gets the type of the value it represents
internal override Type GetValueType()
{
return typeof(int);
}
#endregion Internal Methods
//------------------------------------------------------
//
// Private Fields
//
//------------------------------------------------------
#region Private Fields
// Selector mapped to this object.
private readonly Selector _selector;
#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
- ConstrainedDataObject.cs
- WaitHandleCannotBeOpenedException.cs
- PointLightBase.cs
- DesignerOptionService.cs
- CLSCompliantAttribute.cs
- ImageSource.cs
- CngAlgorithm.cs
- HtmlFormAdapter.cs
- ServiceObjectContainer.cs
- ModelPropertyDescriptor.cs
- ListViewGroup.cs
- ControlCachePolicy.cs
- Image.cs
- CheckBoxPopupAdapter.cs
- DesignerVerbCollection.cs
- Trigger.cs
- TransformValueSerializer.cs
- DataSvcMapFile.cs
- SqlExpressionNullability.cs
- SerializerDescriptor.cs
- SingleStorage.cs
- ReservationNotFoundException.cs
- SID.cs
- DataBindingHandlerAttribute.cs
- VariableQuery.cs
- AncillaryOps.cs
- DesignColumnCollection.cs
- Vector3D.cs
- TrackingServices.cs
- ReadOnlyCollection.cs
- WCFBuildProvider.cs
- CommandDesigner.cs
- UrlPath.cs
- AutomationPatternInfo.cs
- Processor.cs
- DocumentGridPage.cs
- SHA384.cs
- SerializationSectionGroup.cs
- smtpconnection.cs
- IsolatedStorageFile.cs
- ConstraintCollection.cs
- ErrorStyle.cs
- PropertyGroupDescription.cs
- NonBatchDirectoryCompiler.cs
- ObjectStorage.cs
- ExpressionBindingCollection.cs
- httpstaticobjectscollection.cs
- TextEndOfSegment.cs
- TextTreeText.cs
- Utils.cs
- UseLicense.cs
- DoWorkEventArgs.cs
- TextInfo.cs
- FormViewUpdateEventArgs.cs
- WsdlContractConversionContext.cs
- CounterNameConverter.cs
- DetailsViewUpdateEventArgs.cs
- Context.cs
- ProcessModuleCollection.cs
- ClientConvert.cs
- ExtentKey.cs
- HwndStylusInputProvider.cs
- DesignerDataSourceView.cs
- PairComparer.cs
- HttpWebRequestElement.cs
- InlineUIContainer.cs
- RecipientIdentity.cs
- IndependentlyAnimatedPropertyMetadata.cs
- ViewGenerator.cs
- ServerValidateEventArgs.cs
- XmlParserContext.cs
- GridItemProviderWrapper.cs
- MultiTrigger.cs
- ProfileProvider.cs
- PreloadHost.cs
- UTF7Encoding.cs
- HttpModulesInstallComponent.cs
- ScriptReference.cs
- XMLSyntaxException.cs
- FormsAuthentication.cs
- BaseDataListComponentEditor.cs
- HttpGetClientProtocol.cs
- _LoggingObject.cs
- EntityClientCacheEntry.cs
- SmtpAuthenticationManager.cs
- TextBoxAutomationPeer.cs
- FolderNameEditor.cs
- WebEventTraceProvider.cs
- ListViewEditEventArgs.cs
- PieceNameHelper.cs
- PtsCache.cs
- FixedDocumentSequencePaginator.cs
- DynamicEndpoint.cs
- GradientSpreadMethodValidation.cs
- PathSegment.cs
- XmlSchemaCollection.cs
- documentsequencetextcontainer.cs
- FreezableOperations.cs
- BrowserCapabilitiesFactory35.cs
- EntityParameter.cs