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 / ResourceDictionaryCollection.cs / 1 / ResourceDictionaryCollection.cs
using System; using System.Windows; using System.Collections.ObjectModel; using System.Diagnostics; namespace System.Windows { internal class ResourceDictionaryCollection : ObservableCollection{ #region Constructor internal ResourceDictionaryCollection(ResourceDictionary owner) { Debug.Assert(owner != null, "ResourceDictionaryCollection's owner cannot be null"); _owner = owner; } #endregion Constructor #region ProtectedMethods /// /// Called by base class Collection<T> when the list is being cleared; /// raises a CollectionChanged event to any listeners. /// protected override void ClearItems() { for (int i=0; i/// Called by base class Collection<T> when an item is added to list; /// raises a CollectionChanged event to any listeners. /// protected override void InsertItem(int index, ResourceDictionary item) { if (item == null) { throw new ArgumentNullException("item"); } base.InsertItem(index, item); } /// /// Called by base class Collection<T> when an item is set in list; /// raises a CollectionChanged event to any listeners. /// protected override void SetItem(int index, ResourceDictionary item) { if (item == null) { throw new ArgumentNullException("item"); } base.SetItem(index, item); } #endregion ProtectedMethods #region Data private ResourceDictionary _owner; #endregion Data } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Windows; using System.Collections.ObjectModel; using System.Diagnostics; namespace System.Windows { internal class ResourceDictionaryCollection : ObservableCollection{ #region Constructor internal ResourceDictionaryCollection(ResourceDictionary owner) { Debug.Assert(owner != null, "ResourceDictionaryCollection's owner cannot be null"); _owner = owner; } #endregion Constructor #region ProtectedMethods /// /// Called by base class Collection<T> when the list is being cleared; /// raises a CollectionChanged event to any listeners. /// protected override void ClearItems() { for (int i=0; i/// Called by base class Collection<T> when an item is added to list; /// raises a CollectionChanged event to any listeners. /// protected override void InsertItem(int index, ResourceDictionary item) { if (item == null) { throw new ArgumentNullException("item"); } base.InsertItem(index, item); } /// /// Called by base class Collection<T> when an item is set in list; /// raises a CollectionChanged event to any listeners. /// protected override void SetItem(int index, ResourceDictionary item) { if (item == null) { throw new ArgumentNullException("item"); } base.SetItem(index, item); } #endregion ProtectedMethods #region Data private ResourceDictionary _owner; #endregion Data } } // 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
- DecimalStorage.cs
- XmlElement.cs
- BaseTemplateParser.cs
- PageVisual.cs
- DictionaryKeyPropertyAttribute.cs
- StateBag.cs
- DataGridViewSelectedColumnCollection.cs
- BrushConverter.cs
- errorpatternmatcher.cs
- StateMachine.cs
- AdRotator.cs
- PagesSection.cs
- EntityContainer.cs
- DBConcurrencyException.cs
- MemberListBinding.cs
- InstanceLockedException.cs
- VisualBrush.cs
- WebConfigurationHostFileChange.cs
- Exception.cs
- TdsEnums.cs
- WebServiceEnumData.cs
- ContentValidator.cs
- AnnouncementEventArgs.cs
- MouseGestureValueSerializer.cs
- EventLogEntryCollection.cs
- CellCreator.cs
- PropertyConverter.cs
- SystemColorTracker.cs
- BinaryMethodMessage.cs
- WizardStepBase.cs
- MarkupProperty.cs
- PeerInvitationResponse.cs
- MsmqIntegrationBinding.cs
- TdsParameterSetter.cs
- CachedTypeface.cs
- HtmlInputButton.cs
- XhtmlBasicValidationSummaryAdapter.cs
- PersonalizablePropertyEntry.cs
- CompilerInfo.cs
- DataTableReaderListener.cs
- OleDbDataReader.cs
- SmtpMail.cs
- DataBindingHandlerAttribute.cs
- WizardStepCollectionEditor.cs
- XmlSchemaDocumentation.cs
- XamlToRtfWriter.cs
- ServiceInfo.cs
- BoundingRectTracker.cs
- Rotation3D.cs
- GenericEnumerator.cs
- SafeFindHandle.cs
- XmlCharacterData.cs
- ApplicationFileParser.cs
- ConfigXmlComment.cs
- ControlEvent.cs
- ToolBar.cs
- SqlMethods.cs
- WindowsListViewGroupSubsetLink.cs
- Win32Exception.cs
- LinqDataSourceView.cs
- StreamMarshaler.cs
- GridViewItemAutomationPeer.cs
- TypedDataSetSchemaImporterExtensionFx35.cs
- ObjectStateEntry.cs
- TheQuery.cs
- SiteOfOriginPart.cs
- FlowPanelDesigner.cs
- SocketAddress.cs
- CustomValidator.cs
- XPathScanner.cs
- _NegoState.cs
- CachedRequestParams.cs
- SortFieldComparer.cs
- XmlEventCache.cs
- SafeFileHandle.cs
- XmlReflectionMember.cs
- HttpRequestTraceRecord.cs
- StringValueConverter.cs
- ComplusEndpointConfigContainer.cs
- ImageCodecInfoPrivate.cs
- NameScope.cs
- Sentence.cs
- TypefaceCollection.cs
- LocalServiceSecuritySettings.cs
- XmlBinaryReader.cs
- ByteRangeDownloader.cs
- TextEffectResolver.cs
- ListViewInsertionMark.cs
- FormsAuthenticationModule.cs
- GacUtil.cs
- XmlSchemaRedefine.cs
- GradientStopCollection.cs
- PeerCollaboration.cs
- HtmlTernaryTree.cs
- CapiNative.cs
- PlanCompiler.cs
- XmlDictionaryString.cs
- HtmlFormWrapper.cs
- Command.cs
- Opcode.cs