Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Framework / System / Windows / Controls / DeferredSelectedIndexReference.cs / 1 / 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.
//----------------------------------------------------------------------------
//
// 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
- DateTimeConstantAttribute.cs
- ToolStripRenderer.cs
- ResourcesGenerator.cs
- PageFunction.cs
- TcpChannelFactory.cs
- CheckoutException.cs
- TextElementAutomationPeer.cs
- SecurityException.cs
- Win32.cs
- SiteMapNodeItemEventArgs.cs
- OutputCacheSettings.cs
- Types.cs
- HttpWebResponse.cs
- XmlDownloadManager.cs
- StoryFragments.cs
- ClaimTypes.cs
- XmlSchemaSimpleTypeUnion.cs
- SystemTcpConnection.cs
- IgnoreSectionHandler.cs
- DelegatedStream.cs
- HtmlImage.cs
- NCryptNative.cs
- XamlDesignerSerializationManager.cs
- TextServicesProperty.cs
- Menu.cs
- ClientEventManager.cs
- Screen.cs
- DataSet.cs
- SmiRecordBuffer.cs
- HttpListener.cs
- exports.cs
- XmlNullResolver.cs
- SafeProcessHandle.cs
- EntityCollection.cs
- PrimitiveXmlSerializers.cs
- ErrorInfoXmlDocument.cs
- SmtpCommands.cs
- Deflater.cs
- Menu.cs
- OSFeature.cs
- FocusTracker.cs
- PathNode.cs
- SqlTransaction.cs
- LocalizedNameDescriptionPair.cs
- SqlClientFactory.cs
- TrustLevelCollection.cs
- AlternationConverter.cs
- WeakHashtable.cs
- AdvancedBindingEditor.cs
- CssClassPropertyAttribute.cs
- TextSelectionHighlightLayer.cs
- DataKeyCollection.cs
- GreenMethods.cs
- TargetFrameworkAttribute.cs
- ExpressionBuilder.cs
- TextTreeDeleteContentUndoUnit.cs
- FixedPageProcessor.cs
- ClusterSafeNativeMethods.cs
- Rijndael.cs
- HtmlButton.cs
- DataServiceResponse.cs
- MultiAsyncResult.cs
- WebEventCodes.cs
- XmlSchemaAnyAttribute.cs
- SourceSwitch.cs
- ComUdtElementCollection.cs
- CultureInfoConverter.cs
- QueryResponse.cs
- InnerItemCollectionView.cs
- Missing.cs
- ConfigurationElement.cs
- ServiceHttpModule.cs
- NotConverter.cs
- DataListItemCollection.cs
- MasterPage.cs
- BezierSegment.cs
- DataGridViewComboBoxCell.cs
- ListenerSessionConnection.cs
- connectionpool.cs
- DESCryptoServiceProvider.cs
- PermissionRequestEvidence.cs
- UrlMapping.cs
- Point3DValueSerializer.cs
- ScalarType.cs
- MatrixCamera.cs
- ScriptReference.cs
- GridViewRowCollection.cs
- NotConverter.cs
- ExpandCollapseProviderWrapper.cs
- WebPartDescription.cs
- DoubleKeyFrameCollection.cs
- COMException.cs
- AccessKeyManager.cs
- UnsettableComboBox.cs
- TraversalRequest.cs
- SystemColors.cs
- ProcessManager.cs
- ReversePositionQuery.cs
- DllNotFoundException.cs
- IDispatchConstantAttribute.cs