Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / Separator.cs / 1458001 / Separator.cs
//---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using MS.Internal.KnownBoxes; using System.Windows.Automation.Peers; namespace System.Windows.Controls { ////// Separator control is a simple Control subclass that is used in different styles /// depend on container control. Common usage is inside ListBox, ComboBox, MenuItem and ToolBar. /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] // cannot be read & localized as string public class Separator : Control { static Separator() { DefaultStyleKeyProperty.OverrideMetadata(typeof(Separator), new FrameworkPropertyMetadata(typeof(Separator))); _dType = DependencyObjectType.FromSystemTypeInternal(typeof(Separator)); IsEnabledProperty.OverrideMetadata(typeof(Separator), new FrameworkPropertyMetadata(BooleanBoxes.FalseBox)); } internal static void PrepareContainer(Control container) { if (container != null) { // Disable the control and set the alignment to stretch container.IsEnabled = false; container.HorizontalContentAlignment = HorizontalAlignment.Stretch; } } ////// Creates AutomationPeer ( protected override AutomationPeer OnCreateAutomationPeer() { return new SeparatorAutomationPeer(this); } #region DTypeThemeStyleKey // Returns the DependencyObjectType for the registered ThemeStyleKey's default // value. Controls will override this method to return approriate types. internal override DependencyObjectType DTypeThemeStyleKey { get { return _dType; } } private static DependencyObjectType _dType; #endregion DTypeThemeStyleKey } } // 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
- BypassElement.cs
- MailAddress.cs
- _emptywebproxy.cs
- FlowDocumentPage.cs
- ExtensionQuery.cs
- PropertyValue.cs
- SimpleApplicationHost.cs
- MemoryFailPoint.cs
- NumberFormatter.cs
- ListBoxChrome.cs
- ValueExpressions.cs
- EntityTransaction.cs
- elementinformation.cs
- StreamInfo.cs
- OracleParameter.cs
- PartitionedStreamMerger.cs
- ApplicationSecurityInfo.cs
- DataGridViewMethods.cs
- RenderData.cs
- SpotLight.cs
- MgmtResManager.cs
- DataRelationCollection.cs
- RenderContext.cs
- DoubleAnimation.cs
- KeyConverter.cs
- ImageIndexEditor.cs
- SourceFileBuildProvider.cs
- BrowserCapabilitiesFactory35.cs
- HealthMonitoringSection.cs
- ZoomPercentageConverter.cs
- XmlRootAttribute.cs
- SoapCodeExporter.cs
- EventProviderClassic.cs
- ReadOnlyHierarchicalDataSourceView.cs
- ActionFrame.cs
- ServiceNameCollection.cs
- MouseActionValueSerializer.cs
- CustomLineCap.cs
- GridViewSelectEventArgs.cs
- HwndMouseInputProvider.cs
- ColumnBinding.cs
- ProfilePropertySettings.cs
- ManipulationDeltaEventArgs.cs
- ControlPaint.cs
- MultilineStringConverter.cs
- PrimaryKeyTypeConverter.cs
- AccessedThroughPropertyAttribute.cs
- RangeValuePatternIdentifiers.cs
- DesignTimeVisibleAttribute.cs
- OutputCacheProfile.cs
- KernelTypeValidation.cs
- EnumMemberAttribute.cs
- GrammarBuilder.cs
- Image.cs
- WindowCollection.cs
- ParamArrayAttribute.cs
- WindowsToolbarAsMenu.cs
- DataGridViewCellCollection.cs
- FillRuleValidation.cs
- FixedSOMPageConstructor.cs
- BinaryReader.cs
- ExpressionsCollectionConverter.cs
- ConfigurationManagerHelperFactory.cs
- ByteStreamMessage.cs
- TypeLoadException.cs
- NamedObject.cs
- ResourceDisplayNameAttribute.cs
- IdleTimeoutMonitor.cs
- RuntimeConfig.cs
- BaseWebProxyFinder.cs
- StylusOverProperty.cs
- DataColumnChangeEvent.cs
- ToolStripSplitStackLayout.cs
- BrushMappingModeValidation.cs
- MatrixConverter.cs
- AlignmentXValidation.cs
- AxHostDesigner.cs
- XmlElementAttribute.cs
- UnsafeNativeMethods.cs
- Matrix.cs
- DeclaredTypeElementCollection.cs
- UidManager.cs
- FixedStringLookup.cs
- CatalogPartChrome.cs
- RegexFCD.cs
- FunctionCommandText.cs
- Scanner.cs
- ObjectListDataBindEventArgs.cs
- TextContainer.cs
- ContextStaticAttribute.cs
- StorageEntitySetMapping.cs
- ArgumentsParser.cs
- WebResourceUtil.cs
- RetrieveVirtualItemEventArgs.cs
- SmtpNtlmAuthenticationModule.cs
- InkCanvasSelection.cs
- EditableTreeList.cs
- OleDbParameter.cs
- NotImplementedException.cs
- HebrewCalendar.cs