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
- PnrpPermission.cs
- HtmlImage.cs
- NativeRecognizer.cs
- ComponentEditorForm.cs
- SharingService.cs
- ServiceDesigner.cs
- ProcessInfo.cs
- SecureUICommand.cs
- SvcMapFile.cs
- RunWorkerCompletedEventArgs.cs
- Latin1Encoding.cs
- DeclaredTypeValidator.cs
- WebExceptionStatus.cs
- NominalTypeEliminator.cs
- CompletedAsyncResult.cs
- TextFormattingConverter.cs
- AppDomainFactory.cs
- AppDomain.cs
- SecureStringHasher.cs
- SrgsElementFactory.cs
- HtmlTernaryTree.cs
- ActivationServices.cs
- XmlHelper.cs
- xml.cs
- XmlArrayAttribute.cs
- WhereaboutsReader.cs
- TagMapInfo.cs
- GridViewCancelEditEventArgs.cs
- ColumnMapProcessor.cs
- ObjectDataSource.cs
- SchemaObjectWriter.cs
- Token.cs
- ConfigurationElementCollection.cs
- Rss20ItemFormatter.cs
- ToolStripKeyboardHandlingService.cs
- PageCatalogPart.cs
- SignedInfo.cs
- TypeUtil.cs
- HierarchicalDataSourceControl.cs
- ScriptModule.cs
- XmlKeywords.cs
- WebConfigurationHost.cs
- BindingExpressionUncommonField.cs
- Cloud.cs
- WebPartDescription.cs
- BamlRecordWriter.cs
- StaticSiteMapProvider.cs
- PointLight.cs
- MouseEvent.cs
- HandledMouseEvent.cs
- AuthenticationException.cs
- PersonalizablePropertyEntry.cs
- ElasticEase.cs
- D3DImage.cs
- CqlBlock.cs
- StorageTypeMapping.cs
- PropertyDescriptorCollection.cs
- HScrollBar.cs
- TextServicesCompartment.cs
- CategoriesDocument.cs
- DataSourceBooleanViewSchemaConverter.cs
- CodeLabeledStatement.cs
- ScrollChangedEventArgs.cs
- AutomationInteropProvider.cs
- UpdateException.cs
- BamlLocalizableResourceKey.cs
- DataGridParentRows.cs
- MailMessage.cs
- Adorner.cs
- XhtmlBasicCommandAdapter.cs
- CompilerState.cs
- CultureTable.cs
- HtmlInputCheckBox.cs
- EncryptedPackageFilter.cs
- BitmapFrameEncode.cs
- HandoffBehavior.cs
- CodeBinaryOperatorExpression.cs
- KnownColorTable.cs
- WebPartEditVerb.cs
- SettingsProviderCollection.cs
- PrivateFontCollection.cs
- InstanceDataCollection.cs
- XmlSchemaType.cs
- SourceChangedEventArgs.cs
- Figure.cs
- NamespaceList.cs
- AttachedPropertiesService.cs
- ColorIndependentAnimationStorage.cs
- DataGridViewCheckBoxColumn.cs
- ResponseBodyWriter.cs
- DataGridViewSelectedCellCollection.cs
- ScrollProperties.cs
- AssemblyUtil.cs
- RoleManagerEventArgs.cs
- ChoiceConverter.cs
- Encoder.cs
- OleDbConnectionPoolGroupProviderInfo.cs
- ConnectionStringsExpressionBuilder.cs
- FloaterBaseParaClient.cs
- Highlights.cs