2013-05-28 2 views
0

안녕하세요,OnRowRender Corona SDK 1076 데이터가 표시되지 않습니다.

목록에 내 테이블의 내용을 표시 할 때 문제가 있습니다. 이 조치는 각 행의 데이터에 대한 인상을주지 않으며 이유를 이해하지 못합니다.

필자는 1076 버전의 Corona SDK를 가지고 있으며 작동하지 않지만 이전 IF로 작동했습니다.

귀하의 도움을 바랍니다.

local function onRowRender(event) 
    print("oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo") 
     local phase = event.phase 
     local row = event.row 
     local rowGroup = event.view 
     local label = aux.corrigeEspeciales (rowTitles[ row.index ]) 
     local color = 20 
     print ("label" .. label) 
     row.itemName = label 
     row.textObj = display.newRetinaText(rowGroup,label, 0, 0, "Verdana", 12) 
     row.textObj:setTextColor(color) 
     row.textObj:setReferencePoint(display.CenterLeftReferencePoint) 
     row.textObj.x, row.textObj.y = 20, rowGroup.contentHeight * 0.5 
     rowGroup:insert(row.textObj) 
     row.arrow = display.newImage("images/tiendarowArrow.png", false) 
     row.arrow.x = rowGroup.contentWidth - row.arrow.contentWidth * 2 
     row.arrow.y = rowGroup.contentHeight * 0.5 
     rowGroup:insert(row.arrow)    
    end 

enter image description here

답변

0

당신은 사용 2013.1076 코로나 SDK 버전에서 텍스트 정보를 표시 할 수 있습니다 :

 local phase = event.phase 
     local row = event.row 
     local rowGroup = event.view 
     local label = aux.corrigeEspeciales (rowTitles[ row.index ]) 
     local color = 20 
     row.itemName = label 

     local rowTitle = display.newText(row,label, 0, 0, "Verdana", 12) 
     rowTitle.x = row.x - (row.contentWidth * 0.5) + (rowTitle.contentWidth * 0.5) 
     rowTitle.y = row.contentHeight * 0.5 
     rowTitle:setTextColor(0, 0, 0) 
0

코로나 1076 I 위젯 2.0 위젯을 사용하여 생각합니다. 행 그룹을 판별하기 위해 다른 구.이 필요합니다. 위젯을 새로운 구문으로 업데이트하는 방법에 대한이 기사를 참조하십시오.

http://docs.coronalabs.com/api/library/widget/migration.html

또한 새 공용 빌드, 위젯 라이브러리에 상당한 버그 수정이 포함되어 1135있다. 내가 당신에게 이러한 수정 프로그램을 가지고 업그레이 드하는 것이 좋습니다 것입니다.