When pressing a row in tableView, the row shows grey color, how to disable this?

I created a tableView like this

 \_ui.tableView = widget.newTableView { x = \_var.tableCenterX, y = \_var.tableCenterY, width = \_var.tableWidth, height = \_var.tableHeight, hideBackground = true, onRowRender = \_onRowRender, onRowTouch = \_onRowTouch, noLines = true, hideScrollBar = true, }

I found if I press one of the rows, the pressed row shows grey background color (which is inconsistent with my UI design).

Is this a default behavior?

How to disable this?

My code to insert rows

 for idx=1,num do \_ui.tableView:insertRow( { isCategory = false, rowHeight = 150, rowColor = {1, 1, 1}, }) end

I just found the row becomes “blue” in Android devices, which is even odder.

What happens if you run the SampleCode/Interface/WidgetDemo sample app?

Rob

I ran the demo and I found when a row is pressed, the row becomes “blue” in Simulator.

It’s a different color than my own project. So I figure there must be something that can control it. 

Bingo… there is a “over” attribute that can be set in rowColor:

local rowColor =  {  default = { 255, 255, 255 }, over = { 30, 144, 255 }, }

And I also found it is explained in the document for :insertRow() too. 

Sorry I missed that. Newbie mistake.

My code to insert rows

 for idx=1,num do \_ui.tableView:insertRow( { isCategory = false, rowHeight = 150, rowColor = {1, 1, 1}, }) end

I just found the row becomes “blue” in Android devices, which is even odder.

What happens if you run the SampleCode/Interface/WidgetDemo sample app?

Rob

I ran the demo and I found when a row is pressed, the row becomes “blue” in Simulator.

It’s a different color than my own project. So I figure there must be something that can control it. 

Bingo… there is a “over” attribute that can be set in rowColor:

local rowColor =  {  default = { 255, 255, 255 }, over = { 30, 144, 255 }, }

And I also found it is explained in the document for :insertRow() too. 

Sorry I missed that. Newbie mistake.