如何将图书馆计划添加到Android项目? [英] How to add a Library Project to a android project?
问题描述
描述说
操作栏组件是一个库项目。这意味着不需要
将资源复制到您自己的项目中,只需
将操作栏组件添加到任何项目的引用。
我是Android的新手,这是什么意思?如何将库添加到我现有的项目?
将库导入到eclipse工作区中:
-
文件 - >导入 - >常规 - 将现有项目导入工作区,下一步
-
选择根目录:/ path / /项目
-
项目 - >全选
在这一点上,它失败了,因为没有什么可以选择,下一个按钮被停用。
任何想法?
- File-> New-> Other
- 选择Android Project
- 选择从现有的来源创建项目
- 点击浏览...按钮,导航到johannilsson-android-actionbar\actionbar
- 完成(现在您的工作区中的动作栏项目)
- 右键单击您的项目 - >属性
- 在Android-> Library部分中,单击添加
- 选择最近添加的项目 - > Ok
- 就是这样!
现在可以使用它
I have created a new android project. I want to have a action bar at the top so I downloaded the Action Bar for Android Library because I want to support devices from android 2.1.
The description says
The action bar component is an Library Project. This means that there's no need to copy-paste resources into your own project, simply add the action bar component as a reference to any project.
I am new to android so what does this mean? How can I add the library to my existing project?
Import the library into your eclipse workspace:
File->Import->General->Existing Projects into Workspace, Next
Select root directory: /path/to/project
Projects->Select All
At this point it fails because there is nothing to select and the next button is deactivated.
Any ideas?
- File->New->Other
- Select Android Project
- Select "Create Project from existing source"
- Click "Browse..." button and navigate to johannilsson-android-actionbar\actionbar
- Finish (Now action bar project in your workspace)
- Right-click on your project -> Properties
- In Android->Library section click Add
- select recently added project -> Ok
- that's it!
Now you can use it
这篇关于如何将图书馆计划添加到Android项目?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!