| 156 | } |
| 157 | |
| 158 | void PiuColorsDictionary(xsMachine *the, xsSlot* slot, PiuColor colors) |
| 159 | { |
| 160 | if (xsIsInstanceOf(*slot, xsArrayPrototype)) { |
| 161 | xsIntegerValue i, c = xsToInteger(xsGet(*slot, xsID_length)); |
| 162 | if (c > 4) c = 4; |
| 163 | for (i = 0; i < c; i++) { |
| 164 | xsVar(0) = xsGetAt(*slot, xsInteger(i)); |
| 165 | PiuColorDictionary(the, &xsVar(0), &colors[i]); |
| 166 | } |
| 167 | } |
| 168 | else { |
| 169 | PiuColorRecord color; |
| 170 | PiuColorDictionary(the, slot, &color); |
| 171 | colors[0] = color; |
| 172 | colors[1] = color; |
| 173 | colors[2] = color; |
| 174 | colors[3] = color; |
| 175 | } |
| 176 | } |
| 177 | |
| 178 | void PiuColorsSerialize(xsMachine *the, PiuColor colors) |
| 179 | { |
no test coverage detected