You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bitmap object did not generate code for height property correctly
add enums for ids as well as indexes in generated code
use enums for ids and indexes in the in generated code object definitions
enable full code setting in example files
Copy file name to clipboardExpand all lines: cSourceGen.e
+53-23Lines changed: 53 additions & 23 deletions
Original file line number
Diff line number
Diff line change
@@ -20,13 +20,55 @@ PROC create(fser:PTR TO fileStreamer, libsused:PTR TO CHAR,definitionOnly,useIds
20
20
self.indent:=0
21
21
ENDPROC
22
22
23
+
PROC createEnum(windowName:PTR TO CHAR, listObjects:PTR TO stdlist, ids) OF cSrcGen
24
+
DEF n=0, j
25
+
DEF listObject:PTR TO reactionObject
26
+
DEF tempStr[255]:STRING
27
+
28
+
self.write('enum ')
29
+
IF ids
30
+
StringF(tempStr,'\s_id { ',windowName)
31
+
ELSE
32
+
StringF(tempStr,'\s_idx { ',windowName)
33
+
ENDIF
34
+
LowerStr(tempStr)
35
+
self.write(tempStr)
36
+
n:=0
37
+
FOR j:=0 TO listObjects.count()-1
38
+
IF j>0
39
+
self.write(', ')
40
+
n:=n+2
41
+
ENDIF
42
+
43
+
IF n>60
44
+
self.writeLine('')
45
+
self.write(' ')
46
+
n:=0
47
+
ENDIF
48
+
listObject:=listObjects.item(j)
49
+
listObject.gadindex:=j
50
+
StrCopy(tempStr,listObject.ident)
51
+
LowerStr(tempStr)
52
+
self.write(tempStr)
53
+
n:=n+StrLen(tempStr)
54
+
55
+
IF ids
56
+
StringF(tempStr,'_id = \d',listObject.id)
57
+
self.write(tempStr)
58
+
n:=n+StrLen(tempStr)
59
+
ENDIF
60
+
ENDFOR
61
+
62
+
self.writeLine(' };')
63
+
ENDPROC
64
+
23
65
PROC genHeader(screenObject:PTR TO screenObject,rexxObject:PTR TO rexxObject, windowNames:PTR TO stringlist, windowLayouts:PTR TO stdlist, sharedPort) OF cSrcGen
24
66
DEF tempStr[200]:STRING
25
67
DEF menuItem:PTR TO menuItem
26
68
DEF itemName[200]:STRING
27
69
DEF commKey[10]:STRING
28
70
DEF itemType
29
-
DEF hasarexx,i,j
71
+
DEF hasarexx,i,j,n
30
72
DEF layoutObject:PTR TO reactionObject
31
73
DEF listObjects:PTR TO stdlist
32
74
DEF listObject:PTR TO reactionObject
@@ -492,28 +534,13 @@ PROC genHeader(screenObject:PTR TO screenObject,rexxObject:PTR TO rexxObject, wi
Copy file name to clipboardExpand all lines: eSourceGen.e
+43-32Lines changed: 43 additions & 32 deletions
Original file line number
Diff line number
Diff line change
@@ -21,12 +21,43 @@ PROC create(fser:PTR TO fileStreamer,libsused,definitionOnly,useIds) OF eSrcGen
21
21
self.terminator:=0
22
22
ENDPROC
23
23
24
+
PROC createEnum(windowName:PTR TO CHAR, listObjects:PTR TO stdlist, ids) OF eSrcGen
25
+
DEF n=0, j
26
+
DEF listObject:PTR TO reactionObject
27
+
DEF tempStr[255]:STRING
28
+
29
+
self.write('ENUM ')
30
+
FOR j:=0 TO listObjects.count()-1
31
+
IF j>0
32
+
self.write(', ')
33
+
n:=n+2
34
+
ENDIF
35
+
36
+
IF n>60
37
+
self.writeLine('')
38
+
self.write(' ')
39
+
n:=0
40
+
ENDIF
41
+
listObject:=listObjects.item(j)
42
+
listObject.gadindex:=j
43
+
StrCopy(tempStr,listObject.ident)
44
+
UpperStr(tempStr)
45
+
self.write(tempStr)
46
+
n:=n+StrLen(tempStr)
47
+
IF ids
48
+
StringF(tempStr,'_ID = \d',listObject.id)
49
+
n:=n+StrLen(tempStr)
50
+
self.write(tempStr)
51
+
ENDIF
52
+
ENDFOR
53
+
self.writeLine('')
54
+
ENDPROC
55
+
24
56
PROC genHeader(screenObject:PTR TO screenObject,rexxObject:PTR TO rexxObject, windowNames:PTR TO stringlist, windowLayouts:PTR TO stdlist, sharedPort) OF eSrcGen
25
57
DEF tempStr[200]:STRING
26
-
DEF hasarexx,i,j,n
58
+
DEF hasarexx,i
27
59
DEF layoutObject:PTR TO reactionObject
28
60
DEF listObjects:PTR TO stdlist
29
-
DEF listObject:PTR TO reactionObject
30
61
31
62
hasarexx:=(rexxObject.commands.count()>0) AND (StrLen(rexxObject.hostName)>0)
32
63
@@ -103,36 +134,13 @@ PROC genHeader(screenObject:PTR TO screenObject,rexxObject:PTR TO rexxObject, wi
0 commit comments