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
- TreeBuilderBamlTranslator.cs
- XPathDocumentBuilder.cs
- XmlAttributeAttribute.cs
- HistoryEventArgs.cs
- GridViewCellAutomationPeer.cs
- CredentialCache.cs
- ArithmeticException.cs
- ContentOperations.cs
- ComplexObject.cs
- PKCS1MaskGenerationMethod.cs
- XmlSchemaSet.cs
- KoreanCalendar.cs
- JsonServiceDocumentSerializer.cs
- StrongNameIdentityPermission.cs
- PackWebRequestFactory.cs
- RootBrowserWindowProxy.cs
- ObjectToIdCache.cs
- Msmq4SubqueuePoisonHandler.cs
- ChtmlSelectionListAdapter.cs
- RoutedPropertyChangedEventArgs.cs
- TextSchema.cs
- ListViewInsertionMark.cs
- FaultContractAttribute.cs
- ResourceAssociationSet.cs
- HttpModuleActionCollection.cs
- DataStreams.cs
- BufferedReadStream.cs
- XmlDataDocument.cs
- BrowserInteropHelper.cs
- QilIterator.cs
- ConstraintEnumerator.cs
- WindowInteropHelper.cs
- MouseEventArgs.cs
- ManipulationDevice.cs
- PersistenceTypeAttribute.cs
- PaperSize.cs
- Propagator.ExtentPlaceholderCreator.cs
- ToolStripItemCollection.cs
- TrustLevel.cs
- PeerUnsafeNativeCryptMethods.cs
- MapPathBasedVirtualPathProvider.cs
- TextEndOfSegment.cs
- wgx_render.cs
- RegisteredHiddenField.cs
- DependencyPropertyKey.cs
- ImageAnimator.cs
- SmtpException.cs
- TargetInvocationException.cs
- MenuRenderer.cs
- TypeBrowser.xaml.cs
- ResXBuildProvider.cs
- DBCommandBuilder.cs
- MemberPath.cs
- NetworkAddressChange.cs
- UserPreferenceChangingEventArgs.cs
- TimeSpanSecondsConverter.cs
- ChtmlTextBoxAdapter.cs
- SiteMapProvider.cs
- ConditionalExpression.cs
- AdjustableArrowCap.cs
- ExtendedPropertyDescriptor.cs
- Screen.cs
- ToolStripLocationCancelEventArgs.cs
- URI.cs
- ClientTargetSection.cs
- ApplicationTrust.cs
- DataGridSortCommandEventArgs.cs
- versioninfo.cs
- TileBrush.cs
- BindingMAnagerBase.cs
- Control.cs
- ScrollData.cs
- HtmlGenericControl.cs
- OnOperation.cs
- Encoder.cs
- MimeTypeMapper.cs
- DefaultProxySection.cs
- BridgeDataRecord.cs
- BinaryConverter.cs
- SafeCertificateContext.cs
- LoginCancelEventArgs.cs
- TransformCollection.cs
- ToolStripGripRenderEventArgs.cs
- SqlCrossApplyToCrossJoin.cs
- HotSpot.cs
- PersonalizableTypeEntry.cs
- UnmanagedMemoryStreamWrapper.cs
- QilValidationVisitor.cs
- NavigationPropertyEmitter.cs
- PointUtil.cs
- MethodCallConverter.cs
- RegisteredHiddenField.cs
- ActivitySurrogate.cs
- DefaultBindingPropertyAttribute.cs
- DocumentXPathNavigator.cs
- SiblingIterators.cs
- WorkflowServiceBuildProvider.cs
- ScriptResourceAttribute.cs
- CursorInteropHelper.cs
- DataServiceEntityAttribute.cs