Add presentation for buttons.

This commit is contained in:
Nolan Darilek 2018-06-10 20:18:00 +00:00
parent 84df5394cc
commit 417a865bdb
2 changed files with 7 additions and 2 deletions

View File

@ -15,7 +15,6 @@ func augment_tree(node):
func set_initial_screen_focus(screen):
self.augment_tree(get_tree().root)
var focus = find_focusable_control(get_tree().root)
print("Focus ",focus, focus.is_in_group("accessible"))
if not focus:
return
focus.grab_click_focus()

View File

@ -3,7 +3,13 @@ extends Object
var node
func focused():
print("Focus entered.", self.node)
if node is Button:
var text = "Unlabelled"
if node.text:
text = node.text
print("%s: button" % text)
else:
print("Focus entered.", self.node)
func unfocused():
pass