try swing

This commit is contained in:
Aria Moradi 2021-05-21 15:55:37 +04:30
parent fa071aee84
commit 2356537f7c

View File

@ -9,7 +9,6 @@ package ir.armor.tachidesk.server.util
import dorkbox.systemTray.MenuItem import dorkbox.systemTray.MenuItem
import dorkbox.systemTray.SystemTray import dorkbox.systemTray.SystemTray
import dorkbox.systemTray.SystemTray.TrayType
import dorkbox.util.CacheUtil import dorkbox.util.CacheUtil
import dorkbox.util.Desktop import dorkbox.util.Desktop
import ir.armor.tachidesk.server.BuildConfig import ir.armor.tachidesk.server.BuildConfig
@ -30,8 +29,8 @@ fun systemTray(): SystemTray? {
try { try {
// ref: https://github.com/dorkbox/SystemTray/blob/master/test/dorkbox/TestTray.java // ref: https://github.com/dorkbox/SystemTray/blob/master/test/dorkbox/TestTray.java
SystemTray.DEBUG = serverConfig.debugLogsEnabled SystemTray.DEBUG = serverConfig.debugLogsEnabled
if (System.getProperty("os.name").startsWith("Windows")) // if (System.getProperty("os.name").startsWith("Windows"))
SystemTray.FORCE_TRAY_TYPE = TrayType.Swing // SystemTray.FORCE_TRAY_TYPE = TrayType.Swing
CacheUtil.clear(BuildConfig.name) CacheUtil.clear(BuildConfig.name)