Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Core / CSharp / System / Windows / Input / Stylus / Tablet.cs / 1 / Tablet.cs
using System; using System.Windows; using System.Windows.Threading; using System.Security; namespace System.Windows.Input { ///////////////////////////////////////////////////////////////////////// ////// Class containing only static methods to access tablet info. /// public static class Tablet { ///////////////////////////////////////////////////////////////////// ////// Read-only access to the Tablet device associated with the current event /// for the current input manager. /// public static TabletDevice CurrentTabletDevice { get { StylusDevice stylus = Stylus.CurrentStylusDevice; if (stylus == null) return null; return stylus.TabletDevice; } } ///////////////////////////////////////////////////////////////////// ////// Returns the collection of Tablet Devices defined on this tablet. /// ////// Critical: calls into SecurityCritical code (Stylus.TabletDevices) /// PublicOK: - asserts for unmanaged code access (via SUC) to create TabletDevices. /// - returns our collection of TabletDevices which we want public. /// public static TabletDeviceCollection TabletDevices { [SecurityCritical] get { return StylusLogic.CurrentStylusLogic.TabletDevices; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Windows; using System.Windows.Threading; using System.Security; namespace System.Windows.Input { ///////////////////////////////////////////////////////////////////////// ////// Class containing only static methods to access tablet info. /// public static class Tablet { ///////////////////////////////////////////////////////////////////// ////// Read-only access to the Tablet device associated with the current event /// for the current input manager. /// public static TabletDevice CurrentTabletDevice { get { StylusDevice stylus = Stylus.CurrentStylusDevice; if (stylus == null) return null; return stylus.TabletDevice; } } ///////////////////////////////////////////////////////////////////// ////// Returns the collection of Tablet Devices defined on this tablet. /// ////// Critical: calls into SecurityCritical code (Stylus.TabletDevices) /// PublicOK: - asserts for unmanaged code access (via SUC) to create TabletDevices. /// - returns our collection of TabletDevices which we want public. /// public static TabletDeviceCollection TabletDevices { [SecurityCritical] get { return StylusLogic.CurrentStylusLogic.TabletDevices; } } } } // 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
- AudioFormatConverter.cs
- RegexBoyerMoore.cs
- ProxyGenerator.cs
- MimeXmlReflector.cs
- dsa.cs
- CompilerErrorCollection.cs
- DocumentSchemaValidator.cs
- NavigateEvent.cs
- PreProcessor.cs
- Empty.cs
- TextEditorCopyPaste.cs
- SQLCharsStorage.cs
- PerformanceCounterManager.cs
- RedirectionProxy.cs
- TableCellAutomationPeer.cs
- OrderToken.cs
- ContextInformation.cs
- Compilation.cs
- SmuggledIUnknown.cs
- XmlSchemaExternal.cs
- OleDbException.cs
- QualifiedId.cs
- IRCollection.cs
- HttpInputStream.cs
- MarkupObject.cs
- TransportSecurityProtocolFactory.cs
- NegotiateStream.cs
- CodeTypeDeclaration.cs
- ViewStateException.cs
- baseaxisquery.cs
- JpegBitmapEncoder.cs
- StateBag.cs
- DataView.cs
- TeredoHelper.cs
- DataGridViewRowsRemovedEventArgs.cs
- ApplicationException.cs
- ThreadStartException.cs
- DataGridViewSelectedRowCollection.cs
- ReferenceSchema.cs
- GridViewHeaderRowPresenter.cs
- FlowDocumentPageViewerAutomationPeer.cs
- SystemIPv4InterfaceProperties.cs
- GuidConverter.cs
- MobileCapabilities.cs
- PathSegmentCollection.cs
- TypeLoadException.cs
- Attachment.cs
- TextFormatter.cs
- StrokeCollection2.cs
- ServiceProviders.cs
- EpmAttributeNameBuilder.cs
- PreviewPageInfo.cs
- LabelLiteral.cs
- SiteMapDataSource.cs
- Int16Storage.cs
- ColorConvertedBitmapExtension.cs
- SeparatorAutomationPeer.cs
- CodeTypeConstructor.cs
- SamlAuthorizationDecisionClaimResource.cs
- XPathChildIterator.cs
- MobileControlDesigner.cs
- BrowserCapabilitiesCompiler.cs
- AssociationTypeEmitter.cs
- MSHTMLHostUtil.cs
- HttpUnhandledOperationInvoker.cs
- SymmetricKey.cs
- Debug.cs
- TextUtf8RawTextWriter.cs
- AspProxy.cs
- ToolStripLocationCancelEventArgs.cs
- ByteFacetDescriptionElement.cs
- VirtualPathUtility.cs
- TTSEngineTypes.cs
- NameSpaceEvent.cs
- SendKeys.cs
- TextTreeFixupNode.cs
- XmlReflectionMember.cs
- DependentList.cs
- SqlParameterCollection.cs
- XpsDocumentEvent.cs
- XmlSchemaCompilationSettings.cs
- BitConverter.cs
- PenContext.cs
- InternalConfigConfigurationFactory.cs
- HandlerBase.cs
- TdsParserStateObject.cs
- XmlDataSource.cs
- FormViewInsertEventArgs.cs
- SecurityTokenInclusionMode.cs
- AccessedThroughPropertyAttribute.cs
- ArraySortHelper.cs
- PersonalizationProvider.cs
- ActivityValidationServices.cs
- LicenseException.cs
- VisualStateGroup.cs
- HtmlInputImage.cs
- ToolstripProfessionalRenderer.cs
- PanelDesigner.cs
- BooleanAnimationBase.cs
- XmlAttributeCache.cs