Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / Input / Stylus / StylusButton.cs / 1 / StylusButton.cs
using System; using System.Globalization; namespace System.Windows.Input { ///////////////////////////////////////////////////////////////////////// ////// StylusButton class /// public class StylusButton { ///////////////////////////////////////////////////////////////////// internal StylusButton(string name, Guid id) { _name = name; _guid = id; } ///////////////////////////////////////////////////////////////////// ////// Returns the hardware Guid of the StylusDevice button. /// public Guid Guid { get { return _guid; } } ///////////////////////////////////////////////////////////////////// ////// Returns the current state of the button. /// public StylusButtonState StylusButtonState { // get { StylusPointCollection stylusPoints = StylusDevice.GetStylusPoints(null); if (stylusPoints == null || stylusPoints.Count == 0) return CachedButtonState; return (StylusButtonState)stylusPoints[stylusPoints.Count - 1].GetPropertyValue(new StylusPointProperty(Guid, true)); } } internal StylusButtonState CachedButtonState { get { return _cachedButtonState; } set { _cachedButtonState = value; } } ///////////////////////////////////////////////////////////////////// ////// Returns the name of the button. /// public string Name { get { return _name; } } ///////////////////////////////////////////////////////////////////// ////// Returns StylusDevice object that owns this button. /// public StylusDevice StylusDevice { get { return _stylusDevice; } } ///////////////////////////////////////////////////////////////////// /// internal void SetOwner(StylusDevice stylusDevice) { _stylusDevice = stylusDevice; } ///////////////////////////////////////////////////////////////////// ////// Returns the friendly representation of the button object /// ///public override string ToString() { return String.Format(CultureInfo.CurrentCulture, "{0}({1})", base.ToString(), this.Name); } ///////////////////////////////////////////////////////////////////// StylusDevice _stylusDevice; string _name; Guid _guid; StylusButtonState _cachedButtonState = StylusButtonState.Up; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. name of the tablet
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- XmlDownloadManager.cs
- MatrixCamera.cs
- Trigger.cs
- SharedTcpTransportManager.cs
- ChannelServices.cs
- TreeNodeBinding.cs
- XmlExtensionFunction.cs
- RadioButtonBaseAdapter.cs
- WsdlHelpGeneratorElement.cs
- RawContentTypeMapper.cs
- ModelFactory.cs
- ChildrenQuery.cs
- DbConnectionPoolGroup.cs
- Border.cs
- Matrix.cs
- WindowsPrincipal.cs
- ReturnValue.cs
- Keywords.cs
- mansign.cs
- ClientProxyGenerator.cs
- FrameworkTemplate.cs
- HyperLinkField.cs
- ExpressionNormalizer.cs
- DocumentOrderQuery.cs
- ObjectListTitleAttribute.cs
- CaseStatement.cs
- ScriptDescriptor.cs
- ContainerUIElement3D.cs
- QueueSurrogate.cs
- RelationshipWrapper.cs
- SrgsItemList.cs
- SapiRecognizer.cs
- DesignerSerializationOptionsAttribute.cs
- UrlAuthFailedErrorFormatter.cs
- ConfigXmlCDataSection.cs
- DataAccessor.cs
- CodeDomSerializerBase.cs
- ButtonBaseDesigner.cs
- SqlBulkCopyColumnMapping.cs
- ParameterCollection.cs
- Listen.cs
- EmptyControlCollection.cs
- CodeMemberMethod.cs
- SafeSystemMetrics.cs
- handlecollector.cs
- FontStretchConverter.cs
- DecoderReplacementFallback.cs
- Baml2006KnownTypes.cs
- TimelineClockCollection.cs
- Profiler.cs
- MaterialCollection.cs
- TypeSystemHelpers.cs
- FileStream.cs
- DrawingContextDrawingContextWalker.cs
- RecipientInfo.cs
- SchemaObjectWriter.cs
- SecuritySessionSecurityTokenProvider.cs
- TypeDescriptionProviderAttribute.cs
- LinkLabel.cs
- NameValueSectionHandler.cs
- RegexBoyerMoore.cs
- ColorTransform.cs
- XsltQilFactory.cs
- Operator.cs
- CodeStatementCollection.cs
- Vector.cs
- Emitter.cs
- PinnedBufferMemoryStream.cs
- HandleRef.cs
- CalendarData.cs
- LassoHelper.cs
- ImageAutomationPeer.cs
- XslCompiledTransform.cs
- UnsafeCollabNativeMethods.cs
- WmpBitmapEncoder.cs
- RegexReplacement.cs
- SafeFindHandle.cs
- RoleService.cs
- ParallelActivityDesigner.cs
- SchemaTypeEmitter.cs
- ServiceX509SecurityTokenProvider.cs
- CodeAttachEventStatement.cs
- ModuleBuilderData.cs
- InvalidWMPVersionException.cs
- ParameterToken.cs
- CodeConstructor.cs
- HtmlControl.cs
- BrowserCapabilitiesCompiler.cs
- FloatMinMaxAggregationOperator.cs
- CollectionBuilder.cs
- AppLevelCompilationSectionCache.cs
- DPAPIProtectedConfigurationProvider.cs
- PermissionListSet.cs
- PropertyConverter.cs
- SpotLight.cs
- ActivationArguments.cs
- FileDialog.cs
- _SpnDictionary.cs
- FontSizeConverter.cs
- JoinCqlBlock.cs