- Check for null arrays before assigning in SDisplayUtil

This commit is contained in:
Sol
2012-11-24 15:39:31 +00:00
parent 2045039044
commit 8be939987a

View File

@@ -59,7 +59,9 @@ public class SDisplayUtil {
if (counter != (steps - 1)) {
SwingUtilities.invokeLater(new Runnable() { @Override
public void run() {
pnl.setBackground(new Color(newR[counter], oldG, oldB, newA[counter]));
int r = newR == null ? oldR : newR[counter];
int a = newA == null ? oldA : newR[counter];
pnl.setBackground(new Color(r, oldG, oldB, a));
}
});
}