diff options
Diffstat (limited to 'src/createcalls.cpp')
-rw-r--r-- | src/createcalls.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/createcalls.cpp b/src/createcalls.cpp index 2a344a0..800dd49 100644 --- a/src/createcalls.cpp +++ b/src/createcalls.cpp @@ -636,6 +636,14 @@ Project_Layer_Duplicate(project_data *File, project_state *State, memory *Memory History_Action_Block_Swap(Memory, F_Layers, NewLayer); *NewLayer = *Layer; NewLayer->IsSelected = true; + NewLayer->Vertical_Offset--; + + for (int a = i+2; a < LayerCount; a++) { + sorted_layer_array NextSortEntry = SortedLayerStart[a]; + uint32 NextIndex_Physical = NextSortEntry.Block_Layer_Index; + block_layer *NextLayer = (block_layer *)Memory_Block_AddressAtIndex(Memory, F_Layers, NextIndex_Physical); + NextLayer->Vertical_Offset--; + } Assert(!NewLayer->x.Keyframe_Count); Assert(!NewLayer->y.Keyframe_Count); |