Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Framework / System / Windows / Automation / Peers / GridSplitterAutomationPeer.cs / 1 / GridSplitterAutomationPeer.cs
using System; using System.Runtime.InteropServices; using System.Security; using System.Text; using System.Windows; using System.Windows.Automation.Provider; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows.Interop; using System.Windows.Media; using MS.Internal; using MS.Win32; namespace System.Windows.Automation.Peers { /// public class GridSplitterAutomationPeer : ThumbAutomationPeer, ITransformProvider { /// public GridSplitterAutomationPeer(GridSplitter owner): base(owner) {} /// override protected string GetClassNameCore() { return "GridSplitter"; } /// override public object GetPattern(PatternInterface patternInterface) { if (patternInterface == PatternInterface.Transform) return this; return null; } #region ITransformProvider bool ITransformProvider.CanMove { get { return true; } } bool ITransformProvider.CanResize { get { return false; } } bool ITransformProvider.CanRotate { get { return false; } } void ITransformProvider.Move(double x, double y) { if (!IsEnabled()) throw new ElementNotEnabledException(); if (double.IsInfinity(x) || double.IsNaN(x)) throw new ArgumentOutOfRangeException("x"); if (double.IsInfinity(y) || double.IsNaN(y)) throw new ArgumentOutOfRangeException("y"); ((GridSplitter)Owner).KeyboardMoveSplitter(x, y); } void ITransformProvider.Resize(double width, double height) { throw new InvalidOperationException(SR.Get(SRID.UIA_OperationCannotBePerformed)); } void ITransformProvider.Rotate(double degrees) { throw new InvalidOperationException(SR.Get(SRID.UIA_OperationCannotBePerformed)); } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Runtime.InteropServices; using System.Security; using System.Text; using System.Windows; using System.Windows.Automation.Provider; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows.Interop; using System.Windows.Media; using MS.Internal; using MS.Win32; namespace System.Windows.Automation.Peers { /// public class GridSplitterAutomationPeer : ThumbAutomationPeer, ITransformProvider { /// public GridSplitterAutomationPeer(GridSplitter owner): base(owner) {} /// override protected string GetClassNameCore() { return "GridSplitter"; } /// override public object GetPattern(PatternInterface patternInterface) { if (patternInterface == PatternInterface.Transform) return this; return null; } #region ITransformProvider bool ITransformProvider.CanMove { get { return true; } } bool ITransformProvider.CanResize { get { return false; } } bool ITransformProvider.CanRotate { get { return false; } } void ITransformProvider.Move(double x, double y) { if (!IsEnabled()) throw new ElementNotEnabledException(); if (double.IsInfinity(x) || double.IsNaN(x)) throw new ArgumentOutOfRangeException("x"); if (double.IsInfinity(y) || double.IsNaN(y)) throw new ArgumentOutOfRangeException("y"); ((GridSplitter)Owner).KeyboardMoveSplitter(x, y); } void ITransformProvider.Resize(double width, double height) { throw new InvalidOperationException(SR.Get(SRID.UIA_OperationCannotBePerformed)); } void ITransformProvider.Rotate(double degrees) { throw new InvalidOperationException(SR.Get(SRID.UIA_OperationCannotBePerformed)); } #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
- XmlHierarchicalDataSourceView.cs
- QualificationDataAttribute.cs
- TraceRecords.cs
- ToolStripCodeDomSerializer.cs
- returneventsaver.cs
- ToolstripProfessionalRenderer.cs
- DrawingDrawingContext.cs
- VersionedStreamOwner.cs
- TemplateField.cs
- CacheHelper.cs
- Msmq4PoisonHandler.cs
- ApplicationDirectory.cs
- SeekableReadStream.cs
- PageContent.cs
- TextAction.cs
- WorkflowQueueInfo.cs
- XmlComplianceUtil.cs
- Buffer.cs
- GetPageNumberCompletedEventArgs.cs
- BindStream.cs
- RuntimeCompatibilityAttribute.cs
- Accessible.cs
- SafeNativeMethods.cs
- UIElementAutomationPeer.cs
- CellPartitioner.cs
- SpecularMaterial.cs
- DrawingContext.cs
- DescendentsWalkerBase.cs
- BitmapEditor.cs
- SecurityBindingElementImporter.cs
- Ray3DHitTestResult.cs
- InitialServerConnectionReader.cs
- ApplicationHost.cs
- DataSourceHelper.cs
- BuildManagerHost.cs
- LexicalChunk.cs
- FlowDocumentScrollViewerAutomationPeer.cs
- Message.cs
- ToolStripDropDownClosingEventArgs.cs
- SynchronousChannelMergeEnumerator.cs
- PeerNameRecordCollection.cs
- HtmlInputReset.cs
- XsltFunctions.cs
- XmlDataSource.cs
- Compress.cs
- ErrorTableItemStyle.cs
- XamlRtfConverter.cs
- RuleSetDialog.Designer.cs
- ObjectKeyFrameCollection.cs
- ClientScriptManager.cs
- AuthenticationService.cs
- HttpModuleAction.cs
- ProfileParameter.cs
- MemberDomainMap.cs
- CustomValidator.cs
- TreeViewItemAutomationPeer.cs
- CroppedBitmap.cs
- TypeNameConverter.cs
- ToolStripEditorManager.cs
- TextBoxLine.cs
- EncodingNLS.cs
- latinshape.cs
- Registry.cs
- GenericWebPart.cs
- InputScopeNameConverter.cs
- JsonMessageEncoderFactory.cs
- DataErrorValidationRule.cs
- SqlNodeTypeOperators.cs
- SpotLight.cs
- SqlParameter.cs
- IntegrationExceptionEventArgs.cs
- SamlAdvice.cs
- ExpressionBinding.cs
- DBNull.cs
- InkCanvasFeedbackAdorner.cs
- AssemblyAttributesGoHere.cs
- EventPropertyMap.cs
- DbInsertCommandTree.cs
- DataListItemCollection.cs
- DiagnosticsConfigurationHandler.cs
- DigitalSignatureProvider.cs
- SpellerInterop.cs
- NameValueFileSectionHandler.cs
- XamlFilter.cs
- PageOrientation.cs
- ValueTable.cs
- CustomExpression.cs
- SR.cs
- OverflowException.cs
- FormViewCommandEventArgs.cs
- WindowsListViewItemCheckBox.cs
- DataSetViewSchema.cs
- OleDbConnectionInternal.cs
- PageVisual.cs
- WCFServiceClientProxyGenerator.cs
- TextDecorationCollection.cs
- BidirectionalDictionary.cs
- QuaternionConverter.cs
- TypeForwardedToAttribute.cs
- CustomCategoryAttribute.cs