All Projects → mikepenz → Animatedgridview

mikepenz / Animatedgridview

Licence: apache-2.0
A simple library which adds some basic animation if you delete fields. There's also a HeaderGridView if you need such a view for your projects :D

Programming Languages

java
68154 projects - #9 most used programming language

AnimatedGridView

AnimatedGridView extends the default GridView and adds some new functions to animate the deletion of rows. You just have to choose the AnimatedGridView and extend the AnimatedAdapter (which extends the BaseAdapter).

This library also adds a HeaderGridView, like the normal ListView. The HeaderGridView is from the Google Source Code of their gallery app.

Including in your project

###Using Maven AnimatedGridView Library is pushed to [Maven Central], so you just need to add the following dependency to your build.gradle.

dependencies {
	compile 'com.tundem.widget.gridview:library:[email protected]'
}

Usage

via code or via xml (sample)

<com.tundem.widget.gridview.AnimatedGridView
    ...
 />

delete fields and animate the gridview

  • start the animation by calling following method
animateDeleteCells(mRemovedFieldsToAnimate, 200);
  • you can also define a listener to do something after the fields were removed
setAnimationListener(new AnimationListener() {
        @Override
        public void onAnimationFinish() {
            ...
	}
});

add fields and animate the gridview

  • start the animation by calling following method
//Items to add:
LinkedList<Object> items = new LinkedList<Object>();
items.add(1);
items.add(2);
items.add(3);
items.add(4);
items.add(5);
items.add(6);
//animate the new items
agv.animateAddCells(items, 200);

Used in following projects

Numbers (Only remove animation)

Developed By

License

Copyright 2014 Mike Penz

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].