Srokowski Maciej
Srokowski Maciej

Reputation: 431

Using support library

Is there any tutorial available on the net about using support library? I am little confused because in my activity I imported all the widgets from a support library and I still get markers that say I need api 11. Do I have to extend FragmentActivity instead of Activity to use it?

EDIT:

My problem was that I extended Activity instead of FragmentActivity. This problem is mentioned here: getLoaderManager().initLoader() doesn't accept 'this' as argument though the class (ListFragment) implements LoaderManager.LoaderCallbacks<Cursor>

Upvotes: 0

Views: 172

Answers (1)

Tudor Luca
Tudor Luca

Reputation: 6419

Here is a good explanation on how to use the support library.

Regarding FragmentActivity, you have to use it if you are trying to use a Fragment in an Activity.

Also be careful to import the proper classes. An example for a Fragment:

import android.support.v4.app.Fragment;

instead of

import android.app.Fragment;

Upvotes: 1

Related Questions