Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / Input / InputProcessorProfilesLoader.cs / 1 / InputProcessorProfilesLoader.cs
//----------------------------------------------------------------------------
//
//
// Copyright (C) Microsoft Corporation. All rights reserved.
//
//
//
// Description: Creates ITfThreadMgr instances, the root object of the Text
// Services Framework.
//
// History:
// 07/30/2003 : [....] - ported from dotnet tree.
//
//---------------------------------------------------------------------------
// PRESHARP: In order to avoid generating warnings about unkown message numbers and unknown pragmas.
#pragma warning disable 1634, 1691
using System;
using System.Runtime.InteropServices;
using System.Security.Permissions;
using System.Security;
using System.Threading;
using Microsoft.Win32;
using System.Diagnostics;
using MS.Win32;
namespace System.Windows.Input
{
//-----------------------------------------------------
//
// InputProcessorProfilesLoader class
//
//-----------------------------------------------------
///
/// Loads an instance of the Text Services Framework.
///
internal static class InputProcessorProfilesLoader
{
//------------------------------------------------------
//
// Constructors
//
//-----------------------------------------------------
#region Constructors
#endregion Constructors
//------------------------------------------------------
//
// Internal Properties
//
//------------------------------------------------------
#region Internal Properties
///
/// Loads an instance of the Text Services Framework.
///
///
/// May return null if no text services are available.
///
///
/// Critical - calls unmanaged code to load the input profiles, returns unmanaged object
///
[SecurityCritical]
internal static UnsafeNativeMethods.ITfInputProcessorProfiles Load()
{
UnsafeNativeMethods.ITfInputProcessorProfiles obj;
Debug.Assert(Thread.CurrentThread.GetApartmentState() == ApartmentState.STA, "Load called on MTA thread!");
//
// Bug#1212202
//
// Presharp warn this though UnsafeNativeMethods.TF_CreateInputProcessorProfiles() does not have
// SetLastError attribute.
// We think this is a false alarm of Presharp.
//
#pragma warning suppress 6523
if (UnsafeNativeMethods.TF_CreateInputProcessorProfiles(out obj) == NativeMethods.S_OK)
{
return obj;
}
return null;
}
#endregion Internal Properties
}
}
// 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
- dsa.cs
- Inline.cs
- GeneratedContractType.cs
- XmlDataSourceNodeDescriptor.cs
- CompositeDesignerAccessibleObject.cs
- IndentedWriter.cs
- Util.cs
- ProjectionPathBuilder.cs
- CharEnumerator.cs
- OpenTypeCommon.cs
- SimpleApplicationHost.cs
- DataGridItem.cs
- FileSystemEventArgs.cs
- TimeSpanSecondsOrInfiniteConverter.cs
- _SpnDictionary.cs
- ProgressiveCrcCalculatingStream.cs
- CallId.cs
- AsymmetricKeyExchangeDeformatter.cs
- TypedAsyncResult.cs
- RemotingException.cs
- DeploymentExceptionMapper.cs
- EntityViewGenerator.cs
- Html32TextWriter.cs
- AnnotationComponentChooser.cs
- XmlSchemaGroup.cs
- SmiXetterAccessMap.cs
- ConfigViewGenerator.cs
- XmlUtf8RawTextWriter.cs
- CharEnumerator.cs
- ViewgenContext.cs
- SoapAttributeAttribute.cs
- SystemIcmpV4Statistics.cs
- sqlstateclientmanager.cs
- XmlSubtreeReader.cs
- UpdatePanelControlTrigger.cs
- SQLByteStorage.cs
- SystemIPGlobalProperties.cs
- OledbConnectionStringbuilder.cs
- Executor.cs
- CommandPlan.cs
- MruCache.cs
- WebServiceClientProxyGenerator.cs
- MediaSystem.cs
- DrawingImage.cs
- ColumnMapCopier.cs
- ToolTipAutomationPeer.cs
- Matrix3DStack.cs
- RijndaelCryptoServiceProvider.cs
- parserscommon.cs
- RenderingEventArgs.cs
- Vector.cs
- SystemEvents.cs
- IApplicationTrustManager.cs
- DataServiceSaveChangesEventArgs.cs
- WindowsStreamSecurityBindingElement.cs
- PrintPreviewGraphics.cs
- XPathAncestorQuery.cs
- ObjectCache.cs
- Splitter.cs
- ScriptReferenceEventArgs.cs
- UriWriter.cs
- SHA1Cng.cs
- FormattedTextSymbols.cs
- Viewport3DVisual.cs
- SystemGatewayIPAddressInformation.cs
- SqlDataSourceCache.cs
- SamlDoNotCacheCondition.cs
- RNGCryptoServiceProvider.cs
- ResourceReader.cs
- NavigationCommands.cs
- EdgeModeValidation.cs
- WebPageTraceListener.cs
- FormsAuthenticationEventArgs.cs
- SiteIdentityPermission.cs
- CorrelationService.cs
- PocoEntityKeyStrategy.cs
- XmlTextEncoder.cs
- GenerateScriptTypeAttribute.cs
- ImageListDesigner.cs
- ToolboxItem.cs
- XmlObjectSerializerWriteContextComplex.cs
- CqlQuery.cs
- HighlightVisual.cs
- Hex.cs
- DockPattern.cs
- DrawingBrush.cs
- WpfWebRequestHelper.cs
- FormViewUpdateEventArgs.cs
- AdapterUtil.cs
- DataPagerField.cs
- DataExpression.cs
- HtmlSelect.cs
- FullTextLine.cs
- MonitoringDescriptionAttribute.cs
- PathGradientBrush.cs
- ValidatedControlConverter.cs
- OperandQuery.cs
- AccessibleObject.cs
- safelinkcollection.cs
- UserControl.cs