title: How to populate a Spinner from String array
body: <p>How can i populate a Spinner from <code>String array</code> , I know i can do that from <code>array.xml</code> like this <code>code</code> :</p>
  
  <pre><code>ArrayAdapter&lt;CharSequence&gt; gameKindArray = ArrayAdapter.createFromResource(view.getContext(),R.array.game_kind, android.R.layout.simple_spinner_item);
          gameKindArray.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
          gameKind.setAdapter(gameKindArray); 
  </code></pre>
  
  <p>but when i have </p>
  
  <pre><code>String[] test=new String[]{"test1","test2"};
  </code></pre>
  
  <p>how i can change <code>String[]</code> to <code>ArrayAdapter</code> ?!</p>