Fix selected translation in special circumstances.

In cases where there where multiple uilanguages, sometimes the
wrong language was chosen for the Qt localisation.
Also, use the standard matching for locales for the ifw
translation as well.

Task-number: QTIFW-324

Change-Id: I2c4cd079baa3d1ce4c5c69bf6692ba313616f722
Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>