title: QLocale setDefault only works at 2nd time called
body: <p>I am trying to change the default language of a <code>QLocale</code> variable in my code and then use the different separators of each language. I do not want to change it for the whole system I just want to have a chance to print numbers with different group- and decimal separators.
  The user can change the Decimal separator to what he or she prefers.</p>
  
  <pre><code>//this part works as expected in debugger
  QLocale locale;
  
  if(decSep==".")
  {
      locale.setDefault(QLocale::English); 
  }
  else if(decSep==",")
  {
      locale.setDefault(QLocale::German);
  }
  else
  {
      locale.setDefault(QLocale::system().language());
  }
  
  //added for debug purposes
  /*if(local.language()==QLocale::English)
  {
      int x=0;//jumped here when it was supposed to do so (decSep==".")
  }*/
  </code></pre>
  
  <p>Now there is some code which I'm sure has nothing to do with this error.
  Later I use:</p>
  
  <pre><code>//Now this doesn't work
  
  QString tempNum1 = locale.toString(myNum, 'f');
  </code></pre>
  
  <p>With <code>locale.toString</code> I get the separators default to the given language.</p>
  
  <p>Now my problem is that the locale variable seems to need some time or smth to change to other settings. When I change the <code>decSep</code> var and therefore the language is changed (I debugged this, this part <strong>is</strong> changed and when I ask for the language it gives the right enum) it uses the previously set settings. When I then call the function again, which gives me the <code>tempNum1</code> string then it is working.</p>
  
  <p>Is this a known problem or am I doing something wrong? Can I somehow updated locale or something like that?</p>