2

In Android What is the main difference between extending a class from AppCompatActivity and ActionBarActivity? How do these classes differ?

N J
  • 27,217
  • 13
  • 76
  • 96

2 Answers2

6

ActionBarActivity is now deprecated. As of version 22.1 of the support library you should use AppCompatActivity.

Chris Banes (one of the authors of the AppCompat library) covered the refactor in detail here.

Ben Pearson
  • 7,532
  • 4
  • 30
  • 50
0

ActionBarActivity is deprecated, you must use AppCompatActivity instead

Source: developer.android.com

KM11
  • 697
  • 6
  • 15
  • can you tell me the main difference? – N J May 06 '15 at 17:45
  • Found similar question asked before, [accepted answer](http://stackoverflow.com/a/29978777/2846982) – KM11 May 06 '15 at 17:47
  • It has been deprecated but it can still be used, so it is not a "must" ! It is more preferably to use AppCompatActivity but not mandatory. – Red M Oct 07 '16 at 16:57