Changed method of injecting buttons