Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / GroupBox.cs / 1305600 / GroupBox.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // Description: Implementation of the GroupBox Control // //--------------------------------------------------------------------------- using System.Windows.Input; // Access Key support namespace System.Windows.Controls { ////// GroupBox Control class /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] // cannot be read & localized as string public class GroupBox : HeaderedContentControl { #region Constructors static GroupBox() { FocusableProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(false)); IsTabStopProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(false)); DefaultStyleKeyProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(typeof(GroupBox))); EventManager.RegisterClassHandler(typeof(GroupBox), AccessKeyManager.AccessKeyPressedEvent, new AccessKeyPressedEventHandler(OnAccessKeyPressed)); } #endregion #region Override methods ////// Creates AutomationPeer ( protected override System.Windows.Automation.Peers.AutomationPeer OnCreateAutomationPeer() { return new System.Windows.Automation.Peers.GroupBoxAutomationPeer(this); } ///) /// /// The Access key for this control was invoked. /// protected override void OnAccessKey(AccessKeyEventArgs e) { MoveFocus(new TraversalRequest(FocusNavigationDirection.First)); } private static void OnAccessKeyPressed(object sender, AccessKeyPressedEventArgs e) { if (!e.Handled && e.Scope == null && e.Target == null) { e.Target = sender as GroupBox; } } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // Description: Implementation of the GroupBox Control // //--------------------------------------------------------------------------- using System.Windows.Input; // Access Key support namespace System.Windows.Controls { ////// GroupBox Control class /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] // cannot be read & localized as string public class GroupBox : HeaderedContentControl { #region Constructors static GroupBox() { FocusableProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(false)); IsTabStopProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(false)); DefaultStyleKeyProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(typeof(GroupBox))); EventManager.RegisterClassHandler(typeof(GroupBox), AccessKeyManager.AccessKeyPressedEvent, new AccessKeyPressedEventHandler(OnAccessKeyPressed)); } #endregion #region Override methods ////// Creates AutomationPeer ( protected override System.Windows.Automation.Peers.AutomationPeer OnCreateAutomationPeer() { return new System.Windows.Automation.Peers.GroupBoxAutomationPeer(this); } ///) /// /// The Access key for this control was invoked. /// protected override void OnAccessKey(AccessKeyEventArgs e) { MoveFocus(new TraversalRequest(FocusNavigationDirection.First)); } private static void OnAccessKeyPressed(object sender, AccessKeyPressedEventArgs e) { if (!e.Handled && e.Scope == null && e.Target == null) { e.Target = sender as GroupBox; } } #endregion } } // 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
- WindowsToolbarAsMenu.cs
- GeneralTransformGroup.cs
- CodePropertyReferenceExpression.cs
- SecurityTokenValidationException.cs
- ColumnMapCopier.cs
- IdentityReference.cs
- BaseCollection.cs
- BitmapDownload.cs
- DataView.cs
- SvcMapFile.cs
- WindowsListViewScroll.cs
- CFStream.cs
- COM2ExtendedBrowsingHandler.cs
- XamlVector3DCollectionSerializer.cs
- Pair.cs
- X509Certificate2.cs
- TemplateContainer.cs
- GeneralTransform3D.cs
- ItemList.cs
- TraversalRequest.cs
- Rfc4050KeyFormatter.cs
- BasicCellRelation.cs
- MarginsConverter.cs
- GridViewRowCollection.cs
- PageThemeParser.cs
- DuplexSecurityProtocolFactory.cs
- GeneralTransform.cs
- RowToFieldTransformer.cs
- ChameleonKey.cs
- ListViewDeletedEventArgs.cs
- HandleExceptionArgs.cs
- DataTablePropertyDescriptor.cs
- ImageAttributes.cs
- DrawingContextDrawingContextWalker.cs
- CodeGenerator.cs
- ExpressionNode.cs
- DataGridViewLinkColumn.cs
- DatePickerAutomationPeer.cs
- EndpointPerformanceCounters.cs
- _IPv6Address.cs
- QilVisitor.cs
- MemoryStream.cs
- OptimalTextSource.cs
- RegexCompiler.cs
- GeneralTransform.cs
- OperationFormatUse.cs
- MappingItemCollection.cs
- StringAttributeCollection.cs
- MenuItemAutomationPeer.cs
- MimeMapping.cs
- DataSourceProvider.cs
- MultiBinding.cs
- Html32TextWriter.cs
- CustomErrorCollection.cs
- WsdlInspector.cs
- FontSourceCollection.cs
- IPAddress.cs
- webeventbuffer.cs
- ActivityStatusChangeEventArgs.cs
- codemethodreferenceexpression.cs
- CollectionContainer.cs
- SetIndexBinder.cs
- TraceXPathNavigator.cs
- TableCell.cs
- VisualStyleElement.cs
- ClosableStream.cs
- PropertyGridEditorPart.cs
- ParenthesizePropertyNameAttribute.cs
- ContextMenuAutomationPeer.cs
- Image.cs
- ResourcesBuildProvider.cs
- BackStopAuthenticationModule.cs
- SqlSupersetValidator.cs
- Deserializer.cs
- StoreAnnotationsMap.cs
- BidOverLoads.cs
- TiffBitmapEncoder.cs
- DependencyObject.cs
- DataControlFieldCollection.cs
- ConfigurationManagerInternalFactory.cs
- AppDomainAttributes.cs
- Grant.cs
- WebPartActionVerb.cs
- ColorPalette.cs
- XPathDocumentNavigator.cs
- PageClientProxyGenerator.cs
- CssTextWriter.cs
- HighlightVisual.cs
- CellIdBoolean.cs
- BackgroundFormatInfo.cs
- XamlToRtfParser.cs
- DynamicField.cs
- AttributeAction.cs
- SourceElementsCollection.cs
- SoundPlayer.cs
- DataStreamFromComStream.cs
- ComponentDispatcherThread.cs
- DataStreamFromComStream.cs
- cookiecontainer.cs
- RealProxy.cs