title: setAdapter and setDropDownViewResource are written in red by IDE
body: <p>IDE say me "Cannot resolve symbol" in <code>setAdapter</code> and <code>setDropDownViewResource</code>, i don't know why:</p>
  
  <pre><code>spinner.setAdapter(adapter);
  adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
  </code></pre>
  
  <p>Thanks in advance everybody!</p>
  
  <p>I post my code:</p>
  
  <pre><code>public class MyListFragment extends Fragment implements
          android.widget.CompoundButton.OnCheckedChangeListener {
  
      ListView lv;
      ArrayList&lt;Planet&gt; planetList;
      static PlanetAdapter plAdapter;
      private TextView txtName;
      private TextView txtEmail;
      private Button btnLogout;
      private Spinner spinner1;
      private Spinner spinner2;
  
      private SQLiteHandler db;
      private SessionManager session;
      BirraAdapter biAdapter;
      PlanetAdapter.PlanetHolder holder;
      private static Context context = null;
      private static FragmentActivity mInstance;
  
      Integer[] imageId = {
              R.mipmap.androtuto,
              R.mipmap.ic_launcher,
              R.mipmap.ic_launcher,
              R.mipmap.ic_launcher,
              R.mipmap.ok,
              /*R.drawable.image6,
              R.drawable.image7*/
  
      };
      String[] countryNames={"India","China","Australia","Portugle","America","New Zealand"};
  
      @Override
      public View onCreateView(LayoutInflater inflater, ViewGroup container,
                               Bundle savedInstanceState) {
          // Inflate the custom_spinner_items for this fragment
          //super.onDestroy();
  
          SharedPreferences settings = getContext().getSharedPreferences("states", Context.MODE_PRIVATE);
          SharedPreferences.Editor editor = settings.edit();
          editor.clear();
          editor.commit();
          ViewGroup rootView = (ViewGroup) inflater.inflate(R.layout.fragment_list2, container, false);
          context = getActivity();
          mInstance = getActivity();
          txtName = (TextView) rootView.findViewById(R.id.name);
          txtEmail = (TextView) rootView.findViewById(R.id.numero_telefonico);
          btnLogout = (Button) rootView.findViewById(R.id.btnLogout);
  
          // SqLite database handler
          db = new SQLiteHandler(context.getApplicationContext());
  
  
          // session manager
          session = new SessionManager(context.getApplicationContext());
  /*
  
          if (!session.isLoggedIn()) {
              logoutUser();
          }
  */
  
          // Fetching user details from SQLite
          HashMap&lt;String, String&gt; user = db.getUserDetails();
  
          String name = user.get("name");
          //String email = user.get("email");
  //      String email = user.get("email");
          String email = user.get("numero_telefonico");
  
  
          // Displaying the user details on the screen
          System.out.println(name + email);
  
          txtName.setText(name);
          txtEmail.setText(email);
      /*  Button mButton = (Button) rootView.findViewById(R.id.button);
          mButton.setOnClickListener(new View.OnClickListener() {
              public void onClick(View v) {
                  showResult(v);
  
  
              }
          });*/
          //return inflater.inflate(R.custom_spinner_items.fragment_list2, container, false);
          btnLogout.setOnClickListener(new View.OnClickListener() {
  
              @Override
              public void onClick(View v) {
                  logoutUser();
              }
          });
  
      /*  List&lt;String&gt; spinnerArray =  new ArrayList&lt;String&gt;();
          spinnerArray.add("item1");
          spinnerArray.add("item2");
  
          ArrayAdapter&lt;String&gt; adapter = new ArrayAdapter&lt;String&gt;(
                  this.getContext(), android.R.layout.simple_spinner_item, spinnerArray);
  
          adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
          Spinner sItems = (Spinner) rootView.findViewById(R.id.simpleSpinner);
          sItems.setAdapter(adapter);*/
          return rootView;
      }
      Spinner spinner = (Spinner) getView().findViewById(R.id.simpleSpinner);
      // Create an ArrayAdapter using the string array and a default spinner layout
      ArrayAdapter&lt;CharSequence&gt; adapter = ArrayAdapter.createFromResource(this.getContext(),
              R.array.country_arrays, android.R.layout.simple_spinner_item);
  // Specify the layout to use when the list of choices appears
      //adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
  // Apply the adapter to the spinner
      spinner.setAdapter(adapter);
  </code></pre>