Skip to content

Commit

Permalink
Adapt to new component architecture
Browse files Browse the repository at this point in the history
  • Loading branch information
vdelachaux committed Oct 23, 2024
1 parent 0590755 commit 816276e
Show file tree
Hide file tree
Showing 21 changed files with 293 additions and 41 deletions.
Binary file modified Build/4DPop.dmg
Binary file not shown.
Binary file modified Build/4DPop.zip
Binary file not shown.
Binary file modified Build/Components/4DPop.4dbase/4DPop.4DZ
Binary file not shown.
4 changes: 2 additions & 2 deletions Build/Components/4DPop.4dbase/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
<key>NSHumanReadableCopyright</key>
<string>©vdl 2007-2024</string>
<key>CFBundleVersion</key>
<string>269</string>
<string>271</string>
<key>CFBundleDisplayName</key>
<string>4DPop</string>
<key>CFBundleShortVersionString</key>
<string>20R7</string>
<key>CFBundleGetInfoString</key>
<string>20R7</string>
<key>CFBundleLongVersionString</key>
<string>20R7 (268)</string>
<string>20R7 (270)</string>
<key>CFBundleName</key>
<string>4DPop</string>
</dict>
Expand Down
Binary file modified Build/Components/4DPop.4dbase/Libraries/lib4d-arm64.dylib
Binary file not shown.
Binary file modified Build/Components/4DPop.4dbase/Resources/InfoPlist.strings
Binary file not shown.
114 changes: 111 additions & 3 deletions Build/Components/4DPop.4dbase/Resources/en.lproj/syntaxEN.json
Original file line number Diff line number Diff line change
Expand Up @@ -495,6 +495,15 @@
],
"Summary": ""
},
"formName": {
"Syntax": "formName : Text"
},
"windowType": {
"Syntax": "windowType : Integer"
},
"motor": {
"Syntax": "motor : cs.pop.motor"
},
"properties": {
"Syntax": "properties : Object"
},
Expand All @@ -506,9 +515,6 @@
},
"database": {
"Syntax": "database : cs.pop.database"
},
"motor": {
"Syntax": "motor : cs.pop.motor"
}
},
"motor": {
Expand Down Expand Up @@ -862,6 +868,18 @@
]
],
"Summary": ""
},
"bottom": {
"Syntax": "bottom : Integer"
},
"right": {
"Syntax": "right : Integer"
},
"top": {
"Syntax": "top : Integer"
},
"left": {
"Syntax": "left : Integer"
}
},
"_widget": {
Expand Down Expand Up @@ -890,6 +908,69 @@
]
],
"Summary": ""
},
"width": {
"Syntax": "width : Integer"
},
"handler": {
"Syntax": "handler : 4D.Function"
},
"tools": {
"Syntax": "tools : Collection"
},
"popup": {
"Syntax": "popup : Boolean"
},
"plist": {
"Syntax": "plist : 4D.File"
},
"order": {
"Syntax": "order : Integer"
},
"help": {
"Syntax": "help : 4D.File"
},
"infos": {
"Syntax": "infos : Text"
},
"helptip": {
"Syntax": "helptip : Text"
},
"index": {
"Syntax": "index : Integer"
},
"name": {
"Syntax": "name : Text"
},
"visible": {
"Syntax": "visible : Boolean"
},
"default": {
"Syntax": "default : Text"
},
"form": {
"Syntax": "form : Text"
},
"picture": {
"Syntax": "picture : Picture"
},
"manifest": {
"Syntax": "manifest : Object"
},
"file": {
"Syntax": "file : Object"
},
"ondrop": {
"Syntax": "ondrop : Text"
},
"icon": {
"Syntax": "icon : Picture"
},
"copyright": {
"Syntax": "copyright : Text"
},
"tool": {
"Syntax": "tool : Text"
}
},
"menuBar": {
Expand Down Expand Up @@ -942,6 +1023,9 @@
],
"Summary": ""
},
"parameters": {
"Syntax": "parameters : Collection"
},
"_inheritedFrom_": "menu"
},
"svg": {
Expand Down Expand Up @@ -3793,6 +3877,12 @@
],
"Summary": ""
},
"latest": {
"Syntax": "latest : Text"
},
"graphic": {
"Syntax": "graphic : Picture"
},
"store": {
"Syntax": "store : Collection"
},
Expand Down Expand Up @@ -5136,6 +5226,24 @@
]
],
"Summary": ""
},
"errors": {
"Syntax": "errors : Collection"
},
"autoClose": {
"Syntax": "autoClose : Boolean"
},
"xml": {
"Syntax": "xml : Text"
},
"file": {
"Syntax": "file : 4D.File"
},
"success": {
"Syntax": "success : Boolean"
},
"root": {
"Syntax": "root : Text"
}
},
"env": {
Expand Down
4 changes: 2 additions & 2 deletions Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
<key>NSHumanReadableCopyright</key>
<string>©vdl 2007-2024</string>
<key>CFBundleVersion</key>
<string>269</string>
<string>271</string>
<key>CFBundleDisplayName</key>
<string>4DPop</string>
<key>CFBundleShortVersionString</key>
<string>20R7</string>
<key>CFBundleGetInfoString</key>
<string>20R7</string>
<key>CFBundleLongVersionString</key>
<string>20R7 (268)</string>
<string>20R7 (270)</string>
<key>CFBundleName</key>
<string>4DPop</string>
</dict>
Expand Down
20 changes: 17 additions & 3 deletions Project/Sources/Classes/_4DPop.4dm
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ property preferences : cs:C1710.Preferences
property env : cs:C1710.env
property properties : Object

property formName : Text
property windowType : Integer

property _setPosition : Text
property _modifiedOrder : Boolean

// Mark:-
Class constructor

Expand Down Expand Up @@ -86,6 +92,14 @@ Function load() : Object

$component:=$component.parent.parent

Else

//MARK:New component architecture
If ($component.folder("Contents").exists)

$component:=$component.folder("Contents")

End if
End if

// Get the definition file
Expand Down Expand Up @@ -563,13 +577,13 @@ Function doSettings()

End if

If (This:C1470.$setPosition#Null:C1517)
If (This:C1470._setPosition#Null:C1517)

This:C1470.position(This:C1470.$setPosition)
This:C1470.position(This:C1470._setPosition)

End if

If (Bool:C1537(This:C1470.$modifiedOrder))
If (Bool:C1537(This:C1470._modifiedOrder))

$order:={}

Expand Down
6 changes: 4 additions & 2 deletions Project/Sources/Classes/_classCore.4dm
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,11 @@ Function get singleton() : Boolean // Return True if it's a refernce to the cla
return This:C1470.__CLASS__#Null:C1517

// <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <== <==
Function get matrix() : Boolean // Return True if it's the fisrt inastance of the class
Function get matrix() : Boolean // Return True if it's the fisrt instance of the class

//%W-550.26
return This:C1470.__LockerID=Null:C1517
//%W+550.26

// Mark:-
// === === === === === === === === === === === === === === === === === === === === === === === === === ===
Expand Down Expand Up @@ -230,7 +232,7 @@ Function _pushError($message : Text)

var $current; $o : Object
var $c : Collection
$c:=Get call chain:C1662
$c:=Call chain:C1662

For each ($o; $c)

Expand Down
13 changes: 11 additions & 2 deletions Project/Sources/Classes/_widget.4dm
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
property file; manifest : Object
property name; default; ondrop; helptip; tool; form; infos; copyright : Text
property help; plist : 4D:C1709.File
property icon; picture : Picture
property popup; visible : Boolean
property handler : 4D:C1709.Function
property tools : Collection
property order : Integer
property index : Integer
property width : Integer

Class constructor($component : Object; $manifest : Object)

var $item; $key : Text
Expand All @@ -22,9 +33,7 @@ Class constructor($component : Object; $manifest : Object)
This:C1470.handler:=Null:C1517
This:C1470.tools:=[]
This:C1470.order:=0
This:C1470.tool:=""
This:C1470.index:=0
This:C1470.form:=Null:C1517
This:C1470.width:=70

If ($manifest.handler#Null:C1517)
Expand Down
2 changes: 2 additions & 0 deletions Project/Sources/Classes/coord.4dm
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
property left; top; right; bottom : Integer

Class constructor($left : Integer; $top : Integer; $right : Integer; $bottom : Integer)

This:C1470.left:=$left
Expand Down
2 changes: 2 additions & 0 deletions Project/Sources/Classes/menuBar.4dm
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
Class extends menu

property parameters : Collection

Class constructor($menus : Collection)

var $parameter : Text
Expand Down
16 changes: 9 additions & 7 deletions Project/Sources/Classes/svg.4dm
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
Class extends xml

property store : Collection
property _containers; _shapes; _descriptive; _notContainer; _aspectRatioValues; _textRenderingValue; _reservedNames : Collection

Class extends xml
property graphic : Picture
property latest; _current : Text

Class constructor($content)

Super:C1705($content)

This:C1470.latest:=Null:C1517
This:C1470.latest:=""
This:C1470.graphic:=Null:C1517
This:C1470.store:=New collection:C1472

Expand Down Expand Up @@ -4141,7 +4143,7 @@ Function _reset

Super:C1706._reset()

This:C1470.latest:=Null:C1517
This:C1470.latest:=""
This:C1470.graphic:=Null:C1517
This:C1470.store:=New collection:C1472

Expand Down Expand Up @@ -4181,7 +4183,7 @@ Function _getContainer($param) : Text

End if

$name:=Split string:C1554(Get call chain:C1662[1].name; ".")[1]
$name:=Split string:C1554(Call chain:C1662[1].name; ".")[1]

If (This:C1470._notContainer.includes($name))

Expand Down Expand Up @@ -4230,7 +4232,7 @@ Function _getTarget($param) : Text
//_______________________________
: ($param="parent")

If (This:C1470.latest=Null:C1517)
If (This:C1470.latest="")

return This:C1470.root

Expand Down Expand Up @@ -4261,7 +4263,7 @@ Function _getTarget($param) : Text
//_______________________________
End case

return This:C1470.latest#Null:C1517 ? This:C1470.latest : This:C1470.root
return This:C1470.latest#"" ? This:C1470.latest : This:C1470.root

//*** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
// Looks for element "defs", create if not exists
Expand Down
Loading

0 comments on commit 816276e

Please sign in to comment.