diff --git a/main-process/Settings.ts b/main-process/Settings.ts index 4a8b94a..5f3e11e 100644 --- a/main-process/Settings.ts +++ b/main-process/Settings.ts @@ -83,6 +83,7 @@ export default class Settings { } set serverName(name: string) { this.model.serverName = name; + this.save(); } set(config: SettingsModel) { @@ -106,6 +107,7 @@ export default class Settings { recentWorkspaces: ["sample/workspace.json"], recentFiles: [], nodeClassify: sampleNodeClassify, + treesDesc: {}, }; this.save(); } diff --git a/package.json b/package.json index 815a3ef..5021ff8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "behavior3editor", - "version": "0.1.8", + "version": "0.1.9", "description": "行为树编辑器", "main": "./dist/main.js", "scripts": { diff --git a/render-process/Explorer.tsx b/render-process/Explorer.tsx index aa52f48..dedcabf 100644 --- a/render-process/Explorer.tsx +++ b/render-process/Explorer.tsx @@ -152,7 +152,7 @@ class FileDataNode { for (let i = this.children.length - 1; i >= 0; i--) { const child = this.children[i]; if (!child.isFolder) { - const keyStr = child.id; + const keyStr = child.text; child.visible = keyStr.includes(keyWord); } else { child.visible = child.setVisible(keyWord);