Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / 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
- RotateTransform3D.cs
- DoubleCollectionValueSerializer.cs
- DatatypeImplementation.cs
- CommonRemoteMemoryBlock.cs
- XmlSchemaSimpleType.cs
- HealthMonitoringSection.cs
- AssemblyNameProxy.cs
- CharacterBuffer.cs
- BitmapEffectGroup.cs
- SymbolType.cs
- UnlockInstanceAsyncResult.cs
- StackOverflowException.cs
- XmlAtomicValue.cs
- Floater.cs
- HttpDictionary.cs
- ImageBrush.cs
- TripleDES.cs
- WebPartConnectionsCancelVerb.cs
- MobileUITypeEditor.cs
- CodeDomDesignerLoader.cs
- ParserHooks.cs
- MailMessageEventArgs.cs
- WpfSharedXamlSchemaContext.cs
- AsyncResult.cs
- DataGridViewTopLeftHeaderCell.cs
- WorkflowInstanceSuspendedRecord.cs
- EditingCommands.cs
- RangeExpression.cs
- ComboBoxItem.cs
- RewritingSimplifier.cs
- ExpressionBuilder.cs
- Rectangle.cs
- WindowsPen.cs
- SqlUserDefinedAggregateAttribute.cs
- Zone.cs
- PixelFormatConverter.cs
- CmsUtils.cs
- RawUIStateInputReport.cs
- SchemaExporter.cs
- ImportStoreException.cs
- SystemWebExtensionsSectionGroup.cs
- Compensation.cs
- BaseDataList.cs
- _DigestClient.cs
- HtmlDocument.cs
- ImmutableObjectAttribute.cs
- ContextMenu.cs
- CharStorage.cs
- GenericXmlSecurityToken.cs
- ListControlBuilder.cs
- DataRowChangeEvent.cs
- DataTrigger.cs
- PersonalizationProviderHelper.cs
- SimpleRecyclingCache.cs
- XmlQueryType.cs
- Form.cs
- MouseGesture.cs
- ByteConverter.cs
- ValidatorCollection.cs
- TextEditorCopyPaste.cs
- FormViewRow.cs
- ManifestResourceInfo.cs
- ColorPalette.cs
- RegexTree.cs
- Type.cs
- ValueUtilsSmi.cs
- Vector3DAnimation.cs
- EdmSchemaAttribute.cs
- WebBrowserSiteBase.cs
- OutputCacheSettings.cs
- SemaphoreFullException.cs
- TraceSection.cs
- MultipartIdentifier.cs
- BasicExpandProvider.cs
- CodeNamespaceImportCollection.cs
- EmptyStringExpandableObjectConverter.cs
- PrimitiveType.cs
- WizardStepCollectionEditor.cs
- ParseElementCollection.cs
- TableRowCollection.cs
- BitmapEffectState.cs
- ValidationSummaryDesigner.cs
- ResourceType.cs
- TextOptions.cs
- MouseButtonEventArgs.cs
- NamespaceMapping.cs
- ListDictionary.cs
- XmlAttributeProperties.cs
- WindowsFormsSectionHandler.cs
- XmlILIndex.cs
- DispatcherHookEventArgs.cs
- ListControlConvertEventArgs.cs
- EntityTemplateFactory.cs
- OutputBuffer.cs
- ResourceDescriptionAttribute.cs
- ReadOnlyAttribute.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- Encoder.cs
- WebBrowserPermission.cs
- LogWriteRestartAreaState.cs