Changed 'Tabbable/Focusable' logic to use Active
This commit is contained in:
@@ -162,7 +162,7 @@ func (w *LinearLayout) Draw(screen tcell.Screen) {
|
||||
|
||||
func (w *LinearLayout) SetStyle(s tcell.Style) { w.style = s }
|
||||
func (w *LinearLayout) Active() bool { return w.active }
|
||||
func (w *LinearLayout) SetActive(a bool) {
|
||||
func (w *LinearLayout) SetActive(a bool) bool {
|
||||
w.active = a
|
||||
if w.active {
|
||||
act := w.findActiveOrFirst()
|
||||
@@ -170,6 +170,7 @@ func (w *LinearLayout) SetActive(a bool) {
|
||||
act.SetActive(true)
|
||||
}
|
||||
}
|
||||
return w.active
|
||||
}
|
||||
func (w *LinearLayout) Visible() bool { return w.visible }
|
||||
func (w *LinearLayout) SetVisible(a bool) { w.visible = a }
|
||||
|
||||
Reference in New Issue
Block a user