7

In my RSS reader project I need nice Grid for different sized items(that contain image and text).

I searched for solutions to make a Staggered Grid in Android and came across with AndroidStaggeredGrid library by Etsy. I am using Eclipse but library was done for Gradle.

I want to use this library in my Android project. I already tried to follow this answer but couldn't succeed. How can I import this library to my Android project.

Community
  • 1
  • 1
Rafael
  • 6,091
  • 5
  • 54
  • 79

1 Answers1

13
  • Create an Android Application Project, use any name for the package name.
  • Flag "Mark this project as library".
  • Unflag "Create custom launcher icon" and "Create activity"
  • Import the java folder of the Etsy library and then "Build Path" > "Use as Source Folder"
  • Import the res folder of the Etsy library overwriting your old res folder.
  • Use this in the AndroidManifest.xml

    <manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.etsy.android.grid" >
    </manifest>
    
  • Import Support Library: "Android Tools" > "Add Support Library"
  • Remove any other packages in gen but "com.etsy.android.grid"
  • On your project "Android Tools" > "Fix Project Properties".

It has to work now, you can use the library in your project.

GioLaq
  • 2,489
  • 21
  • 26