Skip to content

Commit

Permalink
#200: adds OS check for linux
Browse files Browse the repository at this point in the history
  • Loading branch information
rladstaetter committed May 1, 2024
1 parent afe98c4 commit a68a3c3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class FileMenu(isUnderTest : Boolean
getItems.clear()
getItems.add(openMenuItem)
getItems.add(closeAllMenuItem)
if (OsUtil.isWin || isUnderTest) {
if (OsUtil.isLinux || OsUtil.isWin || isUnderTest) {
getItems.add(quitMenuItem)
}
}
Expand Down
5 changes: 4 additions & 1 deletion core/src/main/scala/app/logorrr/util/OsUtil.scala
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,15 @@ object OsUtil {
Windows
} else if (System.getProperty("os.name").toLowerCase.contains("mac")) {
Mac
} else {
} else if (System.getProperty("os.name").toLowerCase.contains("linux")) {
Linux
} else {
Windows
}

val isMac: Boolean = currentOs == Mac
val isWin: Boolean = currentOs == Windows
val isLinux: Boolean = currentOs == Linux

// for releases / mac installers this value should always be true
// set this flag only during development to false
Expand Down

0 comments on commit a68a3c3

Please sign in to comment.