CTkMVC 0.0.1__tar.gz → 0.0.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of CTkMVC might be problematic. Click here for more details.
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/PKG-INFO +2 -2
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/README.md +1 -1
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/pyproject.toml +1 -1
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/src/ctkmvc/controller.py +4 -2
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/src/ctkmvc/model.py +3 -1
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/src/ctkmvc/view.py +6 -3
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/.gitignore +0 -0
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/LICENSE +0 -0
- {ctkmvc-0.0.1 → ctkmvc-0.0.3}/src/ctkmvc/interface.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: CTkMVC
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.3
|
|
4
4
|
Summary: Base classes for easy using MVC pattern with CTk library
|
|
5
5
|
Project-URL: GitHub, https://github.com/ovxrhxavxn/ctkmvc
|
|
6
6
|
Author-email: Ivan Kirov <evankirk@vk.com>
|
|
@@ -48,7 +48,7 @@ class MyWindow(View):
|
|
|
48
48
|
|
|
49
49
|
super().__init__(controller, model)
|
|
50
50
|
|
|
51
|
-
self.wm_title('
|
|
51
|
+
self.wm_title('Window')
|
|
52
52
|
|
|
53
53
|
self.resizable(False, False)
|
|
54
54
|
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
from abc import ABC
|
|
2
2
|
from typing import TYPE_CHECKING
|
|
3
3
|
|
|
4
|
-
from model import ObservableModel
|
|
4
|
+
from .model import ObservableModel
|
|
5
5
|
|
|
6
6
|
if TYPE_CHECKING:
|
|
7
|
-
from view import View
|
|
7
|
+
from .view import View
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
class Controller(ABC):
|
|
11
11
|
|
|
12
|
+
'''Base abstract class for controllers'''
|
|
13
|
+
|
|
12
14
|
def __init__(self, view_cls: 'type[View]', model: ObservableModel):
|
|
13
15
|
|
|
14
16
|
self._view = view_cls(self, model)
|
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
from customtkinter import CTk
|
|
2
2
|
from typing import TYPE_CHECKING
|
|
3
|
+
from abc import ABC
|
|
3
4
|
|
|
4
|
-
from interface import ModelObserver
|
|
5
|
-
from model import ObservableModel
|
|
5
|
+
from .interface import ModelObserver
|
|
6
|
+
from .model import ObservableModel
|
|
6
7
|
|
|
7
8
|
if TYPE_CHECKING:
|
|
8
|
-
from controller import Controller
|
|
9
|
+
from .controller import Controller
|
|
9
10
|
|
|
10
11
|
|
|
11
12
|
class View(CTk, ModelObserver):
|
|
12
13
|
|
|
14
|
+
'''Base class for views'''
|
|
15
|
+
|
|
13
16
|
def __init__(self, controller: 'Controller', model: ObservableModel):
|
|
14
17
|
|
|
15
18
|
super().__init__()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|