Move dependency injection into input.Init()

Also made dependencies into fields of input struct