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
- CultureInfo.cs
- PriorityQueue.cs
- ViewManager.cs
- SystemResources.cs
- ServiceContractViewControl.cs
- LogicalMethodInfo.cs
- WebBrowserBase.cs
- TypeGeneratedEventArgs.cs
- StringToken.cs
- SelectionService.cs
- DBBindings.cs
- DetailsViewDeleteEventArgs.cs
- ObsoleteAttribute.cs
- ConfigurationPropertyAttribute.cs
- ToolStripOverflow.cs
- ContentIterators.cs
- RIPEMD160Managed.cs
- EntityCommand.cs
- FormatterServices.cs
- CallbackHandler.cs
- DefaultValueConverter.cs
- ListViewSortEventArgs.cs
- StaticTextPointer.cs
- LayoutEditorPart.cs
- ResourceDisplayNameAttribute.cs
- SHA384.cs
- ObjectKeyFrameCollection.cs
- webproxy.cs
- StylusEventArgs.cs
- FtpRequestCacheValidator.cs
- XmlEventCache.cs
- RuntimeArgumentHandle.cs
- RegexMatch.cs
- SchemaAttDef.cs
- IntSumAggregationOperator.cs
- SubclassTypeValidator.cs
- LiteralTextParser.cs
- OpCellTreeNode.cs
- Thread.cs
- RectangleHotSpot.cs
- CompositeTypefaceMetrics.cs
- HttpEncoderUtility.cs
- _TransmitFileOverlappedAsyncResult.cs
- EdmEntityTypeAttribute.cs
- PublishLicense.cs
- XPathDocumentNavigator.cs
- HtmlTitle.cs
- GcSettings.cs
- GridViewRowCollection.cs
- AutomationElementCollection.cs
- ReflectionTypeLoadException.cs
- GeneralTransform.cs
- TextSimpleMarkerProperties.cs
- ArraySortHelper.cs
- ProcessModelSection.cs
- JpegBitmapEncoder.cs
- ContentTextAutomationPeer.cs
- EntryPointNotFoundException.cs
- BamlResourceSerializer.cs
- TimeIntervalCollection.cs
- Crc32.cs
- SpotLight.cs
- InputScopeManager.cs
- GetPageCompletedEventArgs.cs
- EventHandlersStore.cs
- HttpHandlersSection.cs
- ISessionStateStore.cs
- AxDesigner.cs
- FormViewModeEventArgs.cs
- SortDescriptionCollection.cs
- StackBuilderSink.cs
- OleStrCAMarshaler.cs
- DropSource.cs
- MimeFormImporter.cs
- ToolStripDropDown.cs
- RestHandler.cs
- StatusBarPanelClickEvent.cs
- DiscoveryInnerClientAdhocCD1.cs
- EntityDataReader.cs
- CodeTypeParameterCollection.cs
- HttpHandlersInstallComponent.cs
- TdsParserHelperClasses.cs
- SemanticResultValue.cs
- TableSectionStyle.cs
- HttpModuleActionCollection.cs
- DataRowView.cs
- X509CertificateValidationMode.cs
- columnmapkeybuilder.cs
- GenericAuthenticationEventArgs.cs
- SplitContainer.cs
- EpmHelper.cs
- HttpPostedFile.cs
- LogicalExpr.cs
- ReceiveDesigner.xaml.cs
- TransformGroup.cs
- SrgsSemanticInterpretationTag.cs
- GradientBrush.cs
- GacUtil.cs
- _Events.cs
- Query.cs