diff --git a/bin/nwg-drawer b/bin/nwg-drawer index 96d5e38..4490732 100755 Binary files a/bin/nwg-drawer and b/bin/nwg-drawer differ diff --git a/main.go b/main.go index f2aeee2..841cfc1 100644 --- a/main.go +++ b/main.go @@ -314,11 +314,13 @@ func main() { // Focus 1st pinned item if any, otherwise focus 1st found app icon var button gtk.IWidget if pinnedFlowBox.GetChildren().Length() > 0 { - button, _ = pinnedFlowBox.GetChildAtIndex(0).GetChild() + button, err = pinnedFlowBox.GetChildAtIndex(0).GetChild() } else { - button, _ = appFlowBox.GetChildAtIndex(0).GetChild() + button, err = appFlowBox.GetChildAtIndex(0).GetChild() + } + if err == nil { + button.ToWidget().GrabFocus() } - button.ToWidget().GrabFocus() userDirsMap = mapXdgUserDirs()