forked from 77media/video-flow
移除角色替换处理函数handleReplaceCharacter,改为调用handleStartReplaceCharacter以简化角色替换逻辑,优化代码结构。
This commit is contained in:
parent
8111350709
commit
1de2eb3dd1
@ -142,12 +142,6 @@ export function CharacterTabContent({
|
|||||||
setIgnoreReplace(true);
|
setIgnoreReplace(true);
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleReplaceCharacter = (url: string) => {
|
|
||||||
setEnableAnimation(true);
|
|
||||||
// 替换角色
|
|
||||||
|
|
||||||
setIsReplacePanelOpen(true);
|
|
||||||
};
|
|
||||||
// President Alfred King Samuel Ryan
|
// President Alfred King Samuel Ryan
|
||||||
const handleConfirmReplace = (selectedShots: string[], addToLibrary: boolean) => {
|
const handleConfirmReplace = (selectedShots: string[], addToLibrary: boolean) => {
|
||||||
// 处理替换确认逻辑
|
// 处理替换确认逻辑
|
||||||
@ -192,7 +186,7 @@ export function CharacterTabContent({
|
|||||||
// 使用真实的角色数据
|
// 使用真实的角色数据
|
||||||
const selectedRole = userRoleLibrary[index];
|
const selectedRole = userRoleLibrary[index];
|
||||||
if (selectedRole) {
|
if (selectedRole) {
|
||||||
handleReplaceCharacter(selectedRole.imageUrl);
|
handleStartReplaceCharacter();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user