diff --git a/config.py b/config.py index b1afae4f..b0149e64 100644 --- a/config.py +++ b/config.py @@ -491,18 +491,6 @@ class Config: self._ENABLE_SEND_MESSAGE_TO_VRC = value saveJson(self.PATH_CONFIG, inspect.currentframe().f_code.co_name, value) - # [deprecated] - # @property - # @json_serializable('STARTUP_OSC_ENABLED_CHECK') - # def STARTUP_OSC_ENABLED_CHECK(self): - # return self._STARTUP_OSC_ENABLED_CHECK - - # @STARTUP_OSC_ENABLED_CHECK.setter - # def STARTUP_OSC_ENABLED_CHECK(self, value): - # if isinstance(value, bool): - # self._STARTUP_OSC_ENABLED_CHECK = value - # saveJson(self.PATH_CONFIG, inspect.currentframe().f_code.co_name, value) - @property @json_serializable('SEND_MESSAGE_FORMAT') def SEND_MESSAGE_FORMAT(self): @@ -670,7 +658,6 @@ class Config: self._ENABLE_NOTICE_XSOVERLAY = False self._ENABLE_SEND_MESSAGE_TO_VRC = True self._ENABLE_SEND_RECEIVED_MESSAGE_TO_VRC = False # speaker2Chatbox - # self._STARTUP_OSC_ENABLED_CHECK = True # [deprecated] self._ENABLE_LOGGER = False self._IS_CONFIG_WINDOW_COMPACT_MODE = False diff --git a/controller.py b/controller.py index d9b6dd89..6e5a50fd 100644 --- a/controller.py +++ b/controller.py @@ -345,9 +345,7 @@ def callbackCloseConfigWindow(): model.stopCheckMicEnergy() model.stopCheckSpeakerEnergy() view.initMicThresholdCheckButton() - # view.initProgressBar_MicEnergy() # ProgressBarに0をセットしたい view.initSpeakerThresholdCheckButton() - # view.initProgressBar_SpeakerEnergy() # ProgressBarに0をセットしたい if config.ENABLE_TRANSCRIPTION_SEND is True: startThreadingTranscriptionSendMessageOnCloseConfigWindow() @@ -413,6 +411,7 @@ def callbackSetUiLanguage(value): config.UI_LANGUAGE = value view.showRestartButtonIfRequired(locale=config.UI_LANGUAGE) + # Translation Tab def callbackSetDeeplAuthkey(value): print("callbackSetDeeplAuthkey", str(value)) @@ -434,7 +433,8 @@ def callbackSetDeeplAuthkey(value): config.AUTH_KEYS = auth_keys config.CHOICE_TRANSLATOR = model.findTranslationEngine(config.SOURCE_LANGUAGE, config.TARGET_LANGUAGE) -# Transcription Tab (Mic) +# Transcription Tab +# Transcription (Mic) def callbackSetMicHost(value): print("callbackSetMicHost", value) config.CHOICE_MIC_HOST = value @@ -568,7 +568,7 @@ def callbackDeleteMicWordFilter(value): except Exception: print("There was no the target word in config.INPUT_MIC_WORD_FILTER") - +# Transcription (Speaker) def callbackSetSpeakerEnergyThreshold(value): print("callbackSetSpeakerEnergyThreshold", value) if value == "": @@ -592,7 +592,6 @@ def callbackSetSpeakerDynamicEnergyThreshold(value): else: view.openSpeakerEnergyThresholdWidget() - def setProgressBarSpeakerEnergy(energy): view.updateSetProgressBar_SpeakerEnergy(energy) @@ -680,6 +679,11 @@ def callbackSetEnableAutoExportMessageLogs(value): else: model.stopLogger() +def callbackSetEnableSendMessageToVrc(value): + print("callbackSetEnableSendMessageToVrc", value) + config.ENABLE_SEND_MESSAGE_TO_VRC = value + +# Others (Message Formats(Send) def callbackSetSendMessageFormat(value): print("callbackSetSendMessageFormat", value) if isUniqueStrings(["[message]"], value) is True: @@ -701,17 +705,7 @@ def callbackSetSendMessageFormatWithT(value): view.showErrorMessage_SendMessageFormatWithT() view.setSendMessageFormatWithT_EntryWidgets(config.SEND_MESSAGE_FORMAT_WITH_T) - -def callbackSetEnableSendMessageToVrc(value): - print("callbackSetEnableSendMessageToVrc", value) - config.ENABLE_SEND_MESSAGE_TO_VRC = value - -# [deprecated] -# def callbackSetStartupOscEnabledCheck(value): -# print("callbackSetStartupOscEnabledCheck", value) -# config.STARTUP_OSC_ENABLED_CHECK = value - - +# Others (Message Formats(Received) def callbackSetReceivedMessageFormat(value): print("callbackSetReceivedMessageFormat", value) if isUniqueStrings(["[message]"], value) is True: @@ -722,7 +716,6 @@ def callbackSetReceivedMessageFormat(value): view.showErrorMessage_ReceivedMessageFormat() view.setReceivedMessageFormat_EntryWidgets(config.RECEIVED_MESSAGE_FORMAT) - def callbackSetReceivedMessageFormatWithT(value): print("callbackSetReceivedMessageFormatWithT", value) if len(value) > 0: @@ -734,7 +727,6 @@ def callbackSetReceivedMessageFormatWithT(value): view.showErrorMessage_ReceivedMessageFormatWithT() view.setReceivedMessageFormatWithT_EntryWidgets(config.RECEIVED_MESSAGE_FORMAT_WITH_T) - # ---------------------Speaker2Chatbox--------------------- def callbackSetEnableSendReceivedMessageToVrc(value): print("callbackSetEnableSendReceivedMessageToVrc", value) @@ -755,6 +747,7 @@ def callbackSetOscPort(value): print("callbackSetOscPort", int(value)) config.OSC_PORT = int(value) + def initSetConfigByExeArguments(): parser = argparse.ArgumentParser() parser.add_argument("--ip") @@ -786,10 +779,6 @@ def createMainWindow(): # set word filter model.addKeywords() - # check OSC started [deprecated] - # if config.STARTUP_OSC_ENABLED_CHECK is True and config.ENABLE_SEND_MESSAGE_TO_VRC is True: - # model.checkOSCStarted(view.printToTextbox_OSCError) - # check Software Updated if model.checkSoftwareUpdated() is True: view.showUpdateAvailableButton() @@ -877,9 +866,10 @@ def createMainWindow(): "callback_set_enable_notice_xsoverlay": callbackSetEnableNoticeXsoverlay, "callback_set_enable_auto_export_message_logs": callbackSetEnableAutoExportMessageLogs, "callback_set_enable_send_message_to_vrc": callbackSetEnableSendMessageToVrc, - # "callback_set_startup_osc_enabled_check": callbackSetStartupOscEnabledCheck, # [deprecated] + # Others(Message Formats(Send) "callback_set_send_message_format": callbackSetSendMessageFormat, "callback_set_send_message_format_with_t": callbackSetSendMessageFormatWithT, + # Others(Message Formats(Received) "callback_set_received_message_format": callbackSetReceivedMessageFormat, "callback_set_received_message_format_with_t": callbackSetReceivedMessageFormatWithT, diff --git a/view.py b/view.py index b1a89b26..3de218d5 100644 --- a/view.py +++ b/view.py @@ -355,12 +355,6 @@ class View(): CALLBACK_SET_ENABLE_SEND_MESSAGE_TO_VRC=None, VAR_ENABLE_SEND_MESSAGE_TO_VRC=BooleanVar(value=config.ENABLE_SEND_MESSAGE_TO_VRC), - # [deprecated] - # VAR_LABEL_STARTUP_OSC_ENABLED_CHECK=StringVar(value=i18n.t("config_window.startup_osc_enabled_check.label")), - # VAR_DESC_STARTUP_OSC_ENABLED_CHECK=StringVar(value=i18n.t("config_window.startup_osc_enabled_check.desc")), - # CALLBACK_SET_STARTUP_OSC_ENABLED_CHECK=None, - # VAR_STARTUP_OSC_ENABLED_CHECK=BooleanVar(value=config.STARTUP_OSC_ENABLED_CHECK), - VAR_SECOND_TITLE_OTHERS_SEND_MESSAGE_FORMATS=StringVar(value=i18n.t("config_window.side_menu_labels.others_send_message_formats")), @@ -556,7 +550,6 @@ class View(): self.view_variable.CALLBACK_SET_ENABLE_AUTO_EXPORT_MESSAGE_LOGS = config_window_registers.get("callback_set_enable_auto_export_message_logs", None) self.view_variable.CALLBACK_SET_ENABLE_SEND_MESSAGE_TO_VRC = config_window_registers.get("callback_set_enable_send_message_to_vrc", None) - # self.view_variable.CALLBACK_SET_STARTUP_OSC_ENABLED_CHECK = config_window_registers.get("callback_set_startup_osc_enabled_check", None) #[deprecated] self.view_variable.CALLBACK_SET_SEND_MESSAGE_FORMAT = config_window_registers.get("callback_set_send_message_format", None) self.view_variable.CALLBACK_SET_SEND_MESSAGE_FORMAT_WITH_T = config_window_registers.get("callback_set_send_message_format_with_t", None) diff --git a/vrct_gui/config_window/widgets/createSideMenuAndSettingsBoxContainers/setting_box_containers/setting_box_others/createSettingBox_Others.py b/vrct_gui/config_window/widgets/createSideMenuAndSettingsBoxContainers/setting_box_containers/setting_box_others/createSettingBox_Others.py index de2e4394..8a10fb6a 100644 --- a/vrct_gui/config_window/widgets/createSideMenuAndSettingsBoxContainers/setting_box_containers/setting_box_others/createSettingBox_Others.py +++ b/vrct_gui/config_window/widgets/createSideMenuAndSettingsBoxContainers/setting_box_containers/setting_box_others/createSettingBox_Others.py @@ -6,11 +6,8 @@ def createSettingBox_Others(setting_box_wrapper, config_window, settings, view_v sbg = _SettingBoxGenerator(setting_box_wrapper, config_window, settings, view_variable) createSettingBoxCheckbox = sbg.createSettingBoxCheckbox createSettingBoxAutoExportMessageLogs = sbg.createSettingBoxAutoExportMessageLogs - createSettingBox_Labels = sbg.createSettingBox_Labels - createSettingBoxMessageFormatEntries_WithTranslation = sbg.createSettingBoxMessageFormatEntries_WithTranslation - # 元 checkbox_auto_clear_chatbox_callback def checkbox_auto_clear_message_box_callback(checkbox_box_widget): callFunctionIfCallable(view_variable.CALLBACK_SET_ENABLE_AUTO_CLEAR_MESSAGE_BOX, checkbox_box_widget.get()) @@ -29,9 +26,6 @@ def createSettingBox_Others(setting_box_wrapper, config_window, settings, view_v def checkbox_enable_send_message_to_vrc_callback(checkbox_box_widget): callFunctionIfCallable(view_variable.CALLBACK_SET_ENABLE_SEND_MESSAGE_TO_VRC, checkbox_box_widget.get()) - # [deprecated] - # def checkbox_startup_osc_enabled_check_callback(checkbox_box_widget): - # callFunctionIfCallable(view_variable.CALLBACK_SET_STARTUP_OSC_ENABLED_CHECK, checkbox_box_widget.get()) row=0 config_window.sb__auto_clear_message_box = createSettingBoxCheckbox( @@ -86,16 +80,4 @@ def createSettingBox_Others(setting_box_wrapper, config_window, settings, view_v variable=view_variable.VAR_ENABLE_SEND_MESSAGE_TO_VRC, ) config_window.sb__enable_send_message_to_vrc.grid(row=row, pady=0) - row+=1 - - # [deprecated] - # config_window.sb__startup_osc_enabled_check = createSettingBoxCheckbox( - # for_var_label_text=view_variable.VAR_LABEL_STARTUP_OSC_ENABLED_CHECK, - # for_var_desc_text=view_variable.VAR_DESC_STARTUP_OSC_ENABLED_CHECK, - # checkbox_attr_name="sb__checkbox_startup_osc_enabled_check", - # command=lambda: checkbox_startup_osc_enabled_check_callback(config_window.sb__checkbox_startup_osc_enabled_check), - # variable=view_variable.VAR_STARTUP_OSC_ENABLED_CHECK, - # ) - # config_window.sb__startup_osc_enabled_check.grid(row=row, pady=0) - # row+=1 - + row+=1 \ No newline at end of file