In general, to make it work:
- import project into eclipse (File -> Import -> General -> Existing Projects into Workspace)
- in Eclipse, Manually create gen folder and add it as source folder (right click on your project, Build Path -> Configure Build Path -> Add folder)
- Clean your project, you suppose to get R.java generated
But It doesn't, Why?
Because there are some compile error (or bug?) regarding to the xml file in res, so R is not genetared (I've tested on my Mac):
In res/values/styles.xml: commented out the following:
<style name="iWindowTitleBackground" parent="android:WindowTitleBackground">
<item name="android:background">@drawable/title_bar</item>
</style>
In res/values/themes.xml: comment out the following:
<item name="android:windowTitleBackgroundStyle">@style/iWindowTitleBackground</item>
Then do a Project -> Clean, you should get R.java generated.
There is bug reported that parent="android:WindowTitleBackground" cannot be resolved in some operating system, check out here for more details.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…