Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / Media / Effects / DropShadowBitmapEffect.cs / 1 / DropShadowBitmapEffect.cs
//------------------------------------------------------------------------------ // Microsoft Avalon // Copyright (c) Microsoft Corporation, 2005 // // File: BitmapEffectDropShadow.cs //----------------------------------------------------------------------------- #region Using directives using System; using System.Collections.Generic; using System.Text; using System.Runtime.InteropServices; using MS.Internal.PresentationCore; using System.Security; #endregion namespace System.Windows.Media.Effects { ////// The class definition for DropShadowBitmapEffect /// public partial class DropShadowBitmapEffect { ////// Constructor /// public DropShadowBitmapEffect() { } ////// Creates the unmanaged effect handle /// unsafe protected override SafeHandle CreateUnmanagedEffect() { return Create(new Guid(0x459a3fbe, 0xd8ac, 0x4692, 0x87, 0x4b, 0x7a, 0x26, 0x57, 0x15, 0xaa, 0x16)); } ////// /// Update (propagetes) properties to the unmanaged effect /// ////// This method demands permission because effects should not be run /// in partial trust. /// /// SecurityCritical - because SetValue has a link demand /// SecutiryTreatAsSafe - because it demans UIWindow permission /// [SecurityCritical, SecurityTreatAsSafe] protected override void UpdateUnmanagedPropertyState(SafeHandle unmanagedEffect) { SecurityHelper.DemandUIWindowPermission(); BitmapEffect.SetValue(unmanagedEffect, "Color", this.Color); BitmapEffect.SetValue(unmanagedEffect, "ShadowDepth", this.ShadowDepth); BitmapEffect.SetValue(unmanagedEffect, "Direction", this.Direction); BitmapEffect.SetValue(unmanagedEffect, "Noise", this.Noise); BitmapEffect.SetValue(unmanagedEffect, "Opacity", this.Opacity); BitmapEffect.SetValue(unmanagedEffect, "Softness", this.Softness); } } } // 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
- FrugalList.cs
- DataBoundLiteralControl.cs
- XpsManager.cs
- XPathParser.cs
- LogLogRecordEnumerator.cs
- TrackingProfileSerializer.cs
- OdbcErrorCollection.cs
- StringOutput.cs
- GridViewCancelEditEventArgs.cs
- ElementNotEnabledException.cs
- COM2IDispatchConverter.cs
- InkCanvasInnerCanvas.cs
- XmlNodeReader.cs
- OperationDescriptionCollection.cs
- RowToParametersTransformer.cs
- XmlDomTextWriter.cs
- IsolatedStorageException.cs
- BitmapEffectInput.cs
- HostProtectionPermission.cs
- SystemException.cs
- ModulesEntry.cs
- figurelength.cs
- WindowsButton.cs
- UnsafeNativeMethodsMilCoreApi.cs
- UnhandledExceptionEventArgs.cs
- CqlWriter.cs
- ApplyImportsAction.cs
- TextPointer.cs
- WebMessageBodyStyleHelper.cs
- IProvider.cs
- MetadataArtifactLoaderFile.cs
- ThicknessAnimation.cs
- CommunicationObject.cs
- _SSPIWrapper.cs
- PermissionSet.cs
- MSHTMLHostUtil.cs
- PageStatePersister.cs
- BitmapImage.cs
- SecurityPermission.cs
- IOException.cs
- unsafenativemethodsother.cs
- ExtensionWindowHeader.cs
- ListBox.cs
- AutoCompleteStringCollection.cs
- AppDomainFactory.cs
- SQLInt64Storage.cs
- Region.cs
- EqualityComparer.cs
- Point3D.cs
- MatrixStack.cs
- FlowchartDesignerCommands.cs
- ErrorsHelper.cs
- CharacterMetricsDictionary.cs
- AtomServiceDocumentSerializer.cs
- DataServiceClientException.cs
- TypeRestriction.cs
- RichTextBoxConstants.cs
- QilUnary.cs
- SelectorItemAutomationPeer.cs
- _HeaderInfoTable.cs
- UndoManager.cs
- ComplexTypeEmitter.cs
- RtfNavigator.cs
- UnsafePeerToPeerMethods.cs
- XomlCompiler.cs
- UserControlDesigner.cs
- MouseButton.cs
- VarRemapper.cs
- SimpleType.cs
- ReferencedType.cs
- COM2ExtendedTypeConverter.cs
- DataColumnMappingCollection.cs
- ReadOnlyCollection.cs
- PropertyGridCommands.cs
- CacheForPrimitiveTypes.cs
- CaseInsensitiveOrdinalStringComparer.cs
- XslAst.cs
- PipeStream.cs
- AstTree.cs
- Geometry3D.cs
- ArraySegment.cs
- TitleStyle.cs
- XpsResource.cs
- WebPartActionVerb.cs
- ApplicationServicesHostFactory.cs
- DllNotFoundException.cs
- MetadataSet.cs
- ListViewGroupConverter.cs
- DesignerDataSchemaClass.cs
- DataGridViewCellContextMenuStripNeededEventArgs.cs
- ItemsChangedEventArgs.cs
- TransportDefaults.cs
- NeutralResourcesLanguageAttribute.cs
- DispatcherProcessingDisabled.cs
- X509InitiatorCertificateServiceElement.cs
- Misc.cs
- QueryOperator.cs
- ItemsControl.cs
- AsyncOperationManager.cs
- DelayLoadType.cs