MCPcopy
hub / github.com/flet-dev/flet / add_clicked

Method add_clicked

sdk/python/examples/apps/todo/main.py:136–142  ·  view source on GitHub ↗
(self, e)

Source from the content-addressed store, hash-verified

134 ]
135
136 async def add_clicked(self, e):
137 if self.new_task.value:
138 task = Task(self.new_task.value, self.task_delete)
139 self.tasks.controls.append(task)
140 self.new_task.value = ""
141 await self.new_task.focus()
142 self.update()
143
144 def task_delete(self, task):
145 self.tasks.controls.remove(task)

Callers

nothing calls this directly

Calls 4

updateMethod · 0.95
appendMethod · 0.80
TaskClass · 0.70
focusMethod · 0.45

Tested by

no test coverage detected