@Override
public void reportingPeriodUpdated()
{
ReportingPeriod period = getReportingPeriod();
ClientPerformanceSnapshot snapshot = new ClientPerformanceSnapshot(getClient(), period);
try
{
calculation.getTree().setRedraw(false);
calculation.setInput(snapshot);
calculation.expandAll();
ViewerHelper.pack(calculation);
calculation.getTree().getParent().layout();
}
finally
{
calculation.getTree().setRedraw(true);
}
snapshotStart.setInput(snapshot.getStartClientSnapshot());
snapshotStart.pack();
snapshotEnd.setInput(snapshot.getEndClientSnapshot());
snapshotEnd.pack();
earnings.setInput(snapshot.getEarnings());
earningsByAccount.setInput(new GroupEarningsByAccount(snapshot).getItems());
}