How to connect Android TreeView library to my project? - android

This is a pretty newbie question.
I found a Polidea TreeView Library for Android.
But how do I use it for my project in Android Studio?
I've tried several things - adding the .jar files directly, importing as Project/Module, setting the dependencies in Gradle. But none of this worked.
Can anyone help me with this one?

Well, actually it turned out, that the best way of connecting this library - just copy src. It's easier, than messing up with Gradle.
In Eclipse everything works fine, by the way.

Related

Android Swipelistview no longer working

Hi everyone,
I'm trying to implement a swipelistview into an android project with Android Studio, of course i'm using gradle, so i try to download the library from a repository, some odd things I realised so far:
The git repository of 47deg/swipelistview is no longer working. (404)
Also the repository from where gradle tries to download the library is no longer accessible 'http://clinker.47deg.com/nexus/content/groups/public'
The project worked like a charm just one week ago, I have an APK witch is deployed in my phone and i'm looking to it as am writing this question.
This happened days ago when I tried to open the project to do some enhancement to the app, nothing related to the swipelistview thought. And when I try to build Android studio says Cannot resolve
com.fortysevendeg.swipelistview:swipelistview:1.0-SNAPSHOT#aar
I tried removing snapshot#aar, changing version of swipelistview... no result.
Question:
Is there a problem with the repository I'm trying to download from?
If not, what are other libraries that can replace the swipelistview library?
I also checked all the related stackoverflow questions, I updated my Android Studio, changed version of gradle, tried to find a Jar of the library, but all of this without any positive result.
Thanks in advance for any efforts you put in this thread. I'm available for any clarifications.

Android Studio transition and using sub libraries / sharing libraries

I am trying to transition all our projects from Eclipse to Android Studio (Finally decided i had to do it..!) but i am fighting seriously with the way how Android Studio / gradle works - in regard to using external library projects.
Until now in Eclipse - we used to have all the dependent projects in the same workspace and they where 'shared' amongst all projects which were under development.
That made it extremely nice to do changes on the external changes and commit them separately to their own SVN repos - while the projects using them - to take advantage of the changes without thinking.
That goes specifically to one library - our own framework which we use for all android projects and it is constantly being developed, altered, partially reworked and used by several people.
But then came Android Studio... the problem is that say if i have an example project with 10 sublibrary dependencies, including our framework - Android Studio with physically COPY all files into a subfolder of the main root project - loosing all the capabilities to 'commit' changes later being done to the sub libraries - to their own SVN repos.
I've tried pretty much everything, i think i've read everything :) but crap - nothing seems to 'fix' my work case..
I tried to checkout one sublibrary in the already checked out root folder of the root project and tried to import it into it - but ofcourse Android Studio says 'library already exists' - so that doesn't work. Even if it did... the library itself has its own deps and what i saw is that Android Studio will decouple them upon import and put them at the same level in the root project.. which completely messes everything up.
So my question is - even if i understand this is no longer possible - is there any EASY way i can at least COMMIT BACK to the SVN repo of the sublibrary from within the root owning project - using Android Studio (by easy i mean from the UI directly without needing to mess with manual console merge hazzle...)
I can't understand how anyone has not solved this yet - i am sure everyone is doing this one way or another?
Could someone share a good practice way of 'doing' it? :)
THANK YOU!
What i did:
Switched to: git
Converted our subprojects to git from svn
Made all subprojects externals of the primary project
Included the subprojects in gradle with the help of this post: Android Studio 0.8.1 Creating Modules without copying files?
Cons:
Not fully manageable from Android Studio - have to do half commits in Studio, the other half + pushes in console - so i ditched Studio completely and moved all to console once again. May be this ain't so bad after all :)
What i did was use Blundell's advice - although i really... really ... REALLY didn't want to go switching completely to git...
We have over 300 repos here in SVN and it's really not the time to start the git hazzle...
But this was the only workable solution so far as git externals make it really really easy to work in such way.
The f**** up thing about this is that half work has to go to console again... Externals and adding git remotes can't be managed from Android Studio... Life, i guess :)

AndEngine andengine.jar file

Hi im using Android Studio ver. 0.8.6 now i want to use andEngine, i know that i should download andengine.jar file and copy it to libs folder in my project, everything is all right, but i can find the andengine.jar GLES2 there are only files with 1st version, and the newest examples didn't work with it, can someone pls give me link to andengine.jar GLES2? or maybe im doing something wrong?
I'm taking examples from official site and there are a lot of errors one of them:
extends BaseExample
AndEngine GLES2 may be downloaded From Here
You can download AndEngine.jar file From Here
You can download other types of AndEngine.jar file From Here
Also here are some examples about AndEngine From Here
AndEngine GLES2 may be downloaded Alternatively From Here
https://github.com/nicolasgramlich/AndEngine/tree/GLES2-AnchorCenter Use this link to get the latest andengine also download the physics engine which is a separate jar.
or maybe im doing something wrong?
Yes. First of all, you should not be using JARs anymore. You should add AndEngine and any extension as an Android Library project (Eclipse terminology) or Module (Android studio terminology).
UPDATE: Since the Android Studio became the official IDE for Android, it is now recommended to use it. However AndEngine stopped being developed by its author and its populatity is on decline. Anyway see a related question to add the module/library project to your game.
As #sm4 pointed out it is recommended to simply clone the git repo. However, after cloning the repo you will experience errors in AIDE when compiling. See my question and answer to see why I think this happens and how to fix it.

Is it possible to have a Android Studio formatted project to work on Eclipse?

I have succeed to run my android project from Eclipse to Android Studio simply by generating its gradle build (without changing the project's structure).
I would like to change this project structure to the Android Studio's format, however im afraid this p**roject will not be working anymore in Eclipse**.
Have someone did this before?Did the re-structured project still working in Eclipse? (I have a bad feeling about this)
Note : If you wondering why i dont try it before asking, its because the project is fairly complicated (around 5 libraries also need to be restructured and i only know a very little about gradle) so it will be nice if i know it will be working.
Thanks everyone.

Can I have a non-jar-based library project using Eclipse with ADT r14?

I am working with a complex library that, for historical reasons, is separated into two Android library projects that reference each other. Prior to r14 of the SDK, this worked fine. Each simply referred to the other's source code. We released a jar, and in Eclipse, applications could refer to the two library projects.
With r14, Eclipse tries to build a separate jar from each one. Since each references the other, they both fail. It may be necessary to construct a single new library project from the two. But that's development work and presents other problems. For now, I'd like to instruct Eclipse and ADT to handle them as before, i.e. not to build jars from them, just to reference the source. I've been digging, but I haven't yet found a way to do that.
Thanks in advance for any advice.
The answer is probably no. We worked around it using source links, which improves matters tremendously. This mechanism didn't work with previous ADT versions.
The other solution that would work is using apklib project that you create with the android maven plugin.

Categories

Resources