TODO. Refactor all things witch connected with loading waiting.