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
- DataGridState.cs
- QueryIntervalOp.cs
- DataTablePropertyDescriptor.cs
- FileAuthorizationModule.cs
- MethodImplAttribute.cs
- CloseCryptoHandleRequest.cs
- CellTreeNode.cs
- CLRBindingWorker.cs
- TextRunProperties.cs
- ConfigurationValue.cs
- ValidationSummary.cs
- RegionInfo.cs
- webbrowsersite.cs
- EDesignUtil.cs
- Cursors.cs
- QueueException.cs
- FieldMetadata.cs
- DefaultCommandExtensionCallback.cs
- DeferrableContentConverter.cs
- XmlSerializationWriter.cs
- RequiredArgumentAttribute.cs
- JournalEntry.cs
- SQLInt32Storage.cs
- IUnknownConstantAttribute.cs
- MachineSettingsSection.cs
- UnhandledExceptionEventArgs.cs
- ListViewItem.cs
- MethodImplAttribute.cs
- ServiceNameElementCollection.cs
- COM2PictureConverter.cs
- Calendar.cs
- URI.cs
- RenderContext.cs
- BypassElementCollection.cs
- SecurityUtils.cs
- SqlProfileProvider.cs
- DataGridPagerStyle.cs
- AtlasWeb.Designer.cs
- BindingFormattingDialog.cs
- CodeTypeParameterCollection.cs
- Block.cs
- Label.cs
- EmbeddedMailObjectsCollection.cs
- StorageTypeMapping.cs
- HandlerFactoryCache.cs
- ClockController.cs
- FlowDocumentFormatter.cs
- XsltArgumentList.cs
- EntityStoreSchemaFilterEntry.cs
- InternalConfigSettingsFactory.cs
- StorageAssociationSetMapping.cs
- AnchoredBlock.cs
- WhitespaceReader.cs
- CacheDependency.cs
- FileDialog_Vista.cs
- FontStretches.cs
- MemberAccessException.cs
- SocketPermission.cs
- NullReferenceException.cs
- BookmarkScopeHandle.cs
- ConfigurationStrings.cs
- SID.cs
- MiniAssembly.cs
- TableHeaderCell.cs
- EntityConnectionStringBuilderItem.cs
- ZoneButton.cs
- XNameTypeConverter.cs
- EventPrivateKey.cs
- Run.cs
- ChildrenQuery.cs
- TableAdapterManagerNameHandler.cs
- ToolBarPanel.cs
- RecipientInfo.cs
- ListBase.cs
- DataGridViewRow.cs
- SqlDataSource.cs
- _SSPIWrapper.cs
- ListViewInsertEventArgs.cs
- HttpCacheVary.cs
- ResourceDefaultValueAttribute.cs
- EventSource.cs
- MeasureData.cs
- ExtendedPropertyCollection.cs
- InstanceNormalEvent.cs
- DataGridItemEventArgs.cs
- HttpVersion.cs
- CanonicalFormWriter.cs
- EdmFunction.cs
- LinkedResourceCollection.cs
- ColorConvertedBitmapExtension.cs
- HtmlFormAdapter.cs
- UIHelper.cs
- WebPartEditorCancelVerb.cs
- DataAdapter.cs
- BufferAllocator.cs
- GraphicsContainer.cs
- Padding.cs
- SqlCachedBuffer.cs
- OdbcTransaction.cs
- GridViewSelectEventArgs.cs