-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathview.py
35 lines (27 loc) · 1002 Bytes
/
view.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
from tkinter import *
from seria_controller import SeriaController
class FrameView:
def __init__(self, mainview, controller: SeriaController):
self.mainview = mainview
self.controller: SeriaController = controller
self.frm_container = Frame(mainview.root)
def show(self):
self.frm_container.pack(fill=BOTH, expand=True)
def hide(self):
self.frm_container.pack_forget()
def enable(self):
'''Enable sub widgets such as buttons, entries, etc for interaction.
Override this method in child classes.'''
pass
def disable(self):
'''Disable sub widgets such as buttons, entries, etc for interaction.
Override this method in child classes.'''
pass
def update(self):
'''Update view with data from controller.
Override this method in child classes.'''
pass
def clear(self):
'''Clear view data.
Override this method in child classes.'''
pass