fix: preserve last-frame canvas curve and pen edits across the host out-point boundary
这个提交包含在:
1 父节点
dad77aff77
当前提交
8ac7ca43da
9 个文件已更改
+43
-10
没有与搜索条件相匹配的文件
@@ -1,3 +1,4 @@
|
||||
#include "DYScopeDisplayTime.h"
|
||||
#include "DYSpiderState.h"
|
||||
#import "DYHistogram.h"
|
||||
|
||||
@@ -175,7 +176,7 @@ static BOOL DYViewerSanitizeValue(NSDictionary *d,double input,double *output) {
|
||||
if(!active)return NO;
|
||||
id<FxCustomParameterActionAPI_v4>action=[_writerTarget apiForProtocol:@protocol(FxCustomParameterActionAPI_v4)];if(!action)return NO;
|
||||
BOOL valid=NO;[action startAction:self];@try{
|
||||
valid=CMTIME_IS_NUMERIC(action.currentTime)&&CMTimeCompare(action.currentTime,_writerTime)==0&&[self writerValueMatches];
|
||||
valid=CMTIME_IS_NUMERIC(action.currentTime)&&CMTimeCompare(DYHostDisplayedFrameTime(_writerHost,action.currentTime),_writerTime)==0&&[self writerValueMatches];
|
||||
}@finally{[action endAction:self];}return valid;
|
||||
}
|
||||
- (void)beginParameter:(NSDictionary*)descriptor node:(NSString*)nodeID value:(double)value atTime:(CMTime)time {
|
||||
@@ -200,7 +201,7 @@ static BOOL DYViewerSanitizeValue(NSDictionary *d,double input,double *output) {
|
||||
if(!action){[host release];return;}
|
||||
id<PROAPIAccessing>target=nil;NSString *type=nil;
|
||||
[action startAction:self];@try{
|
||||
if(CMTIME_IS_NUMERIC(action.currentTime)&&CMTimeCompare(action.currentTime,time)==0){
|
||||
if(CMTIME_IS_NUMERIC(action.currentTime)&&CMTimeCompare(DYHostDisplayedFrameTime(host,action.currentTime),time)==0){
|
||||
NSDictionary *doc=DYReadTools(host,time).document;
|
||||
if([node hasPrefix:@"base:"]){type=[node substringFromIndex:5];if([DYToolTypes()containsObject:type]&&!DYBaseToolRemoved(doc,type))target=[host retain];}
|
||||
else{NSDictionary *layer=DYToolWithID(doc,node);if(layer){type=layer[@"type"];target=[[DYToolManager alloc]initWithHost:host node:layer];}}
|
||||
@@ -230,7 +231,7 @@ static BOOL DYViewerSanitizeValue(NSDictionary *d,double input,double *output) {
|
||||
if([frozen isEqual:self->_writerLastMesh])return;
|
||||
id<FxCustomParameterActionAPI_v4>a=[self->_writerTarget apiForProtocol:@protocol(FxCustomParameterActionAPI_v4)];BOOL changed=NO,failed=NO;
|
||||
[a startAction:self];@try{
|
||||
if(!CMTIME_IS_NUMERIC(a.currentTime)||CMTimeCompare(a.currentTime,self->_writerTime)!=0||![self writerValueMatches]){failed=YES;}
|
||||
if(!CMTIME_IS_NUMERIC(a.currentTime)||CMTimeCompare(DYHostDisplayedFrameTime(self->_writerHost,a.currentTime),self->_writerTime)!=0||![self writerValueMatches]){failed=YES;}
|
||||
else{
|
||||
if(!self->_writerUndoOpen)self->_writerUndoOpen=[[self->_writerHost apiForProtocol:@protocol(FxUndoAPI)]startUndoGroup:@"画面调整 · 蜘蛛盘"];
|
||||
if(self->_writerUndoOpen){DYAssetState *old=DYReadAssets(self->_writerTarget,self->_writerTime);DYAssetState *next=[[old copy]autorelease];next.spiderMesh=frozen;
|
||||
@@ -264,7 +265,7 @@ static BOOL DYViewerSanitizeValue(NSDictionary *d,double input,double *output) {
|
||||
id<FxCustomParameterActionAPI_v4>action=[_writerTarget apiForProtocol:@protocol(FxCustomParameterActionAPI_v4)];
|
||||
if(!action){[self closeWriter];return;}BOOL conflict=NO,changed=NO,failed=NO;
|
||||
[action startAction:self];@try{
|
||||
conflict=!CMTIME_IS_NUMERIC(action.currentTime)||CMTimeCompare(action.currentTime,_writerTime)!=0||![self writerValueMatches];
|
||||
conflict=!CMTIME_IS_NUMERIC(action.currentTime)||CMTimeCompare(DYHostDisplayedFrameTime(_writerHost,action.currentTime),_writerTime)!=0||![self writerValueMatches];
|
||||
if(!conflict&&anyChanged){
|
||||
id<FxUndoAPI>undo=[_writerHost apiForProtocol:@protocol(FxUndoAPI)];
|
||||
NSString *title=_writerDescriptors.count==1?_writerDescriptors[0][@"title"]:@"图形控件";
|
||||
|
||||
在新工单中引用
屏蔽一个用户