Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import android.os.Handler;
import android.view.View;

public class Main {
    public static void fadeOut(final View view, int millis) {
        view.animate().alpha(0f).setDuration(millis).setListener(null);
        new Handler().postDelayed(new Runnable() {
            public void run() {
                view.setVisibility(View.GONE);
            }
        }, millis);
    }
}