Refactor some parts of code.
Update russian localization.