mirror of
https://github.com/Artemis-RGB/Artemis
synced 2025-12-13 05:48:35 +00:00
Profile editor - Fixed keyframe positions of groups not updating
This commit is contained in:
parent
13d2ee0c3b
commit
ecbc3e4f35
@ -1,4 +1,5 @@
|
|||||||
using System;
|
using System;
|
||||||
|
using System.ComponentModel;
|
||||||
using Artemis.Storage.Entities.Profile;
|
using Artemis.Storage.Entities.Profile;
|
||||||
|
|
||||||
namespace Artemis.Core
|
namespace Artemis.Core
|
||||||
@ -6,7 +7,7 @@ namespace Artemis.Core
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Represents a keyframe on a <see cref="ILayerProperty" /> containing a value and a timestamp
|
/// Represents a keyframe on a <see cref="ILayerProperty" /> containing a value and a timestamp
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public interface ILayerPropertyKeyframe
|
public interface ILayerPropertyKeyframe : INotifyPropertyChanged
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets an untyped reference to the layer property of this keyframe
|
/// Gets an untyped reference to the layer property of this keyframe
|
||||||
|
|||||||
@ -27,6 +27,7 @@ public class TimelineGroupViewModel : ActivatableViewModelBase
|
|||||||
PropertyGroupViewModel.Keyframes
|
PropertyGroupViewModel.Keyframes
|
||||||
.ToObservableChangeSet()
|
.ToObservableChangeSet()
|
||||||
.AutoRefreshOnObservable(_ => profileEditorService.PixelsPerSecond)
|
.AutoRefreshOnObservable(_ => profileEditorService.PixelsPerSecond)
|
||||||
|
.AutoRefreshOnObservable(k => k.WhenAnyValue(kv => kv.Position))
|
||||||
.Transform(k => k.Position.TotalSeconds * _pixelsPerSecond, true)
|
.Transform(k => k.Position.TotalSeconds * _pixelsPerSecond, true)
|
||||||
.Bind(out ReadOnlyObservableCollection<double> keyframePositions)
|
.Bind(out ReadOnlyObservableCollection<double> keyframePositions)
|
||||||
.Subscribe()
|
.Subscribe()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user