Skip to content

Commit

Permalink
Set custom WM_CLASS on Linux based on distributor (closes #294)
Browse files Browse the repository at this point in the history
  • Loading branch information
jwbonner committed Jan 2, 2025
1 parent b673383 commit f52863a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/main/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3205,6 +3205,15 @@ process.env["ELECTRON_DISABLE_SECURITY_WARNINGS"] = "true";
// Silence unhandled promise rejections
process.on("unhandledRejection", () => {});

// Set WM_CLASS for Linux
if (process.platform === "linux") {
if (DISTRIBUTOR === Distributor.WPILib) {
app.setName("AdvantageScope (WPILib)");
} else {
app.setName("AdvantageScope");
}
}

app.whenReady().then(() => {
// Check preferences and set theme
if (!fs.existsSync(PREFS_FILENAME)) {
Expand Down

0 comments on commit f52863a

Please sign in to comment.