mirror of
https://github.com/stashapp/stash.git
synced 2025-12-06 00:13:46 +01:00
update mac notification (#6329)
This commit is contained in:
parent
a3ed381901
commit
97c01c70b3
1 changed files with 7 additions and 1 deletions
|
|
@ -3,6 +3,7 @@
|
|||
package desktop
|
||||
|
||||
import (
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/kermieisinthehouse/systray"
|
||||
|
|
@ -20,7 +21,12 @@ func startSystray(exit chan int, faviconProvider FaviconProvider) {
|
|||
// system is started from a non-terminal method, e.g. double-clicking an icon.
|
||||
c := config.GetInstance()
|
||||
if c.GetShowOneTimeMovedNotification() {
|
||||
SendNotification("Stash has moved!", "Stash now runs in your tray, instead of a terminal window.")
|
||||
// Use platform-appropriate terminology
|
||||
location := "tray"
|
||||
if runtime.GOOS == "darwin" {
|
||||
location = "menu bar"
|
||||
}
|
||||
SendNotification("Stash has moved!", "Stash now runs in your "+location+", instead of a terminal window.")
|
||||
c.SetBool(config.ShowOneTimeMovedNotification, false)
|
||||
if err := c.Write(); err != nil {
|
||||
logger.Errorf("Error while writing configuration file: %v", err)
|
||||
|
|
|
|||
Loading…
Reference in a new issue