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
- ConfigUtil.cs
- DataGridViewEditingControlShowingEventArgs.cs
- ProcessInfo.cs
- Rijndael.cs
- LambdaCompiler.Address.cs
- PackWebRequestFactory.cs
- ExceptionValidationRule.cs
- CssClassPropertyAttribute.cs
- GlobalizationSection.cs
- ChtmlPageAdapter.cs
- Trace.cs
- GeneratedContractType.cs
- ResourceSet.cs
- ColorDialog.cs
- ReflectEventDescriptor.cs
- NamedPipeAppDomainProtocolHandler.cs
- WindowsIdentity.cs
- X509Certificate2.cs
- StringValueSerializer.cs
- DmlSqlGenerator.cs
- IDictionary.cs
- LoginName.cs
- XmlBindingWorker.cs
- WebPartTracker.cs
- CompModSwitches.cs
- RegexCompiler.cs
- XmlSerializationWriter.cs
- CookieParameter.cs
- StringCollection.cs
- WindowExtensionMethods.cs
- ErrorLog.cs
- WebPartMovingEventArgs.cs
- RoleManagerModule.cs
- OrderByBuilder.cs
- DiscoveryDocumentReference.cs
- LambdaCompiler.Binary.cs
- streamingZipPartStream.cs
- milrender.cs
- PageHandlerFactory.cs
- TreeViewItem.cs
- XmlSchemaSimpleContentRestriction.cs
- ThreadAttributes.cs
- ThreadStateException.cs
- FlowDocumentFormatter.cs
- MenuTracker.cs
- PromptStyle.cs
- CheckBoxRenderer.cs
- CodeMethodInvokeExpression.cs
- DataControlPagerLinkButton.cs
- SqlHelper.cs
- NameObjectCollectionBase.cs
- HeaderCollection.cs
- HashUtility.cs
- EndpointDiscoveryMetadata.cs
- ComAwareEventInfo.cs
- BoundPropertyEntry.cs
- WorkflowInstanceAbortedRecord.cs
- ClientScriptManager.cs
- ControlParameter.cs
- IPCCacheManager.cs
- AdornedElementPlaceholder.cs
- SurrogateEncoder.cs
- RuleRef.cs
- ThrowHelper.cs
- DrawingDrawingContext.cs
- MsmqHostedTransportManager.cs
- Roles.cs
- GuidelineSet.cs
- NameTable.cs
- FormatConvertedBitmap.cs
- UnsafeNativeMethods.cs
- BaseDataListPage.cs
- UnsafeMethods.cs
- Panel.cs
- ColorTransformHelper.cs
- BufferBuilder.cs
- OdbcException.cs
- Inline.cs
- OleCmdHelper.cs
- HandlerWithFactory.cs
- InkPresenter.cs
- MediaTimeline.cs
- AspNetHostingPermission.cs
- ComEventsSink.cs
- RegexBoyerMoore.cs
- ZipIOExtraField.cs
- DataBoundControlAdapter.cs
- RowBinding.cs
- MessageHeaderDescription.cs
- ImmutablePropertyDescriptorGridEntry.cs
- GridViewCancelEditEventArgs.cs
- SystemWebSectionGroup.cs
- InternalBufferOverflowException.cs
- SuppressMessageAttribute.cs
- ScrollViewerAutomationPeer.cs
- MaskedTextBox.cs
- ConnectionStringsExpressionBuilder.cs
- HyperLinkColumn.cs
- RegisteredArrayDeclaration.cs
- WorkflowInlining.cs