[Update] Main Page: Add the software update available button.

This commit is contained in:
Sakamoto Shiina
2024-11-14 10:07:09 +09:00
parent c374a2dc03
commit 4b92c210d6
7 changed files with 57 additions and 0 deletions

View File

@@ -1,5 +1,6 @@
export { useWindow } from "./useWindow";
export { useIsOpenedConfigPage } from "./useIsOpenedConfigPage";
export { useIsSoftwareUpdateAvailable } from "./useIsSoftwareUpdateAvailable";
export { useOpenFolder } from "./useOpenFolder";
export { useMessage } from "./useMessage";
export { useVolume } from "./useVolume";

View File

@@ -0,0 +1,10 @@
import { useStore_IsSoftwareUpdateAvailable } from "@store";
export const useIsSoftwareUpdateAvailable = () => {
const { currentIsSoftwareUpdateAvailable, updateIsSoftwareUpdateAvailable } = useStore_IsSoftwareUpdateAvailable();
return {
currentIsSoftwareUpdateAvailable,
updateIsSoftwareUpdateAvailable,
};
};

View File

@@ -5,6 +5,7 @@ import {
useWindow,
useMessage,
useVolume,
useIsSoftwareUpdateAvailable,
} from "@logics_common";
import {
@@ -81,6 +82,7 @@ export const useReceiveRoutes = () => {
addSentMessageLog,
addReceivedMessageLog,
} = useMessage();
const { updateIsSoftwareUpdateAvailable } = useIsSoftwareUpdateAvailable();
const { updateSoftwareVersion } = useSoftwareVersion();
const { updateEnableAutoMicSelect } = useEnableAutoMicSelect();
const { updateEnableAutoSpeakerSelect } = useEnableAutoSpeakerSelect();
@@ -154,6 +156,7 @@ export const useReceiveRoutes = () => {
"/set/data/main_window_geometry": () => {},
"/run/open_filepath_logs": () => console.log("Opened Directory, Message Logs"),
"/run/open_filepath_config_file": () => console.log("Opened Directory, Config File"),
"/run/update_software_flag": updateIsSoftwareUpdateAvailable,
// Main Page
// Page Controls