Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Media / Animation / SetStoryboardSpeedRatio.cs / 1305600 / SetStoryboardSpeedRatio.cs
/****************************************************************************\ * * File: SetStoryboardSpeedRatio.cs * * This object includes a Storyboard reference. When triggered, the Storyboard * speed ratio is set to the given parameter. * * Copyright (C) by Microsoft Corporation. All rights reserved. * \***************************************************************************/ using System.ComponentModel; // DefaultValueAttribute using System.Diagnostics; // Debug.Assert namespace System.Windows.Media.Animation { ////// SetStoryboardSpeedRatio will set the speed for its Storyboard reference when /// it is triggered. /// public sealed class SetStoryboardSpeedRatio : ControllableStoryboardAction { ////// A speed ratio to use for this action. If it is never explicitly /// specified, it is 1.0. /// [DefaultValue(1.0)] public double SpeedRatio { get { return _speedRatio; } set { if (IsSealed) { throw new InvalidOperationException(SR.Get(SRID.CannotChangeAfterSealed, "SetStoryboardSpeedRatio")); } _speedRatio = value; } } ////// Called when it's time to execute this storyboard action /// internal override void Invoke( FrameworkElement containingFE, FrameworkContentElement containingFCE, Storyboard storyboard ) { Debug.Assert( containingFE != null || containingFCE != null, "Caller of internal function failed to verify that we have a FE or FCE - we have neither." ); if( containingFE != null ) { storyboard.SetSpeedRatio(containingFE, SpeedRatio); } else { storyboard.SetSpeedRatio(containingFCE, SpeedRatio); } } double _speedRatio = 1.0; } } // 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
- ParameterToken.cs
- SessionKeyExpiredException.cs
- EventHandlerList.cs
- FlowchartDesignerCommands.cs
- BinaryParser.cs
- PostBackOptions.cs
- UpdateTranslator.cs
- PropertyDescriptorComparer.cs
- ResourceExpression.cs
- TypeConverterAttribute.cs
- WasEndpointConfigContainer.cs
- GACMembershipCondition.cs
- ObjectStorage.cs
- TraceHandlerErrorFormatter.cs
- DataGridColumnCollection.cs
- ConfigurationStrings.cs
- AsymmetricSignatureDeformatter.cs
- ImageListUtils.cs
- SQLBytesStorage.cs
- MemberProjectionIndex.cs
- Accessible.cs
- TableParaClient.cs
- ProviderBase.cs
- UIElement3DAutomationPeer.cs
- RepeaterItem.cs
- While.cs
- PreviewKeyDownEventArgs.cs
- ComponentResourceKey.cs
- GCHandleCookieTable.cs
- RemoteDebugger.cs
- ProtocolsConfigurationHandler.cs
- SmiEventSink_Default.cs
- WindowsImpersonationContext.cs
- InputDevice.cs
- RoutedEvent.cs
- CommonServiceBehaviorElement.cs
- ContextProperty.cs
- HttpHeaderCollection.cs
- CodeRegionDirective.cs
- InlineUIContainer.cs
- HttpRequest.cs
- TableProvider.cs
- NamespaceMapping.cs
- RectConverter.cs
- MobileControlsSectionHandler.cs
- DbConnectionPool.cs
- SpnegoTokenProvider.cs
- FileChangesMonitor.cs
- TemplatedMailWebEventProvider.cs
- InkSerializer.cs
- COM2PictureConverter.cs
- XmlObjectSerializerWriteContext.cs
- ListControl.cs
- StreamReader.cs
- FragmentQueryProcessor.cs
- HitTestWithGeometryDrawingContextWalker.cs
- SeverityFilter.cs
- TreeNode.cs
- MemoryPressure.cs
- FormClosingEvent.cs
- EmbeddedObject.cs
- System.Data.OracleClient_BID.cs
- FullTrustAssemblyCollection.cs
- ValueType.cs
- SystemFonts.cs
- SetMemberBinder.cs
- RangeBaseAutomationPeer.cs
- SettingsPropertyValue.cs
- PageFunction.cs
- TextServicesCompartmentEventSink.cs
- StickyNoteAnnotations.cs
- WindowsHyperlink.cs
- GetResponse.cs
- LinqToSqlWrapper.cs
- GeneralTransformGroup.cs
- XmlQualifiedNameTest.cs
- TextContainerHelper.cs
- Pointer.cs
- TypeDelegator.cs
- ImageList.cs
- WSFederationHttpBindingCollectionElement.cs
- SqlAliaser.cs
- PlatformCulture.cs
- DataGridHelper.cs
- ServiceProviders.cs
- Focus.cs
- ZipIOModeEnforcingStream.cs
- DataGridViewRowPostPaintEventArgs.cs
- Invariant.cs
- UntrustedRecipientException.cs
- UTF32Encoding.cs
- XPathBinder.cs
- SortFieldComparer.cs
- ToolStripControlHost.cs
- BulletDecorator.cs
- RawStylusActions.cs
- CommandEventArgs.cs
- WebPartVerb.cs
- AutoCompleteStringCollection.cs
- AnnouncementEndpointElement.cs