Skip to content

Commit

Permalink
Merge branch 'develop' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
lucor committed Sep 21, 2022
2 parents a58f9c2 + 85a5823 commit 6aaa81b
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- name: Setup Go environment
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
go-version: "1.16.x"
go-version: "1.18.x"

- name: Get dependencies
run: sudo apt-get update && sudo apt-get install gcc libgl1-mesa-dev libegl1-mesa-dev libgles2-mesa-dev libx11-dev xorg-dev
Expand All @@ -34,7 +34,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
go-version: ["1.17.x", "1.16.x"]
go-version: ["1.18.x", "1.19.x"]

steps:
- name: Setup Go environment
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@ It is written in Go and uses [Fyne](https://github.com/fyne-io/fyne) as UI toolk

## Screenshot

<div align="center">
<img alt="Paw screenshot" src="screenshot.png" />
<div>
<img alt="Paw - lock view" src="images/lock.png" />
<img alt="Paw - list view" src="images/list.png" />
<img alt="Paw - details view" src="images/details.png" />
</div>

## Main features
Expand Down
Binary file added images/details.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/list.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/lock.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions internal/ui/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,10 @@ func (a *app) makeApp() *container.Scroll {
func (a *app) setVaultViewByName(name string) {
vault, ok := a.unlockedVault[name]
if !ok {
a.vault = nil
a.main.Content = a.makeUnlockVaultView(name)
a.main.Refresh()
a.setWindowTitle()
return
}
a.setVaultView(vault)
Expand All @@ -106,6 +108,7 @@ func (a *app) setVaultView(vault *paw.Vault) {
a.unlockedVault[vault.Name] = vault
a.main.Content = a.makeCurrentVaultView()
a.main.Refresh()
a.setWindowTitle()
}

func (a *app) showAuditPasswordView() {
Expand All @@ -120,6 +123,14 @@ func (a *app) showCurrentVaultView() {
a.win.SetContent(a.main)
}

func (a *app) setWindowTitle() {
title := "Paw"
if a.vault != nil {
title = a.vault.Name + " - " + title
}
a.win.SetTitle(title)
}

func (a *app) showAddItemView() {
a.win.SetContent(a.makeAddItemView())
}
Expand Down
2 changes: 1 addition & 1 deletion internal/ui/menu.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func (a *app) makeVaultMenuItems() []*fyne.MenuItem {
i := i
vaultName := vaultName
mi[i] = fyne.NewMenuItem(vaultName, func() {})
_, isDesktop := fyne.CurrentDevice().(desktop.App)
_, isDesktop := fyne.CurrentApp().(desktop.App)
if isDesktop && i < 9 {
shortcut := &desktop.CustomShortcut{KeyName: fyne.KeyName(fmt.Sprint(i + 1)), Modifier: fyne.KeyModifierControl}
a.win.Canvas().AddShortcut(shortcut, func(shortcut fyne.Shortcut) {
Expand Down
1 change: 1 addition & 0 deletions internal/ui/vault.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ func (a *app) makeCreateVaultView() fyne.CanvasObject {
a.setVaultView(vault)
a.showCurrentVaultView()
a.win.SetMainMenu(a.makeMainMenu())
a.makeSysTray()
})

return container.NewCenter(container.NewVBox(logo, name, password, btn))
Expand Down
Binary file modified screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6aaa81b

Please sign in to comment.