Android Open Source - SimpleNotes List Header Animation Listener






From Project

Back to project page SimpleNotes.

License

The source code is released under:

Apache License

If you think the Android project SimpleNotes listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.moysa.simplenotes.ui.listeners;
/*from   w  w  w . java  2 s  .  c om*/
import android.animation.Animator;
import android.view.View;
import android.view.ViewGroup;

/**
 * Created by Sergey Moysa on 15.03.14.
 */
public class ListHeaderAnimationListener implements Animator.AnimatorListener {

    private ViewGroup standardGroup;
    private ViewGroup searchGroup;
    private boolean isSearchShown;

    public ListHeaderAnimationListener(ViewGroup standardGroup, ViewGroup searchGroup, boolean isSearchShown) {
        this.standardGroup = standardGroup;
        this.searchGroup = searchGroup;
        this.isSearchShown = isSearchShown;
    }

    @Override
    public void onAnimationStart(Animator animation) {
        if (!isSearchShown) {
            searchGroup.setVisibility(View.VISIBLE);
        }
    }

    @Override
    public void onAnimationEnd(Animator animation) {
        if (isSearchShown) {
            searchGroup.setVisibility(View.GONE);
        }
    }

    @Override
    public void onAnimationCancel(Animator animation) {

    }

    @Override
    public void onAnimationRepeat(Animator animation) {

    }
}




Java Source Code List

com.moysa.simplenotes.core.Note.java
com.moysa.simplenotes.core.NotesComparator.java
com.moysa.simplenotes.core.NotesUtils.java
com.moysa.simplenotes.db.NoteDataBaseHelper.java
com.moysa.simplenotes.ui.activities.MainActivity.java
com.moysa.simplenotes.ui.activities.SettingsActivity.java
com.moysa.simplenotes.ui.adapters.NotesAdapter.java
com.moysa.simplenotes.ui.application.NoteApplication.java
com.moysa.simplenotes.ui.fragments.NavigationDrawerFragment.java
com.moysa.simplenotes.ui.fragments.NoteFragment.java
com.moysa.simplenotes.ui.listeners.ListHeaderAnimationListener.java