Skip to content

Commit ed694b3

Browse files
committed
fixpath adjustmnt again
1 parent ffc2acf commit ed694b3

File tree

82 files changed

+425
-361
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+425
-361
lines changed

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
*.pyc
1+
.pyc

MiddleKit/.idea/vcs.xml

+6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

MiddleKit/.idea/workspace.xml

+23-14
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Binary file not shown.
3.78 KB
Binary file not shown.
Binary file not shown.
357 Bytes
Binary file not shown.
502 Bytes
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
359 Bytes
Binary file not shown.
585 Bytes
Binary file not shown.
12.1 KB
Binary file not shown.
Binary file not shown.
Binary file not shown.
588 Bytes
Binary file not shown.
Binary file not shown.
11.6 KB
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
502 Bytes
Binary file not shown.
426 Bytes
Binary file not shown.

MiddleKit/Design/Doc.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
import sys
1111
import time
1212

13-
from . import FixPath
13+
#from . import FixPath
14+
import FixPath
1415
import MiddleKit
1516
from MiscUtils.Funcs import valueForString
1617
from WebUtils.Funcs import htmlEncode
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
163 Bytes
Binary file not shown.

MiddleKit/Tests/WorkDir/Bar.py

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
'''
2+
Bar.py
3+
'''
4+
5+
6+
from GeneratedPy.GenBar import GenBar
7+
8+
9+
class Bar(GenBar):
10+
11+
def __init__(self):
12+
GenBar.__init__(self)

MiddleKit/Tests/WorkDir/Dummy.py

-12
This file was deleted.

MiddleKit/Tests/WorkDir/GeneratedPy/GenDummy.py MiddleKit/Tests/WorkDir/GeneratedPy/GenBar.py

+36-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
'''
2-
GenDummy.py
2+
GenBar.py
33
Generated by MiddleKit.
44
'''
55

66
# MK attribute caches for setFoo() methods
77
_xAttr = None
8+
_yAttr = None
89

910

1011
from datetime import date, datetime, time, timedelta
@@ -18,11 +19,12 @@
1819

1920

2021

21-
class GenDummy(MiddleObject):
22+
class GenBar(MiddleObject):
2223

2324
def __init__(self):
2425
MiddleObject.__init__(self)
2526
self._x = None
27+
self._y = None
2628

2729

2830
def x(self):
@@ -57,3 +59,35 @@ def setX(self, value):
5759
# Tell ObjectStore it happened
5860
self._mk_store.objectChanged(self)
5961

62+
def y(self):
63+
return self._y
64+
65+
def setY(self, value):
66+
if value is not None:
67+
if isinstance(value, int):
68+
value = int(value)
69+
#if isinstance(value, int):
70+
# raise OverflowError(value)
71+
elif not isinstance(value, int):
72+
raise TypeError('expecting int type, but got value %r of type %r instead' % (value, type(value)))
73+
74+
# set the attribute
75+
origValue = self._y
76+
self._y = value
77+
78+
# MiddleKit machinery
79+
if not self._mk_initing and self._mk_serialNum>0 and value is not origValue:
80+
global _yAttr
81+
if _yAttr is None:
82+
_yAttr = self.klass().lookupAttr('y')
83+
if not _yAttr.shouldRegisterChanges():
84+
_yAttr = 0
85+
if _yAttr:
86+
# Record that it has been changed
87+
self._mk_changed = True
88+
if self._mk_changedAttrs is None:
89+
self._mk_changedAttrs = {} # maps name to attribute
90+
self._mk_changedAttrs['y'] = _yAttr # changedAttrs is a set
91+
# Tell ObjectStore it happened
92+
self._mk_store.objectChanged(self)
93+

0 commit comments

Comments
 (0)