[Atomic] Some changes to run on Deplhi XE5