-
Notifications
You must be signed in to change notification settings - Fork 7
/
events_ui.py
103 lines (62 loc) · 2.04 KB
/
events_ui.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
'''
Created on august 31st, 2016
@author: giroux
'''
from PyQt5.QtCore import QEvent
# Boreholes
class BoreholeAdded(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(BoreholeAdded, self).__init__(BoreholeAdded._type)
class BoreholeDeleted(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(BoreholeDeleted, self).__init__(BoreholeDeleted._type)
class BoreholeEdited(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(BoreholeEdited, self).__init__(BoreholeEdited._type)
# Covariance
class CovarianceEdited(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(CovarianceEdited, self).__init__(CovarianceEdited._type)
# Grid
class GridEdited(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(GridEdited, self).__init__(GridEdited._type)
# Models
class ModelAdded(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(ModelAdded, self).__init__(ModelAdded._type)
class ModelDeleted(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(ModelDeleted, self).__init__(ModelDeleted._type)
class ModelEdited(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(ModelEdited, self).__init__(ModelEdited._type)
# Mogs
class MogAdded(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(MogAdded, self).__init__(MogAdded._type)
class MogDeleted(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(MogDeleted, self).__init__(MogDeleted._type)
class MogEdited(QEvent):
_type = QEvent.registerEventType()
def __init__(self):
super(MogEdited, self).__init__(MogEdited._type)
if __name__ == '__main__':
e = MogAdded()
print(e.type())
print(MogAdded._type == e.type())
e = BoreholeAdded()
print(e.type())
print(BoreholeAdded._type == e.type())
print(MogAdded._type == e.type())