Sei sulla pagina 1di 2

ActionBarActivity is deprecated (Android Studio) - Stack Overflow http://stackoverflow.com/questions/29890530/actionbaractivity-is-deprec...

Este site não tem classificação


sign up log in tour help stack overflow careers

Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: ×

ActionBarActivity is deprecated (Android Studio)

Actually there is no problem. Project compiles and runs. But I can't understand what is mean strikeout class name (Android Studio tells that

there is deprecated code is used) . Can


anybody explain?

android android-actionbar deprecated

asked Apr 27 at 8:15


Yurii Mirskii
486 1 3 5

duplicate stackoverflow.com/questions/29877692/… – Ajit Aug 18 at 18:03

3 Answers

Since the version 22.1.0, the class ActionBarActivity is deprecated. You should use
AppCompatActivity .

Read here and here for more information.

edited Apr 27 at 16:29 answered Apr 27 at 8:19


Gabriele Mariotti Gaëtan
32.5k 9 77 102 3,813 2 8 26

Thank you very much! – Yurii Mirskii Apr 27 at 9:08

Could you please accept the answer if it was helpful? – Gaëtan May 4 at 7:52

It is working properly. – Suthar Rohit May 9 at 9:33

7 they could have updated the activity templates. sigh... – victor n. Jun 28 at 15:58

26 Now 1,000,000 will waste 5 minutes fixing this because somebody at google did not update the template.
That´s 5 million minutes lost, to be conservative. – Josh Jul 20 at 9:25

According to this video of Android Developers you should only make two changes

1 de 2 06/12/2015 10:24
ActionBarActivity is deprecated (Android Studio) - Stack Overflow http://stackoverflow.com/questions/29890530/actionbaractivity-is-deprec...

edited Jun 5 at 13:21 answered Jun 1 at 1:43


Jorge Casariego
4,727 2 22 33

Other changes may be necessary as outlined in that video. The two changes shown here are merely the
most basic changes. It is also important to include the proper dependency for existing projects -- as outlined
in that video. – dm78 Jun 18 at 15:47

android developers documentation says : "Updated the AppCompatActivity as the base class
for activities that use the support library action bar features. This class replaces the deprecated
ActionBarActivity."

checkout changes for Android Support Library, revision 22.1.0 (April 2015)

answered May 1 at 19:00


AmyDroid
101 1 9

2 de 2 06/12/2015 10:24

Potrebbero piacerti anche