-
Notifications
You must be signed in to change notification settings - Fork 0
/
handlers.py
55 lines (35 loc) · 1.65 KB
/
handlers.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
"""
Simple handlers file. Is to be encoded and no more, because main changes happen in screens classes,
which are called in handlers, so you just need to update files in `Python files` in constructor.
"""
from menu import Menu
from birds import Birds
from detail import Detail
from add import Add
from hashmap import HashMap
from seen import Seen
# main menu
def menu_on_start(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Menu.on_start(hashMap, _files, _data)
def menu_on_input(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Menu.on_input(hashMap, _files, _data)
# birds list
def birds_list_on_start(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Birds.on_start(hashMap, _files, _data)
def birds_list_on_input(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Birds.on_input(hashMap, _files, _data)
# add bird
def add_bird_on_start(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Add.on_start(hashMap, _files, _data)
def add_bird_on_input(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Add.on_input(hashMap, _files, _data)
# bird detail
def bird_detail_on_start(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Detail.on_start(hashMap, _files, _data)
def bird_detail_on_input(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Detail.on_input(hashMap, _files, _data)
# seen birds list
def seen_on_start(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Seen.on_start(hashMap, _files, _data)
def seen_on_input(hashMap: HashMap, _files=None, _data=None) -> HashMap:
return Seen.on_input(hashMap, _files, _data)