DataWindow :
- aggiunta lettura opzioni ferramenta da jwd - sistemate costanti jwd.
This commit is contained in:
@@ -31,12 +31,13 @@ local JSON = require( 'JSON')
|
||||
local function GetJoints( tJoints)
|
||||
local vJoints = {}
|
||||
for i = 1, #tJoints do
|
||||
local nIndex = tJoints[i][JWD_INDEX]
|
||||
if tJoints[i][JWD_JOINT_TYPE] == 'FULL_H' then
|
||||
vJoints[i] = WIN_JNT.FULL_H
|
||||
vJoints[nIndex] = WIN_JNT.FULL_H
|
||||
elseif tJoints[i][JWD_JOINT_TYPE] == 'FULL_V' then
|
||||
vJoints[i] = WIN_JNT.FULL_V
|
||||
vJoints[nIndex] = WIN_JNT.FULL_V
|
||||
elseif tJoints[i][JWD_JOINT_TYPE] == 'ANGLED' then
|
||||
vJoints[i] = WIN_JNT.ANGLED
|
||||
vJoints[nIndex] = WIN_JNT.ANGLED
|
||||
end
|
||||
end
|
||||
return vJoints
|
||||
@@ -173,7 +174,8 @@ local function ConvertTableToGeometry( AreaTable, nParentId)
|
||||
local vDim = {}
|
||||
local tDimensions = AreaTable[JWD_DIMENSION_LIST]
|
||||
for i = 1, #tDimensions do
|
||||
vDim[i] = tDimensions[i][JWD_VALUE]
|
||||
local nIndex = tDimensions[i][JWD_INDEX]
|
||||
vDim[nIndex] = tDimensions[i][JWD_VALUE]
|
||||
end
|
||||
|
||||
-- creo il telaio
|
||||
@@ -202,6 +204,15 @@ local function ConvertTableToGeometry( AreaTable, nParentId)
|
||||
nBottomRailNbr = AreaTable[JWD_BOTTOMRAIL_QTY]
|
||||
end
|
||||
|
||||
-- lettura opzioni ferramenta
|
||||
local HdwOptions = AreaTable[JWD_HARDWARE_OPTIONS] or {}
|
||||
local vsOptions = {}
|
||||
for i = 1, #HdwOptions do
|
||||
local sName = HdwOptions[i][JWD_NAME]
|
||||
local sValue = HdwOptions[i][JWD_VALUE]
|
||||
table.insert( vsOptions, sName .. '=' .. sValue)
|
||||
end
|
||||
|
||||
-- anta singola
|
||||
if #tSashes == 1 then
|
||||
local nOpeningType = GetOpeningType( tSashes[1][JWD_OPENING_TYPE])
|
||||
@@ -222,6 +233,7 @@ local function ConvertTableToGeometry( AreaTable, nParentId)
|
||||
sHandleSide = 'Dx'
|
||||
end
|
||||
WinCreate.AddHardware( nAreaId, AreaTable[JWD_HARDWARE], sHandleSide)
|
||||
EgtSetInfo( nAreaId, WIN_HDW_OPTIONS, vsOptions)
|
||||
-- bottomrail
|
||||
WinCreate.AddBottomRail( nAreaId, nBottomRailNbr)
|
||||
-- analizzo sottaree
|
||||
@@ -254,8 +266,9 @@ local function ConvertTableToGeometry( AreaTable, nParentId)
|
||||
-- aggiungo la ferramenta sull'area split
|
||||
local nSplitAreaId = EgtGetParent( vAreas[1])
|
||||
WinCreate.AddHardware( nSplitAreaId, AreaTable[JWD_HARDWARE], sHandleSide)
|
||||
EgtSetInfo( nSplitAreaId, WIN_HDW_OPTIONS, vsOptions)
|
||||
end
|
||||
|
||||
|
||||
|
||||
-- FILL
|
||||
elseif AreaTable[JWD_AREA_TYPE] == 'FILL' then
|
||||
|
||||
Reference in New Issue
Block a user