Skip to content

Commit

Permalink
Add context menu item for favoriting folders, too (follow-up for #905)
Browse files Browse the repository at this point in the history
  • Loading branch information
richardwilkes committed Dec 29, 2024
1 parent ba286d6 commit 3d87890
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ux/navigator.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ func (n *Navigator) setupToolBar() {
n.configLibraryButton.ClickCallback = n.configureSelection

n.favoriteButton = unison.NewSVGButton(svg.Star)
n.favoriteButton.Tooltip = newWrappedTooltip(i18n.Text("Favorite"))
n.favoriteButton.Tooltip = newWrappedTooltip(i18n.Text("Toggle Favorite"))
n.favoriteButton.ClickCallback = n.favoriteSelection

first := unison.NewPanel()
Expand Down Expand Up @@ -580,7 +580,7 @@ func (n *Navigator) mouseDown(where unison.Point, button, clickCount int, mod un
cm := f.NewMenu(unison.PopupMenuTemporaryBaseID|unison.ContextMenuIDFlag, "", nil)
id := 1
for _, one := range sel {
if one.IsFile() {
if one.IsFile() || one.IsDirectory() {
cm.InsertItem(-1, newContextMenuItemFromButton(f, &id, n.favoriteButton))
cm.InsertSeparator(-1, true)
break
Expand Down

0 comments on commit 3d87890

Please sign in to comment.