Fix keyboard layout changing bug on Windows systems.
Provide correct relogin;
Fix NullPointerException appearing while old properties initialization;
Avoid to restore session if connection hadn't been initiated correctly;