Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
//License from project: Open Source License 

import android.view.View;
import android.view.animation.AlphaAnimation;
import android.view.animation.Animation;

public class Main {
    /**
     * Fades in the view
     * @param view
     */
    public static void fadeIn(final View view, int duration) {
        final Animation in = new AlphaAnimation(0.0f, 1.0f);
        in.setDuration(duration);
        view.setAnimation(in);
    }
}