Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
[email protected] committed Nov 7, 2013
2 parents 54693cb + d062713 commit d28fc41
Show file tree
Hide file tree
Showing 42 changed files with 222 additions and 154 deletions.
Binary file modified ListViewAnimationsExample.apk
Binary file not shown.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Known applications using ListViewAnimations
* Car Hire ([Play Store][10])
* Super BART ([Play Store][11])
* DK FlashCards ([Play Store][15])
* Voorlees Verhaaltjes 2.0 ([Play Store][21])

If you want your app to be listed as well please contact me via [Google Plus][8], or send me an email at haarman.niek [at] gmail.com, starting the title with `[LVA]`.

Expand Down Expand Up @@ -60,7 +61,6 @@ Special Thanks
* Roman Nurik - The ListViewAnimations library uses a modified version of his [SwipeDismissListViewTouchListener][5] to support swipe-to-dismiss.
* DevBytes - Drag-and-Drop reordering is done by a modified version of their [DynamicListView][16].
* Jake Warthon - To support devices pre-HC (<3.0), a jar file of [NineOldAndroids][2] is included.
* Emil Sjölander - If you're already using the [StickyListHeaders][14] library, the ListViewAnimations library makes sure your header views are animated as well. Therefore, a copy of the StickyListHeaders jar file is included.

License
-----
Expand All @@ -82,7 +82,7 @@ License
[1]: https://play.google.com/store/apps/details?id=com.haarman.listviewanimations
[2]: http://nineoldandroids.com/
[3]: http://en.wikipedia.org/wiki/Decorator_pattern
[4]: https://github.com/nhaarman/ListViewAnimations/blob/master/com.haarman.listviewanimations-2.5.1.jar?raw=true
[4]: https://github.com/nhaarman/ListViewAnimations/blob/master/com.haarman.listviewanimations-2.5.2.jar?raw=true
[5]: https://gist.github.com/romannurik/2980593
[6]: https://play.google.com/store/apps/details?id=com.haarman.treinverkeer
[7]: https://www.twitter.com/niekfct
Expand All @@ -92,10 +92,10 @@ License
[11]: https://play.google.com/store/apps/details?id=com.getgoodcode.bart
[12]: https://play.google.com/store/apps/details?id=com.haarman.ultimatettt
[13]: https://github.com/nhaarman/ListViewAnimations/wiki
[14]: http://emilsjolander.github.io/StickyListHeaders/
[15]: https://play.google.com/store/apps/details?id=com.ducky.flashcards
[16]: http://youtu.be/_BZIvjMgH-Q
[17]: https://github.com/JakeWharton/NineOldAndroids/downloads
[18]: https://play.google.com/store/apps/details?id=com.rageconsulting.android.lightflowlite
[19]: https://play.google.com/store/apps/details?id=com.juannale.pearljamlyricsapp
[20]: https://play.google.com/store/apps/details?id=com.cafetaso.foodinfo
[20]: https://play.google.com/store/apps/details?id=com.cafetaso.foodinfo
[21]: https://play.google.com/store/apps/details?id=sa.voorleesVerhaaltjes
Binary file removed com.haarman.listviewanimations-2.5.1.jar
Binary file not shown.
Binary file added com.haarman.listviewanimations-2.5.2.jar
Binary file not shown.
6 changes: 3 additions & 3 deletions example/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.haarman.listviewanimations"
android:versionCode="201310141"
android:versionName="2.5.1" >
android:versionCode="201311071"
android:versionName="2.5.2" >

<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="18" />
android:targetSdkVersion="19" />

<uses-permission android:name="com.android.vending.BILLING" />

Expand Down
2 changes: 1 addition & 1 deletion example/project.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt

# Project target.
target=android-18
target=android-19
android.library.reference.1=..\\..\\android-support-v7-appcompat
android.library.reference.2=../library
Binary file modified example/res/drawable-hdpi/ic_beer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-hdpi/ic_github.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-mdpi/ic_beer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-mdpi/ic_github.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-xhdpi/ic_beer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-xhdpi/ic_github.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-xxhdpi/ic_beer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified example/res/drawable-xxhdpi/ic_github.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion example/res/layout/activity_animateremoval.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
android:orientation="vertical"
android:paddingTop="@dimen/paddingTop" >

<Button
android:id="@+id/activity_animateremoval_button"
Expand Down
11 changes: 11 additions & 0 deletions example/res/layout/activity_draganddrop.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<merge xmlns:android="http://schemas.android.com/apk/res/android" >

<com.haarman.listviewanimations.view.DynamicListView
android:id="@+id/activity_draganddrop_listview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="@dimen/paddingTop"
android:divider="@null" />

</merge>
1 change: 1 addition & 0 deletions example/res/layout/activity_examples_itemmanipulations.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/paddingTop"
android:gravity="center_horizontal"
android:orientation="vertical"
android:padding="8dp" >
Expand Down
5 changes: 3 additions & 2 deletions example/res/layout/activity_googlecards.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<ListView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/activity_googlecards_listview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/activity_googlecards_listview"
android:background="#e2e2e2"
android:clipToPadding="false"
android:divider="@null"
android:fadingEdge="none"
android:dividerHeight="16dp"
android:fadingEdge="none"
android:padding="16dp"
android:layout_marginTop="@dimen/paddingTop"
android:scrollbarStyle="outsideOverlay" />
10 changes: 5 additions & 5 deletions example/res/layout/activity_gridview.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>

<GridView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:numColumns="3"
android:id="@+id/activity_gridview_gv"
android:layout_height="match_parent">
android:id="@+id/activity_gridview_gv"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:numColumns="3"
android:paddingTop="@dimen/paddingTop" >

</GridView>
1 change: 1 addition & 0 deletions example/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:layout_marginTop="@dimen/paddingTop"
android:gravity="center_horizontal"
android:orientation="vertical"
android:padding="8dp"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@
<merge xmlns:android="http://schemas.android.com/apk/res/android" >

<ListView
android:id="@+id/activity_appearanceexample_listview"
android:id="@+id/activity_mylist_listview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="@dimen/paddingTop"
android:divider="@null" />

</merge>
5 changes: 5 additions & 0 deletions example/res/values-v19/dimens.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<resources >

<dimen name="paddingTop">73dp</dimen>

</resources>
5 changes: 5 additions & 0 deletions example/res/values/dimens.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<resources >

<dimen name="paddingTop">0dp</dimen>

</resources>
2 changes: 1 addition & 1 deletion example/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Base application theme, dependent on API level. This theme is replaced
by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
-->
<style name="AppBaseTheme" parent="@style/Theme.AppCompat.Light.DarkActionBar">
<style name="AppBaseTheme" parent="@style/Theme.AppCompat.Light">
<!--
Theme customizations available in newer API levels can go in
res/values-vXX/styles.xml, while customizations related to
Expand Down
10 changes: 7 additions & 3 deletions example/src/com/haarman/listviewanimations/BaseActivity.java
Original file line number Diff line number Diff line change
@@ -1,19 +1,23 @@
package com.haarman.listviewanimations;

import android.annotation.SuppressLint;
import android.os.Build;
import android.os.Bundle;
import android.support.v7.app.ActionBarActivity;
import android.view.MenuItem;

public class BaseActivity extends ActionBarActivity {

@SuppressLint("InlinedApi")
@Override
protected void onCreate(Bundle savedInstanceState) {
if (Build.VERSION.SDK_INT >= 19) {
getWindow().addFlags(android.view.WindowManager.LayoutParams.FLAG_TRANSLUCENT_NAVIGATION);
}
super.onCreate(savedInstanceState);

getSupportActionBar().setDisplayHomeAsUpEnabled(true);
}



@Override
public boolean onOptionsItemSelected(MenuItem item) {
switch (item.getItemId()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ protected void onCreate(Bundle savedInstanceState) {

mGoogleCardsAdapter = new GoogleCardsAdapter(this);
SwingBottomInAnimationAdapter swingBottomInAnimationAdapter = new SwingBottomInAnimationAdapter(new SwipeDismissAdapter(mGoogleCardsAdapter, this));
swingBottomInAnimationAdapter.setInitialDelayMillis(300);
swingBottomInAnimationAdapter.setAbsListView(listView);

listView.setAdapter(swingBottomInAnimationAdapter);
Expand Down
17 changes: 11 additions & 6 deletions example/src/com/haarman/listviewanimations/GridViewActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@

import java.util.ArrayList;
import java.util.List;

import android.annotation.SuppressLint;
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.Build;
import android.os.Bundle;
import android.support.v4.util.LruCache;
import android.support.v7.app.ActionBarActivity;
Expand All @@ -14,20 +15,24 @@
import android.view.ViewGroup;
import android.widget.GridView;
import android.widget.ImageView;

import com.haarman.listviewanimations.swinginadapters.prepared.AlphaInAnimationAdapter;
import com.haarman.listviewanimations.swinginadapters.prepared.SwingBottomInAnimationAdapter;

public class GridViewActivity extends ActionBarActivity {

@SuppressLint("InlinedApi")
@Override
protected void onCreate(Bundle savedInstanceState) {
if (Build.VERSION.SDK_INT >= 19) {
getWindow().addFlags(android.view.WindowManager.LayoutParams.FLAG_TRANSLUCENT_NAVIGATION);
}
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_gridview);

GridView gridView = (GridView) findViewById(R.id.activity_gridview_gv);
AlphaInAnimationAdapter alphaInAnimationAdapter = new AlphaInAnimationAdapter(new MyAdapter(this, getItems()));
alphaInAnimationAdapter.setAbsListView(gridView);
gridView.setAdapter(alphaInAnimationAdapter);
SwingBottomInAnimationAdapter swingBottomInAnimationAdapter = new SwingBottomInAnimationAdapter(new MyAdapter(this, getItems()));
swingBottomInAnimationAdapter.setAbsListView(gridView);
swingBottomInAnimationAdapter.setInitialDelayMillis(300);
gridView.setAdapter(swingBottomInAnimationAdapter);

getSupportActionBar().setDisplayHomeAsUpEnabled(true);
}
Expand Down
15 changes: 11 additions & 4 deletions example/src/com/haarman/listviewanimations/MainActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,19 @@
import org.json.JSONException;
import org.json.JSONObject;

import android.annotation.SuppressLint;
import android.app.Activity;
import android.app.PendingIntent;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
import android.content.IntentSender.SendIntentException;
import android.content.ServiceConnection;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.os.IBinder;
import android.os.RemoteException;
import android.support.v7.app.ActionBarActivity;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
Expand All @@ -40,10 +42,15 @@
import com.haarman.listviewanimations.appearanceexamples.AppearanceExamplesActivity;
import com.haarman.listviewanimations.itemmanipulationexamples.ItemManipulationsExamplesActivity;

public class MainActivity extends ActionBarActivity {
public class MainActivity extends Activity {

@SuppressLint("InlinedApi")
@Override
protected void onCreate(Bundle savedInstanceState) {
if (Build.VERSION.SDK_INT >= 19) {
getWindow().addFlags(android.view.WindowManager.LayoutParams.FLAG_TRANSLUCENT_NAVIGATION);
}

super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);

Expand Down Expand Up @@ -110,13 +117,13 @@ public void onItemManipulationClicked(View view) {
@Override
public void onServiceDisconnected(ComponentName name) {
mService = null;
supportInvalidateOptionsMenu();
// supportInvalidateOptionsMenu();
}

@Override
public void onServiceConnected(ComponentName name, IBinder service) {
mService = IInAppBillingService.Stub.asInterface(service);
supportInvalidateOptionsMenu();
// supportInvalidateOptionsMenu();

new Thread() {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ public class MyListActivity extends BaseActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
mListView = new ListView(this);
setContentView(mListView);
setContentView(R.layout.activity_mylist);
mListView = (ListView) findViewById(R.id.activity_mylist_listview);
mListView.setDivider(null);
}

Expand Down
Loading

0 comments on commit d28fc41

Please sign in to comment.