From 60f7804d54656a51c3e495cf5df4cdcf8d0268a3 Mon Sep 17 00:00:00 2001 From: lcastel Date: Fri, 19 Jun 2026 10:50:05 +0200 Subject: [PATCH] fix(electron): added missing file from previous commit for electron integration. --- electron-app/src/windows/mainWindow.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/electron-app/src/windows/mainWindow.js b/electron-app/src/windows/mainWindow.js index 0bf125b85..9b88c524f 100644 --- a/electron-app/src/windows/mainWindow.js +++ b/electron-app/src/windows/mainWindow.js @@ -16,7 +16,7 @@ const appPath = getAppPath(); // Store the main window instance let mainWindow = null; // Track the currently loaded view -let currentView = "testing-view"; +let currentView = "competition-view"; /** * Creates and initializes the main application window. @@ -93,10 +93,13 @@ function loadView(view) { // Load the view HTML file mainWindow.loadFile(viewPath); // Update window title based on view type + const titles = { + "competition-view": "Competition View", + "testing-view": "Testing View", + "flashing-view": "Flashing View", + }; mainWindow.setTitle( - `Hyperloop Control Station - ${ - view === "control-station" ? "Competition View" : "Testing View" - }` + `Hyperloop Control Station - ${titles[view] ?? view}`, ); } else { // Log error and show dialog if view not found