Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / ContentOperations.cs / 1 / ContentOperations.cs
namespace System.Windows { ////// This interface defines the common methods and services available from a ContentElement. /// public static class ContentOperations { ////// Get the Visual parent of this ContentElement. /// public static DependencyObject GetParent(ContentElement reference) { if(reference == null) { throw new ArgumentNullException("reference"); } return reference._parent; } ////// Set the Visual parent of this ContentElement. /// ////// This is different than Visuals. For Visuals, you have to /// Add/Remove the visual from a children collection to change /// the parent. I think it is a better model, but I don't /// know if we want to expose a full children collection for /// content elements. /// public static void SetParent(ContentElement reference, DependencyObject parent) { if(reference == null) { throw new ArgumentNullException("reference"); } DependencyObject oldParent = reference._parent; reference._parent = parent; // Raise content parent changed notification reference.OnContentParentChanged(oldParent); } } } // 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
- X509Utils.cs
- MonthCalendar.cs
- MethodSet.cs
- ReaderContextStackData.cs
- CodeAccessSecurityEngine.cs
- TextParaLineResult.cs
- DropDownHolder.cs
- FontDialog.cs
- WindowsListViewItemCheckBox.cs
- HtmlMeta.cs
- ISO2022Encoding.cs
- Win32MouseDevice.cs
- GeneralTransform3DTo2DTo3D.cs
- UInt64Storage.cs
- XhtmlBasicControlAdapter.cs
- ContentIterators.cs
- errorpatternmatcher.cs
- HandledMouseEvent.cs
- WhileDesigner.xaml.cs
- XPathQilFactory.cs
- SymbolType.cs
- ScopelessEnumAttribute.cs
- assertwrapper.cs
- DataGridAddNewRow.cs
- AppModelKnownContentFactory.cs
- StorageModelBuildProvider.cs
- PostBackOptions.cs
- Label.cs
- Sequence.cs
- GroupItemAutomationPeer.cs
- DashStyles.cs
- ErrorInfoXmlDocument.cs
- Comparer.cs
- DateTimeConverter.cs
- RecordConverter.cs
- UInt16Storage.cs
- Debugger.cs
- RequestCacheValidator.cs
- IssuanceLicense.cs
- ObjectDataSourceView.cs
- ProfileProvider.cs
- DataViewSetting.cs
- VisualStyleTypesAndProperties.cs
- XmlSchemaProviderAttribute.cs
- TraceEventCache.cs
- IxmlLineInfo.cs
- TextBox.cs
- KeyFrames.cs
- RelationshipDetailsCollection.cs
- IApplicationTrustManager.cs
- Message.cs
- ResourceContainer.cs
- AsyncPostBackTrigger.cs
- ExecutedRoutedEventArgs.cs
- BitmapEffectGeneralTransform.cs
- DoWorkEventArgs.cs
- ZipIOCentralDirectoryBlock.cs
- IgnoreFlushAndCloseStream.cs
- DeliveryStrategy.cs
- CharacterHit.cs
- base64Transforms.cs
- NativeWindow.cs
- XamlSerializer.cs
- XPathAncestorIterator.cs
- Transform.cs
- ISAPIApplicationHost.cs
- TextDecoration.cs
- CFStream.cs
- NewArray.cs
- MessageTransmitTraceRecord.cs
- SpoolingTaskBase.cs
- xdrvalidator.cs
- DataGridViewIntLinkedList.cs
- SerialErrors.cs
- TemplateColumn.cs
- ProxyGenerator.cs
- SQLGuidStorage.cs
- SqlServices.cs
- ComContractElementCollection.cs
- AssemblyAttributesGoHere.cs
- ChannelReliableSession.cs
- WindowsFont.cs
- DateTimePicker.cs
- NullableBoolConverter.cs
- CodeParameterDeclarationExpressionCollection.cs
- CLSCompliantAttribute.cs
- HtmlElement.cs
- infer.cs
- WebServiceResponseDesigner.cs
- GeneralTransform.cs
- nulltextcontainer.cs
- TraceFilter.cs
- CancelEventArgs.cs
- Atom10FormatterFactory.cs
- AssertFilter.cs
- Int16Storage.cs
- ZipIOModeEnforcingStream.cs
- FastEncoder.cs
- DataSourceControl.cs
- IPGlobalProperties.cs