summaryrefslogtreecommitdiff
path: root/pkg/systray/systray.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/systray/systray.go')
-rw-r--r--pkg/systray/systray.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/pkg/systray/systray.go b/pkg/systray/systray.go
index 714852d..6bd58b8 100644
--- a/pkg/systray/systray.go
+++ b/pkg/systray/systray.go
@@ -20,6 +20,7 @@ import (
"log"
"os"
"os/signal"
+ "strconv"
"time"
"0xacab.org/leap/bitmask-vpn/icon"
@@ -88,10 +89,21 @@ func (bt *bmTray) setUpSystray() {
bt.mHelp = systray.AddMenuItem(printer.Sprintf("Help..."), "")
bt.mDonate = systray.AddMenuItem(printer.Sprintf("Donate..."), "")
+
bt.mAbout = systray.AddMenuItem(printer.Sprintf("About..."), "")
systray.AddSeparator()
bt.mQuit = systray.AddMenuItem(printer.Sprintf("Quit"), "")
+
+ showDonate, err := strconv.ParseBool(config.AskForDonations)
+ if err != nil {
+ log.Printf("Error parsing AskForDonations: %v", err)
+ showDonate = true
+ }
+ if !showDonate {
+ bt.mDonate.Hide()
+ }
+
}
func (bt *bmTray) loop(bm bitmask.Bitmask, notify *notificator, as bitmask.Autostart) {