johannilsson / android-actionbar

DEPRECATED Android Action Bar Implementation
1.31k stars 564 forks source link

ActionBar red underlines? #59

Closed TonyCostanza closed 12 years ago

TonyCostanza commented 12 years ago

Sorry, for I figure this is a straight NOOB issue, but:

when i add the ActionBar actionBar = (ActionBar) findViewById(R.id.actionbar); // You can also assign the title programmatically by passing a // CharSequence or resource id. //actionBar.setTitle(R.string.some_title); actionBar.setHomeAction(new IntentAction(this, HomeActivity.createIntent(this), R.drawable.ic_title_home_default)); actionBar.addAction(new IntentAction(this, createShareIntent(), R.drawable.ic_title_share_default)); actionBar.addAction(new ToastAction());

on my project, the ActionBar term is giving me errors. I was told actionbar only works on Android 3.0+, is this true of your project as well or is ActionBar not coming up because i screwed up importing your other project as a reference/library

johannilsson commented 12 years ago

The native ActionBar, included in the SDK only works from 3.0+, this implementation works from 1.6+. Have you initiated it correct, if you're getting red underlines I guess it's an IDE related issue?

TonyCostanza commented 12 years ago

Thanks for your reply, I'm still playing around with it. Is there any other documentation regarding implementing this aside from the README?

TonyCostanza commented 12 years ago

Do you have skype sir? :)

johannilsson commented 12 years ago

The readme is the only documentation available, there's some projects listed in the wiki with links to their github repos which works pretty well as references too. Regarding the installation if you're still seeing the red underlines I would recommend to have a look at the android documentaiton regarding library projects.

TonyCostanza commented 12 years ago

Sorry to bother you, but I'd really like to get this to work I've been at it for quite awhile. I had to remove your code and start all over again, and now i can't seem to import your project. The one question I have:

In order to use this project as a library, all I have to do is use the "https://github.com/johannilsson/android-actionbar.git" and clone your project. Then I should be able to import your project into eclipse right? What i'm stuck on is that I can't get eclipse to see that your "https://github.com/johannilsson/android-actionbar.git" is a project. Do you have any idea what may be screwing me up? I can't seem to figure out how to get started D:

johannilsson commented 12 years ago

I believe you have to use import from source or similar in Eclipse.

TonyCostanza commented 12 years ago

Hey Johannilsson, thanks for your help yesterday. I slept on all the dilemmas I was having, and this morning I found some very obvious errors on my part. I got your project added as a library now, and It's all smooth sailing now. You've done an excellent job on this. I like how you've structured everything. Thanks for the time and effort you put into this project. These kinds of good deeds do not go unnoticed. Cheers from California, - Tony Costanza

johannilsson commented 12 years ago

Thank you glad to hear you like it and that you got it to run. California sounds sunny, here's -15°C and snowing brrr.