From 7ded8a575267c440eb5f2f09fbe3845470cccf3e Mon Sep 17 00:00:00 2001 From: Hommy <16620803786@163.com> Date: Wed, 1 Apr 2026 13:02:48 +0800 Subject: [PATCH] =?UTF-8?q?=E9=BB=98=E8=AE=A4=E5=90=AF=E7=94=A8=E5=8F=8C?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E5=85=BC=E5=AE=B9=E6=A8=A1=E5=BC=8F=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pyJianYingDraft/script_file.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/pyJianYingDraft/script_file.py b/src/pyJianYingDraft/script_file.py index 97a3938..d2bc394 100644 --- a/src/pyJianYingDraft/script_file.py +++ b/src/pyJianYingDraft/script_file.py @@ -181,6 +181,9 @@ class ScriptFile: imported_tracks: List[ImportedTrack] """导入的轨道信息""" + dual_file_compatibility: bool + """双文件兼容模式,启用时同时保存到 draft_content.json 和 draft_info.json""" + def __init__(self, width: int, height: int, fps: int, maintrack_adsorb: bool): """**创建剪映草稿推荐使用`DraftFolder.create_draft()`而非此方法** @@ -204,6 +207,8 @@ class ScriptFile: self.imported_materials = {} self.imported_tracks = [] + self.dual_file_compatibility = True # 启用双文件兼容模式 + with open(assets.get_asset_path('DRAFT_CONTENT_TEMPLATE'), "r", encoding="utf-8") as f: self.content = json.load(f)