From e84764dcd904530772acc161191fd3e6fcb78946 Mon Sep 17 00:00:00 2001 From: misyaguziya Date: Sun, 17 Sep 2023 07:40:07 +0900 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B[bugfix]=20main=20config.ENABLE=5FT?= =?UTF-8?q?RANSCRIPTION=5FSEND=20is=20True=20=E3=81=8B=E3=81=A4=20config.E?= =?UTF-8?q?NABLE=5FTRANSCRIPTION=5FRECEIVE=20is=20True=E3=81=AE=E5=A0=B4?= =?UTF-8?q?=E5=90=88=E3=81=AB=E3=83=87=E3=83=90=E3=82=A4=E3=82=B9=E3=83=89?= =?UTF-8?q?=E3=83=A9=E3=82=A4=E3=83=90=E3=81=AE=E3=82=A2=E3=82=AF=E3=82=BB?= =?UTF-8?q?=E3=82=B9=E5=B9=B2=E6=B8=89=E3=81=8C=E8=B5=B7=E3=81=8D=E3=81=AA?= =?UTF-8?q?=E3=81=84=E3=82=88=E3=81=86=E3=81=ABNOP=E3=82=92=E8=BF=BD?= =?UTF-8?q?=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/main.py b/main.py index 1a5eca28..696b8c64 100644 --- a/main.py +++ b/main.py @@ -1,3 +1,4 @@ +from time import sleep from threading import Thread from config import config from model import model @@ -242,18 +243,19 @@ def callbackOpenConfigWindow(): view.foregroundOff() def callbackCloseConfigWindow(): - if config.ENABLE_TRANSCRIPTION_SEND is True: - startThreadingTranscriptionSendMessage() - if config.ENABLE_TRANSCRIPTION_RECEIVE is True: - startThreadingTranscriptionReceiveMessage() model.stopCheckMicEnergy() + model.stopCheckSpeakerEnergy() view.replaceMicThresholdCheckButton_Passive() # view.initProgressBar_MicEnergy() # ProgressBarに0をセットしたい - - model.stopCheckSpeakerEnergy() view.replaceSpeakerThresholdCheckButton_Passive() # view.initProgressBar_SpeakerEnergy() # ProgressBarに0をセットしたい + if config.ENABLE_TRANSCRIPTION_SEND is True: + startThreadingTranscriptionSendMessage() + if config.ENABLE_TRANSCRIPTION_RECEIVE is True: + sleep(2) + if config.ENABLE_TRANSCRIPTION_RECEIVE is True: + startThreadingTranscriptionReceiveMessage() if config.ENABLE_FOREGROUND is True: view.foregroundOn()