return VDXMLColorValue.WHITE;
} else {
return null;
}
} else if (color instanceof StyleColorPercentages) {
StyleColorPercentages colorPercentages = (StyleColorPercentages) color;
// Basics of this ripped off from EmulatorStyleColorRenderer
// Might be worth factoring the percent to byte conversion out.
int red = convertPercentageToByte(colorPercentages.getRed());
int green = convertPercentageToByte(colorPercentages.getGreen());
int blue = convertPercentageToByte(colorPercentages.getBlue());
int percentRgb =
(red & 0x0000ff) << 16 |
(green & 0x0000ff) << 8 |
(blue & 0x0000ff);
return getColorForRGB(percentRgb);