Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX: エンジン追加後にプロジェクトの保存をキャンセルすると同じエンジンを複数登録できてしまう問題を修正 #1240

Merged
merged 2 commits into from
Mar 1, 2023

Conversation

sabonerune
Copy link
Contributor

内容

同じエンジンを重複して保存できてしまう問題を修正します。

再現方法

  1. テキストの追加等をして未保存状態(閉じようとすると保存ダイアログが表示される状態)にする
  2. EngineManageDialog開きエンジンを追加する
  3. 再起動のダイアログが表示されるので再起動ボタンを押す
  4. プロジェクトの保存を確認するダイアログが表示されるのでキャンセルする
  5. 追加ボタンが押せる状態なので押すともう一度追加操作ができてしまう

特に既存エンジンを重複登録すると同じエンジンを同時に起動させようとしてしまうため起動が不可能になってしまいます。

その他

ついでに型エラーを修正しておきましたがこの辺りのいい対処方法が分からなかったのでエラーのままにしています。

engineManifests[selectedId].supportedFeatures
)"
:key="feature"
:class="value ? '' : 'text-warning'"
>
{{ getFeatureName(feature) }}:{{ value ? "対応" : "非対応" }}

@sabonerune sabonerune requested a review from a team as a code owner March 1, 2023 11:57
@sabonerune sabonerune requested review from Hiroshiba and removed request for a team March 1, 2023 11:57
@@ -593,6 +601,7 @@ const requireRestart = (message: string) => {
},
})
.onOk(() => {
toInitialState();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

なるほどです!
onCancel側とコピペコードになっていますが、$q.dialogの仕様上仕方ないかもと思いました。

Copy link
Member

@Hiroshiba Hiroshiba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!!

問題ないと思うのでマージします!

(マルチエンジン作ってくださった @sevenc-nanashi さんにも一応共有・・・!)

@Hiroshiba Hiroshiba merged commit 29e807a into VOICEVOX:main Mar 1, 2023
@sabonerune sabonerune deleted the fix/duplicate-engine-dir branch March 1, 2023 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants