1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

JuceDemo: make Tables in WidgetDemo look nicer by adding zebra striping

This commit is contained in:
Timur Doumler 2015-04-20 16:45:21 +01:00
parent ee3fe813e1
commit f04e0f0462

View file

@ -741,10 +741,13 @@ public:
}
// This is overloaded from TableListBoxModel, and should fill in the background of the whole row
void paintRowBackground (Graphics& g, int /*rowNumber*/, int /*width*/, int /*height*/, bool rowIsSelected) override
void paintRowBackground (Graphics& g, int rowNumber, int /*width*/, int /*height*/, bool rowIsSelected) override
{
if (rowIsSelected)
g.fillAll (Colours::lightblue);
else if (rowNumber % 2)
g.fillAll (Colour (0xffeeeeee));
}
// This is overloaded from TableListBoxModel, and must paint any cells that aren't using custom