How I can change background color to red for row if row had timeToReply>15. I can't get timeToReply in rowDelegate. How I can do this ?

Qt Code:
  1. TableView
  2. {
  3. model: someModel
  4. TableViewColumn{title:"Time";role: "timeToReply";width: 170}
  5. rowDelegate: Item {
  6. clip: true
  7. Text {
  8. anchors.verticalCenter: parent.verticalCenter
  9. color: {
  10. if(timeToReply>15) //problem
  11. {
  12. color="red"
  13. }
  14. else
  15. {
  16. color="black"
  17. }
  18. }
  19. text: styleData.value
  20. elide: Text.ElideMiddle
  21. }
  22. }
  23. }
To copy to clipboard, switch view to plain text mode