mirror of
https://github.com/taigrr/wtf
synced 2025-01-18 04:03:14 -08:00
Widget#focus now a thing
Widgets can inform whether or not they should get tab focus. Widgets that provide additional functionality should return true. Widgets that have no extra capability should return false. This allows the FocusTracker to only tab through and focus on widgets for which it provides value.
This commit is contained in:
@@ -25,7 +25,7 @@ type Widget struct {
|
||||
// NewWidget creates and returns a new instance of the weather Widget.
|
||||
func NewWidget() *Widget {
|
||||
widget := Widget{
|
||||
TextWidget: wtf.NewTextWidget(" Weather ", "weather"),
|
||||
TextWidget: wtf.NewTextWidget(" Weather ", "weather", true),
|
||||
APIKey: os.Getenv("WTF_OWM_API_KEY"),
|
||||
Idx: 0,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user