This commit is contained in:
zhuzichu
2023-09-28 12:31:20 +08:00
parent 0e4d81c7c8
commit 52c806eeff
4 changed files with 96 additions and 12 deletions

View File

@ -275,11 +275,18 @@ Rectangle {
property var tableModel: table_model
property var position: item_table.position
property int row: position.y
property var modelData: table_model.getRow(row)
property int column: position.x
property var options: {
if(typeof(itemData) == "object"){
return itemData.options
}
return {}
}
anchors.fill: parent
sourceComponent: {
if(itemData instanceof Component){
return itemData
if(typeof(itemData) == "object"){
return itemData.comId
}
return com_text
}
@ -530,4 +537,13 @@ Rectangle {
scroll_bar_h.position = 0
scroll_bar_v.position = 0
}
function customItem(comId,options={}){
var o = {}
o.comId = comId
o.options = options
return o
}
function updateRow(row,obj){
table_model.setRow(row,obj)
}
}