diff options
author | Ruben Pollan <meskio@sindominio.net> | 2018-03-20 11:29:44 +0100 |
---|---|---|
committer | Ruben Pollan <meskio@sindominio.net> | 2018-03-20 11:33:39 +0100 |
commit | 24e77dd9ca2a9ca30c9c65823aea87c607896145 (patch) | |
tree | 7f3d300dd0673ff7b1eb1950a1092af9b90a1318 | |
parent | 52c02085d2c86a49692d7013a423d04f7c1254d8 (diff) |
[feat] let's not notify about donations for now
As MVP we decided to remove the donations notifications for now.
- Resolves: #21
-rw-r--r-- | notificator.go | 2 | ||||
-rw-r--r-- | systray.go | 16 |
2 files changed, 1 insertions, 17 deletions
diff --git a/notificator.go b/notificator.go index 7c53d18..9ce224f 100644 --- a/notificator.go +++ b/notificator.go @@ -41,7 +41,7 @@ func newNotificator(conf *systrayConfig) *notificator { AppName: "RiseupVPN", }) n := notificator{notify, conf} - go n.donations() + //go n.donations() return &n } @@ -33,7 +33,6 @@ type bmTray struct { mTurnOn *systray.MenuItem mTurnOff *systray.MenuItem mDonate *systray.MenuItem - mHaveDonated *systray.MenuItem mCancel *systray.MenuItem activeGateway *gatewayTray } @@ -71,7 +70,6 @@ func (bt *bmTray) onReady() { mHelp := systray.AddMenuItem(printer.Sprintf("Help ..."), "") bt.mDonate = systray.AddMenuItem(printer.Sprintf("Donate ..."), "") - bt.mHaveDonated = systray.AddMenuItem(printer.Sprintf("... I have donated"), "") mAbout := systray.AddMenuItem(printer.Sprintf("About ..."), "") systray.AddSeparator() @@ -86,8 +84,6 @@ func (bt *bmTray) onReady() { } for { - bt.updateDonateMenu() - select { case status := <-ch: log.Println("status: " + status) @@ -107,8 +103,6 @@ func (bt *bmTray) onReady() { open.Run("https://riseup.net/vpn") case <-bt.mDonate.ClickedCh: open.Run("https://riseup.net/donate-vpn") - case <-bt.mHaveDonated.ClickedCh: - bt.conf.setDonated() case <-mAbout.ClickedCh: open.Run("https://bitmask.net") @@ -209,16 +203,6 @@ func (bt *bmTray) changeStatus(status string) { bt.mStatus.SetTooltip(printer.Sprintf("RiseupVPN is %v", statusStr)) } -func (bt *bmTray) updateDonateMenu() { - if bt.conf.hasDonated() { - bt.mHaveDonated.Hide() - bt.mDonate.Hide() - } else { - bt.mHaveDonated.Show() - bt.mDonate.Show() - } -} - func (bt *bmTray) waitIcon() { icons := [][]byte{icon.Wait0, icon.Wait1, icon.Wait2, icon.Wait3} for i := 0; true; i = (i + 1) % 4 { |