Using Support Design Library in Eclipse

后端 未结 1 1137
抹茶落季
抹茶落季 2021-01-03 04:38

I\'m working on a project that unfortunately hasn\'t been migrated to Android Studio yet. I want to utilize the floating action button in Google\'s new support.design librar

相关标签:
1条回答
  • 2021-01-03 05:23

    Through Eclipse's project properties dialog (Project → Properties), not only can you attach to a library project, but you can mark a project as being a library project.

    Normally, when you import a project, that information is pulled from the project.properties file. Alas, the Android Support Design Project does not have a project.properties file, and Eclipse's stock import process therefore assumes that you are importing an app.

    Just go into Project → Properties → Android and mark the imported library as being a library, via the "Is Library" checkbox. Then, you can attach it to the app that wishes to use the library.

    Note that you will need to repeat this "Is Library" nonsense with future editions of the library, when you import those to replace your existing one, when Google ships updates to the library.

    All of this headache will go away when you switch to Android Studio (adding libraries is much easier), though it will probably be replaced by new and exciting headaches. :-)

    0 讨论(0)
提交回复
热议问题